Using Alias in Ubuntu Scripts [duplicate]
I'm trying to make an alias for my shell script which is saved in ~/Dokumente/music.sh
Therefore, I added following line to ~/.bash_aliases
:
alias music='.//home/robin/Dokumente/music.sh'
After saving, I executed source ~/.bash_aliases
.
I think the alias itself is working fine, but ./ doesn't find the file. Why? I've tried multiple things (e.g. ~/Dokumente/music.sh
) but nothing works.
I can execute the script when I type ./music.sh
within the containing folder. That shouldn't be the point…
I want the script being executable from any direction with this user.
Any help would be appreciated!
Try:
alias music='/home/robin/Dokumente/music.sh'
the ./
part usually denotes current directory, so a relative path.