summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMicah Jerome Ellison <micah.jerome.ellison@gmail.com>2023-03-04 12:45:37 -0800
committerGitHub <noreply@github.com>2023-03-04 12:45:37 -0800
commit427485a1d7acb25a898e608f909c61e856fe6d4b (patch)
treed7210d5f7c06ecaed1d572279cd366addcecd367
parent23150ddb3129be17d31259da0a891f7ab49623da (diff)
Add message with config location and docs location when installation is complete (#1695)
-rw-r--r--jrnl/install.py9
-rw-r--r--jrnl/messages/MsgText.py5
-rw-r--r--tests/bdd/features/install.feature4
3 files changed, 17 insertions, 1 deletions
diff --git a/jrnl/install.py b/jrnl/install.py
index 6f14e967..f9d9ac1a 100644
--- a/jrnl/install.py
+++ b/jrnl/install.py
@@ -154,6 +154,15 @@ def install() -> dict:
default_config["colors"] = get_default_colors()
save_config(default_config)
+
+ print_msg(
+ Message(
+ MsgText.InstallComplete,
+ MsgStyle.NORMAL,
+ params={"config_path": get_config_path()},
+ )
+ )
+
return default_config
diff --git a/jrnl/messages/MsgText.py b/jrnl/messages/MsgText.py
index a0fd6dd0..ee2a43a1 100644
--- a/jrnl/messages/MsgText.py
+++ b/jrnl/messages/MsgText.py
@@ -28,6 +28,11 @@ class MsgText(Enum):
AllDoneUpgrade = "We're all done here and you can start enjoying jrnl 2"
+ InstallComplete = """
+ jrnl configuration created at {config_path}
+ For advanced features, read the docs at https://jrnl.sh
+ """
+
# --- Prompts --- #
InstallJournalPathQuestion = """
Path to your journal file (leave blank for {default_journal_path}):
diff --git a/tests/bdd/features/install.feature b/tests/bdd/features/install.feature
index 44c36814..5dc286b9 100644
--- a/tests/bdd/features/install.feature
+++ b/tests/bdd/features/install.feature
@@ -6,7 +6,9 @@ Feature: Installing jrnl
\n
\n
\n
- Then the output should contain "Journal 'default' created"
+ Then the output should contain "jrnl configuration created at"
+ And the output should contain "For advanced features, read the docs at https://jrnl.sh"
+ And the output should contain "Journal 'default' created"
And the default journal "journal.txt" should be in the "." directory
And the config should contain "encrypt: false"
And the version in the config file should be up-to-date