tasty changes to the inventory command, which now has that name instead of just 'i'.
[feisty_meow.git] / scripts / core / common.alias
1 #!/bin/bash
2 ##############
3 # Name   : common.alias
4 # Author : Chris Koeritz
5 # Rights : Copyright (C) 1988-$now by Author
6 ##############
7 # This script is free software; you can modify/redistribute it under the terms
8 # of the GNU General Public License. [ http://www.gnu.org/licenses/gpl.html ]
9 # Feel free to send updates to: [ fred@gruntose.com ]
10 ##############
11
12 # a list of core aliases for feisty meow codebase.
13
14 # repurposes certain commands that feisty meow does a little differently.
15 alias cls='clear_colormap; clear'
16 alias copy='\cp -i -v '
17 alias cp='\cp -i -v '
18 alias cvs='perl $FEISTY_MEOW_SCRIPTS/rev_control/cvs_fix.pl'
19 alias del='perl $FEISTY_MEOW_SCRIPTS/files/safedel.pl'
20 alias deltree='perl $FEISTY_MEOW_SCRIPTS/files/safedel.pl'
21 alias df='\df -mh'
22 alias dir='perl $FEISTY_MEOW_SCRIPTS/files/summing_dir.pl'
23 alias du='\du -h'
24 alias erase='perl $FEISTY_MEOW_SCRIPTS/files/safedel.pl'
25 # elaborate replacement for filesystem explorer command, which we have
26 # shortened to "exp".
27 if [ "$OS" != "Windows_NT" ]; then
28   if [ -n "$IS_DARWIN" ]; then
29     # case for mac os x.
30     alias exp='open'
31   elif [ ! -z "$(which nautilus)" ]; then
32     # we prefer nautilus if available.
33     alias exp='nautilus'
34   else
35     # last ditch is konqueror browser.
36     alias exp='konqueror'
37   fi
38 else
39   # windows gets routed to our helpful script instead.
40   alias exp="bash $FEISTY_MEOW_SCRIPTS/winders/exploder.sh"
41 fi
42 # re-use work we did on 'exp' macro for the longer windows command.
43 alias explorer=exp
44 alias i=inventory
45 alias l='perl $FEISTY_MEOW_SCRIPTS/files/summing_dir.pl'
46 alias ll='\ls -hFC $color_add'
47 alias ls='perl $FEISTY_MEOW_SCRIPTS/files/summing_dir.pl'
48 #='\ls -hFC $color_add'
49 alias lsd='ls -hl'
50 alias md='mkdir'
51 alias more='less'
52 alias move='mv -i -v '
53 alias mv='\mv -i -v '
54 alias notepad='gedit'
55 alias pwd="/bin/pwd|sed -e 's/^\/home\/$USER/~/'"
56 alias rd='perl $FEISTY_MEOW_SCRIPTS/files/zapdirs.pl'
57 alias ren='\mv -v -i '
58 alias rm='perl $FEISTY_MEOW_SCRIPTS/files/safedel.pl'
59 alias rmdir='perl $FEISTY_MEOW_SCRIPTS/files/zapdirs.pl'
60 alias s='echo "##############"'
61 alias path='echo $PATH'
62 alias whence=which
63
64 ##############
65
66 # some aliases that are just generally nice to have.
67 alias aliases=alias
68 alias calc='kcalc'
69 alias cd..='\cd ..'
70 alias cd...='\cd ../..'
71 alias cd....='\cd ../../..'
72 alias cd.....='\cd ../../../..'
73 alias mo='less'
74 alias np='gvim'
75 alias up='cd ..'
76
77 ##############
78
79 # extended aliases for meta-operations.
80 alias dvd_rip='vobcopy -m'
81 alias blu_rip='echo "what would this command be?"'
82 alias mplayer='\mplayer -ao arts'
83 alias play='bash $FEISTY_MEOW_SCRIPTS/multimedia/sound_play.sh'
84
85 ##############
86
87 # some really eccentric feisty meow aliases...
88
89 # says goodbye when leaving a shell.
90 alias bye='. $FEISTY_MEOW_SCRIPTS/users/goodbye.sh'
91 alias cputemp='acpi -t'
92 # makes root user's home directory's permissions right.
93 alias reroot='chown -R root:root /root'
94 # yes, these are really helpful...
95 alias whoareyou='echo -e "Hello, I am a computer named $(hostname)\nand I'\''m very pleased to meet you."'
96 alias whereami='echo whoa dude, try not to think about it...'
97 alias why='echo just because.'
98
99 # done with loading up regular aliases now...
100
101 ##############
102
103 # call the generated aliases file, if it exists.
104 if [ -f "$FEISTY_MEOW_GENERATED/fmc_aliases_for_scripts.sh" ]; then 
105   if [ ! -z "$SHELL_DEBUG" ]; then echo loading script aliases...; fi
106   source "$FEISTY_MEOW_GENERATED/fmc_aliases_for_scripts.sh"
107   if [ ! -z "$SHELL_DEBUG" ]; then echo done loading script aliases.; fi
108 fi
109
110 ##############
111
112 # remove the fredization macro if it was defined, helping to avoid running
113 # the shell scripts twice for users like root that don't always load this
114 # stuff.
115 unalias fredme &>/dev/null
116
117 ##############
118
119 # set the sentinel variable that says this file was handled.
120 export CORE_ALIASES_LOADED=true
121
122 ##############
123