For example, looking at wget here we could use an alias but this is less desireable as wget and some other commands (this is just the first example I ran into after installing Garuda today) can be run in scripts too and a config file would ensure all usages of wget won't cause issues.
My initial idea would be to create an action of type: create-config which takes path and data which is a multiline string which is written to the file and can substitute variables for absolute paths. If the file already exists, error and do not complete the rule, printing data and telling the user to manually do it.
It would be interesting to see if we could extend this to manual-only rules for editing root-owned files, too. You can get rid of .bashrc and .bash_profile by editing /etc/profile for example.
For example, looking at wget here we could use an alias but this is less desireable as wget and some other commands (this is just the first example I ran into after installing Garuda today) can be run in scripts too and a config file would ensure all usages of wget won't cause issues.
My initial idea would be to create an
action
oftype: create-config
which takespath
anddata
which is a multiline string which is written to the file and can substitute variables for absolute paths. If the file already exists, error and do not complete the rule, printingdata
and telling the user to manually do it.It would be interesting to see if we could extend this to manual-only rules for editing root-owned files, too. You can get rid of
.bashrc
and.bash_profile
by editing/etc/profile
for example.