You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This plugin might be quite complex to use - especially for beginners - and setting up shell commands can involve quite a lot of trial and error. It's not uncommon for even experienced users to forget to e.g. turn on a Prompt for a shell command when using custom variables related to the Prompt.
I think some uninterruping, light footprint tips could help users get some things right quicker. However, I'd like them to be "rare" in a way that when a tip appears, it's actually something that the user will probably fix, so that the tip won't show up forever. A tip is useless, if most of the time users don't react to it. Could also add a setting where each tip type could be hidden forever.
Tips could also offer a button for fixing the problem automatically or showing user how to fix it. However, autofixes should never edit shell commands' content, as automatic editing could lead to shell commands being different than what a user meant, making them possibly dangerous.
Placement in settings
Tips could appear below a shell command. (Not with a red color, it's just there as a placeholder).
Tip ideas so far
Permanent tips
These would show up until a problem is solved by a user.
Prompt related custom variables are used, but no Prompt is selected for the shell command.
Auto fix: Select (the prompt name here) to be used by the shell command.
Prompt related custom variables are used, but they belong to a different Prompt than what is selected for the shell command.
Auto fix: Switch to use (the correct prompt name here).
{{event_*}} variables are used, but no related event is enabled for the shell command.
Auto fix: Turn on event: ... followed by a list of events that can satisfy all the {{event_*}} variables contained in the shell command. Even though a user may want to enable multiple suggested events, only allow clicking just one, or an All option, for the sake of simplicity.
Obsidian quits event is used together with "Ask for confirmation" setting. The confirmation setting leads to the shell command not being executed when quitting, because a confirmation dialog cannot be shown when Obsidian quits.
Auto fix: Don't ask for confirmation.
Auto fix: Disable the "Obsidian quits" event.
Obsidian quits event is used together with a Prompt. The prompt leads to the shell command not being executed when quitting, because a prompt modal cannot be shown when Obsidian quits.
Auto fix: Don't use a Prompt. (But clicking this would lead to Prompt related custom variables are used, but no Prompt is selected for the shell command. Need to think this fix more.)
Auto fix: Disable the "Obsidian quits" event.
Obsidian quits event is used together with stdout output handling. There's no time for doing anything with the output when Obsidian quits. This is mostly needed if user has selected output to be written to a note, not so much needed if the output channel is just a notification balloon.
Auto fix: Set stdout output channel to "Ignore"
Auto fix: Disable the "Obsidian quits" event.
Similar tip for stderr as above.
Windows: Using CMD.EXE as a shell, and having linebreaks in a command (i.e. multiline command). There's a problem with this plugin that on CMD, only the first line gets executed. I don't know how to fix it, so there could be a tip that would suggest to either switch to use PowerShell or to put the shell command on a single line. (Added on 2023-09-23).
Temporary tips
Tips that relate to problems that can only be detected after a shell command is executed, or after some other action.
Output is received, but it's ignored in the output settings. This tip could be shown when testing shell command execution in the settings, by clicking an Execute now icon, and some output comes to stdout. Normal execution would not show the tip, as tips are only meant to show up in settings. This not always a problem, as sometimes ignoring output is a conscious decision.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
This plugin might be quite complex to use - especially for beginners - and setting up shell commands can involve quite a lot of trial and error. It's not uncommon for even experienced users to forget to e.g. turn on a Prompt for a shell command when using custom variables related to the Prompt.
I think some uninterruping, light footprint tips could help users get some things right quicker. However, I'd like them to be "rare" in a way that when a tip appears, it's actually something that the user will probably fix, so that the tip won't show up forever. A tip is useless, if most of the time users don't react to it. Could also add a setting where each tip type could be hidden forever.
Tips could also offer a button for fixing the problem automatically or showing user how to fix it. However, autofixes should never edit shell commands' content, as automatic editing could lead to shell commands being different than what a user meant, making them possibly dangerous.
Placement in settings
Tips could appear below a shell command. (Not with a red color, it's just there as a placeholder).
Tip ideas so far
Permanent tips
These would show up until a problem is solved by a user.
{{event_*}}
variables are used, but no related event is enabled for the shell command.{{event_*}}
variables contained in the shell command. Even though a user may want to enable multiple suggested events, only allow clicking just one, or an All option, for the sake of simplicity.stdout
output handling. There's no time for doing anything with the output when Obsidian quits. This is mostly needed if user has selected output to be written to a note, not so much needed if the output channel is just a notification balloon.stdout
output channel to "Ignore"stderr
as above.CMD.EXE
as a shell, and having linebreaks in a command (i.e. multiline command). There's a problem with this plugin that on CMD, only the first line gets executed. I don't know how to fix it, so there could be a tip that would suggest to either switch to usePowerShell
or to put the shell command on a single line. (Added on 2023-09-23).Temporary tips
Tips that relate to problems that can only be detected after a shell command is executed, or after some other action.
stdout
. Normal execution would not show the tip, as tips are only meant to show up in settings. This not always a problem, as sometimes ignoring output is a conscious decision.stdout
.stdout
.stderr
?Beta Was this translation helpful? Give feedback.
All reactions