[Bug 1186284] [NEW] Add a mechanism to add systemwide aliases
Luc Pionchon
pionchon.luc at gmail.com
Fri May 31 14:50:48 UTC 2013
Public bug reported:
I am making a package that contains bash aliases.
The aliases should be available system wide in all bash interactive shells
I found nowhere to install them:
- /etc/bash.bashrc
will be overwritten by the next bash upgrade
- /etc/profile.d/my-aliases.sh
affects login shells but not interactive shells
- /etc/bash_completion.d/my-aliases.sh
works, but this is a hack.
I wish there would be a directory:
/etc/bash.bashrc.d/ where we can install bash-files.sh
and /etc/bash.bashrc would source them:
if [ -d /etc/bash.bashrc.d ]; then
for ii in /etc/bash.bashrc.d/*.sh; do
if [ -r $ii ]; then
. $ii
fi
done
unset ii
fi
(Or is there an existing place or a way to get these aliases in all user interactive shells?)
** Affects: bash (Ubuntu)
Importance: Undecided
Status: New
--
You received this bug notification because you are a member of Ubuntu
Foundations Bugs, which is subscribed to bash in Ubuntu.
https://bugs.launchpad.net/bugs/1186284
Title:
Add a mechanism to add systemwide aliases
Status in “bash” package in Ubuntu:
New
Bug description:
I am making a package that contains bash aliases.
The aliases should be available system wide in all bash interactive shells
I found nowhere to install them:
- /etc/bash.bashrc
will be overwritten by the next bash upgrade
- /etc/profile.d/my-aliases.sh
affects login shells but not interactive shells
- /etc/bash_completion.d/my-aliases.sh
works, but this is a hack.
I wish there would be a directory:
/etc/bash.bashrc.d/ where we can install bash-files.sh
and /etc/bash.bashrc would source them:
if [ -d /etc/bash.bashrc.d ]; then
for ii in /etc/bash.bashrc.d/*.sh; do
if [ -r $ii ]; then
. $ii
fi
done
unset ii
fi
(Or is there an existing place or a way to get these aliases in all user interactive shells?)
To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/bash/+bug/1186284/+subscriptions
More information about the foundations-bugs
mailing list