Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions changelog.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ Internal
* Use prompt_toolkit's `bell()`.
* Refactor `SQLResult` dataclass.
* Avoid depending on string matches into host info.
* Add more URL constants.


1.58.0 (2026/02/28)
Expand Down
6 changes: 4 additions & 2 deletions mycli/constants.py
Original file line number Diff line number Diff line change
@@ -1,2 +1,4 @@
DOCS_URL = 'https://mycli.net/docs'
ISSUES_URL = 'https://github.com/dbcli/mycli/issues'
HOME_URL = 'https://mycli.net'
REPO_URL = 'https://github.com/dbcli/mycli'
DOCS_URL = f'{HOME_URL}/docs'
ISSUES_URL = f'{REPO_URL}/issues'
19 changes: 8 additions & 11 deletions mycli/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@
from mycli.compat import WIN
from mycli.completion_refresher import CompletionRefresher
from mycli.config import get_mylogin_cnf_path, open_mylogin_cnf, read_config_files, str_to_bool, strip_matching_quotes, write_default_config
from mycli.constants import ISSUES_URL
from mycli.constants import HOME_URL, ISSUES_URL, REPO_URL
from mycli.key_bindings import mycli_bindings
from mycli.lexer import MyCliLexer
from mycli.packages import special
Expand Down Expand Up @@ -95,7 +95,7 @@
# Query tuples are used for maintaining history
Query = namedtuple("Query", ["query", "successful", "mutating"])

SUPPORT_INFO = f"Home: https://mycli.net\nBug tracker: {ISSUES_URL}"
SUPPORT_INFO = f"Home: {HOME_URL}\nBug tracker: {ISSUES_URL}"
DEFAULT_WIDTH = 80
DEFAULT_HEIGHT = 25
MIN_COMPLETION_TRIGGER = 1
Expand Down Expand Up @@ -2002,16 +2002,15 @@ def get_password_from_file(password_file: str | None) -> str | None:
click.secho(
"Warning: The --ssl/--no-ssl CLI options are deprecated and will be removed in a future release. "
"Please use the \"default_ssl_mode\" config option or --ssl-mode CLI flag instead. "
"See issue https://github.com/dbcli/mycli/issues/1507",
f"See issue {ISSUES_URL}/1507",
err=True,
fg="yellow",
)

# ssh_port and ssh_config_path have truthy defaults and are not included
if any([ssh_user, ssh_host, ssh_password, ssh_key_filename, list_ssh_config, ssh_config_host]) and not ssh_warning_off:
click.secho(
"Warning: The built-in SSH functionality is deprecated and will be removed in a future release. "
"See Issue https://github.com/dbcli/mycli/issues/1464",
f"Warning: The built-in SSH functionality is deprecated and will be removed in a future release. See issue {ISSUES_URL}/1464",
err=True,
fg="red",
)
Expand Down Expand Up @@ -2101,7 +2100,7 @@ def get_password_from_file(password_file: str | None) -> str | None:
click.secho(
'Warning: The "ssl" DSN URI parameter is deprecated and will be removed in a future release. '
'Please use the "ssl_mode" parameter instead. '
'See issue https://github.com/dbcli/mycli/issues/1507',
f'See issue {ISSUES_URL}/1507',
err=True,
fg='yellow',
)
Expand Down Expand Up @@ -2265,7 +2264,7 @@ def get_password_from_file(password_file: str | None) -> str | None:
dedent(
f"""
Reading configuration from my.cnf files is deprecated.
See https://github.com/dbcli/mycli/issues/1490 .
See {ISSUES_URL}/1490 .
The cause of this message is the following in a my.cnf file without a corresponding
~/.myclirc entry:

Expand All @@ -2279,7 +2278,7 @@ def get_password_from_file(password_file: str | None) -> str | None:

The ~/.myclirc setting will take precedence. In the future, the my.cnf will be ignored.

Values are documented at https://github.com/dbcli/mycli/blob/main/mycli/myclirc . An
Values are documented at {REPO_URL}/blob/main/mycli/myclirc . An
empty <value> is generally accepted.

To ignore all of this, set
Expand Down Expand Up @@ -2633,9 +2632,7 @@ def do_config_checkup(mycli: MyCli) -> None:
did_output_deprecated = True

if did_output_missing or did_output_unsupported or did_output_deprecated:
print(
'For more info on supported features, see the commentary and defaults at:\n\n * https://github.com/dbcli/mycli/blob/main/mycli/myclirc\n'
)
print(f'For more info on supported features, see the commentary and defaults at:\n\n * {REPO_URL}/blob/main/mycli/myclirc\n')
else:
print('\n### Configuration:\n')
print('User configuration all up to date!\n')
Expand Down