I am looking for a simple way to create a permanent alias for all users. So
~/.bash_profile is not an option.
Hasn't anybody created a program for this? I think it should be a very common need. If not, I can always create a custom Bash script, but I need to know if there is a equivalent of .bash_profile for all users.
In my case, I am using Mac OS X v10.9 (Mavericks) and Ubuntu 12.04 (Precise Pangolin), but I would like a method that works on major Unix systems.
UPDATE: I was wondering about a program which automatically allows the users to manage a list of permanent of aliases directly from the command-line without having to edit files. It would have options for setting for all users, target users, interative/login shell, etc.
UPDATE 2: Reply to answer of @jimmij
$ su -m Password: # cat /etc/profile alias test343="echo working" # cat /etc/bash.bashrc alias test727="echo working" # test727 bash: test727: command not found # test343 bash: test343: command not found