Make the initrc file more obvious
I was in the process of getting ion set up on my linux box when I realized
ls didn't automatically output with color (tbf the only shell I know that does is bash and they just include an alias in the bashrc by default) so I went to go find the config file for ion. I head to .config, notice an
ion/ directory and enter it, it's empty. I went to the Ion manual (https://doc.redox-os.org/ion-manual/) and search for config and settings, neither of which bring up what I'm looking for.
Since I couldn't find anything useful I try creating
config (which doesn't work) and
ionrc (which doesn't work) in the
.config/ion/ folder. Then I tried
.ionrc in my home directory (doesn't work), so then I try editing
~/.profile, which doesn't work.
At this point I'm wondering if ion even has a config file, so I head to the issues section to search for other people asking the same thing.
I found #47 (closed) by searching for config which leads me to this old pull request on github, https://github.com/redox-os/ion/pull/102 where I click on the pull request commit
c6c479c and notice that it uses the phrasing "init", just like issue #47 (closed) does. So I head back to the ion manual and search for init where I finally find this page https://doc.redox-os.org/ion-manual/misc/02-xdg.html and then proceed to learn that the config file should be
I then add my line
alias ls="ls --color=always" and wonder why I didn't try naming the file initrc before.
I'm can't find the config file for quite a long time and finally realize it should be called initrc.
To try and keep others from having this issue in the future I have two suggestions
- Add the word "configuration" somewhere to https://doc.redox-os.org/ion-manual/misc/02-xdg.html so that it shows up when searching for "config" or "configuration" or,
- create initrc by default (as an empty file or with a comment) so you don't have to hunt down the name or,
- look for
configfiles as well.
if looking for files, maybe something like this?
$XDG_CONFIG_HOME/ion/* (ionrc, initrc, or config),
~/.ionrc in that order.
EDIT: and as for the last sentence of the ion manual page on XDG App dirs, ion only outputs
ion: creating history file at "/home/username/.local/share/ion/history" because it only creates the history file.