To include a script in a ~/.bashrc is very simple. Just use either of two methods.
One.
source /usr/share/landscape/landscape-sysinfo.wrapper |
Or this simpler method.
. /usr/share/landscape/landscape-sysinfo.wrapper |
Either of these methods will work. This is an easy way to include a script in your ~/.bashrc and run it.
if [ -f ~/.bash_aliases ]; then . ~/.bash_aliases fi |
As seen above the if statement here checks if the file exists before trying to include it. That would be a very good way to do this properly.
Or this example, try 2 separate files.
# enable programmable completion features (you don't need to enable # this, if it's already enabled in /etc/bash.bashrc and /etc/profile # sources /etc/bash.bashrc). if ! shopt -oq posix; then if [ -f /usr/share/bash-completion/bash_completion ]; then . /usr/share/bash-completion/bash_completion elif [ -f /etc/bash_completion ]; then . /etc/bash_completion fi fi |