-
Notifications
You must be signed in to change notification settings - Fork 0
Home
Welcome to the ali wiki! For just now ali works and explains it self but has only an add and list funktion.. the rest of this wiki is a vision..
ali is very simple program. ali explaines it self. you can also use -h for to get help when you have a command you want to have an alias for you just write it or roll it up on the commandline and put an "ali" first on the line like this ali mycomand -option /string/etc ali will then ask you what alias you want for this command. Alernativly you write the alias together with the command separated with a = like this ali C=mycommand -anyoptions /evetuall/string Then ali will ask you if you want to add "alias C='mycommand -anyoptions /eventuall/string'" to your aliases file .bash_aliases. After you accept it will inform you if it succeded. source .bashrc to update and exit. Also you can start ali without arguments and be quized about command and then alias for that command.
The command alis will list your aliases and can be given a limiting regular expression searsh terms that search both aliases and commands. with oprands -a or -c it can match only aliases or commands. Default behaviour can be set tru match=a or match=c in the settings in the .ali file. Results of alis will be dumped to screen trough less if useless=1 is set in the config part of the ali script or the operand -l is used. The operand -# can be passed to also list the commented aliases.
alid followed of an alias will delete that alias. With the operand -# alid will only comment it out. To uncomment an alias, use.. alid -## alias. Again The operand -# can be passed to alis to also list the commented aliases.
The text strings used for the Quis and comfirmations can easyli be translated and are located in the beginning of the ali script close to the settings.
ali can also set bash to paste the actuall command to the comandline before execution if the showcommand=1 is set in the settings. This can be good for the posibility to change the commands string and explicit for educational purposes. Dont forget if you are a newbee that you might end up on a foreign mashine and not have access to your aliases. Its good to know linux, and when you feel you know that specific command you can always send it to no show with a alich -sh as you just will see.
It is possible to make a list of aliases to be shown like this by adding the operand -sh when adding the alias with ali. This behaviour will be reversed if show command is set to default with showcommand=1 set. The status of an alias in regard to this list can be changed by passing the operands -sh and -shx to alich together with the alias or a matching regular expression with the operands -r and/or -rc. Like this.. alich -sh myalias or alich -shx myalias or alich -sh -r regexp or with a regexpression for the commands with the operand -rc. So.. alich -shx -rc -r myregxpress takes away the show status of all entries that have myregexpress in either alias or command.
alie will let you edit an alias manualy and is only used with a existing alias.
All operands and even commands are easy to change in the source.
Instalation is easy just put .ali in your home folders root and source it in .bashrc by putting "include ~/.ali" in to the end of your .bashrc ali will use an existing .bash_aliases if it exists ells make and populate one. Thats it. Have fun and love linux.