Page 1 of 3
This should be fun. Share your alias collection. :)
Posted: Wed Jan 20, 2016 1:11 am
by KernSpy
Just think it might be fun to share Aliases and bashrc files. Perhaps some of you
gearheads don't even use bash anymore? It would be nice to see what nifty aliases
you folks have created.
Just thought it might be fun ..
Kern...
Re: This should be fun. Share your alias collection. :)
Posted: Wed Jan 20, 2016 2:02 am
by Eadwine Rose
My alias has been the same ever since I hopped on the internet. Either Eadwine, or Eadwine Rose (back when I needed a last name for yahoo

)
Re: This should be fun. Share your alias collection. :)
Posted: Wed Jan 20, 2016 3:47 am
by i_ri
hello KernSpy and yours? you currently have a great avatar.
. here and hithere. b e t t y @ b o o p H . o m e , Workgroup =NONEJOINED. errrr, can we start another thread about favorite passwords? That's where we really shine.
Re: This should be fun. Share your alias collection. :)
Posted: Wed Jan 20, 2016 6:47 am
by KernSpy
My .bashrc doesn't have many entries.
sudo apt-get update .. saud
sudo apt-get dist-upgrade .. saug
sudo apt-get install .. install
clear screen .. cls
la .. ls -Al
ps .. ps auxf
That is pretty much it.
I dl'ed the Ultimate bashrc, so that should be interesting.
Kern ..
Re: This should be fun. Share your alias collection. :)
Posted: Wed Jan 20, 2016 7:56 am
by Jerry3904
The only one I have was worked out by a some people here a couple of years ago for use in a terminal as regular user (F4):
alias up='su -c "apt-get update && apt-get dist-upgrade"'
Re: This should be fun. Share your alias collection. :)
Posted: Wed Jan 20, 2016 8:11 am
by KernSpy
Jerry3904 wrote:The only one I have was worked out by a some people here a couple of years ago for use in a terminal as regular user (F4):
alias up='su -c "apt-get update && apt-get dist-upgrade"'
Hi Jerry, that is a good one. I had to "su --help" to check and see
what the -c was for. It is to:
Options: -c, --command COMMAND pass COMMAND to the invoked shell
Thanks!

Re: This should be fun. Share your alias collection. :)
Posted: Wed Jan 20, 2016 11:01 am
by DBeckett
I've used the same .bashrc for years, mostly to colorize the display.
alias ls='ls -al --color=auto'
screengrab3.png
Re: This should be fun. Share your alias collection. :)
Posted: Wed Jan 20, 2016 2:07 pm
by KernSpy
Thanks .. DBeckett

Re: This should be fun. Share your alias collection. :)
Posted: Wed Jan 20, 2016 2:31 pm
by Topher
I used to have an alias to create a list of all installed software but had to change it to a script so that LuckyBackup would run it when I did my back ups. Others have added on to the original to do the same thing but create slightly different outputs.
dpkg --get-selections > /home/chris/Documents/Computer/My_Sys_Info/MX-pkg-list.txt
dpkg -l > /home/chris/Documents/Computer/My_Sys_Info/MX-pkg-list2.txt
dpkg -l | awk '/^ii/{ print $2 }' | grep -v -e ^lib -e -dev -e linux-image -e linux-headers > /home/chris/Documents/My_Sys_Info/MX-pkg-list3.txt
Re: This should be fun. Share your alias collection. :)
Posted: Wed Jan 20, 2016 4:03 pm
by anticapitalista
MX-15 ships with a few by default.
Code: Select all
#apt-get
alias agu="apt-get update"
alias agd="apt-get dist-upgrade"
alias agc="apt-get clean"
alias ag="apt-get update;apt-get dist-upgrade"
Here are some of what I use on antiX
Code: Select all
# inxi
alias inF="inxi -F"
alias inS="inxi -s"
alias inW="inxi -xxx -W Thessaloniki,Greece"
alias inG="inxi -G"
alias inR="inxi -r"
alias inP="inxi -plou"
alias inA="inxi -A"
alias inI="inxi -i"
alias inN="inxi -nx"
alias inD="inxi -xx -S"
alias inFx="inxi -Fxx"
# Various
alias df="df -Th"
alias du="du -h -c > sizes.txt"
alias ins="dpkg -l > installed.txt"
#Git commands
alias gfu="git fetch upstream"
alias gmu="git merge upstream/master"
alias gadd="git add ."
alias grm="git rm"
alias gcom="git commit -m"
alias gpom="git push origin master"
alias gstat="git status"
alias gdiff="git diff"
alias glog="git log"
alias gdiffh="git diff HEAD^"
# Creates an archive from given directory
mktar() { tar cvf "${1%%/}.tar" "${1%%/}/"; }
mktgz() { tar cvzf "${1%%/}.tar.gz" "${1%%/}/"; }
mktbz() { tar cvjf "${1%%/}.tar.bz2" "${1%%/}/"; }
# Easy extract
# uncompress depending on extension...
extract() {
if [ -f "$1" ] ; then
case "$1" in
*.tar.bz2) tar xvjf "$1" ;;
*.tar.gz) tar xvzf "$1" ;;
*.tar.xz) tar xvJf "$1" ;;
*.bz2) bunzip2 "$1" ;;
*.rar) unrar x "$1" ;;
*.gz) gunzip "$1" ;;
*.tar) tar xvf "$1" ;;
*.tbz2) tar xvjf "$1" ;;
*.tgz) tar xvzf "$1" ;;
*.zip) unzip "$1" ;;
*.Z) uncompress "$1" ;;
*.7z) 7z x "$1" ;;
*)
echo "'$1' cannot be extracted"
return 1
;;
esac
else
echo "'$1' is not a valid file"
return 1
fi
return 0
}