Debian 13 trixie

Initial Settings : Set Command Alias2025/08/11

 

Set Command Alias for some commands that are often used.

[1] Apply to all users as defaults.
root@localhost:~#
vi /etc/profile.d/command_alias.sh
# create new file
# add alias you'd like to set

alias ll='ls $LS_OPTIONS -l'
alias l='ls $LS_OPTIONS -lA'
alias rm='rm -i'
alias cp='cp -i'
alias mv='mv -i'
# reload

root@localhost:~#
source /etc/profile.d/command_alias.sh

[2] Apply to a user.
For example, a user [trixie] applies alias for itself.
trixie@localhost:~$
vi ~/.bashrc
# add to the end : add alias you'd like to set

alias ll='ls $LS_OPTIONS -l'
alias l='ls $LS_OPTIONS -lA'
alias rm='rm -i'
alias cp='cp -i'
alias mv='mv -i'
trixie@localhost:~$
source ~/.bashrc

Matched Content