Mercurial > ec-dotfiles
annotate rc/tcsh @ 134:cf328bd06078
Special check for windows. What the hell.
author | edogawaconan <edho@myconan.net> |
---|---|
date | Mon, 31 Oct 2011 11:54:49 +0700 |
parents | a7484f2c9616 |
children | 443e0004a708 |
rev | line source |
---|---|
0 | 1 #!/usr/bin/env tcsh |
74
54a82956bb11
[tcsh,setup] updated tcsh to new naming scheme.
Edho Prima Arief <me@myconan.net>
parents:
39
diff
changeset
|
2 [ -e "${HOME}/.ecos_tcsh.before" ] && source "${HOME}/.ecos_tcsh.before" |
0 | 3 umask 22 |
4 limit coredumpsize 0 | |
5 | |
6 set prompt="[%B%n@%m %~%b]%# " | |
74
54a82956bb11
[tcsh,setup] updated tcsh to new naming scheme.
Edho Prima Arief <me@myconan.net>
parents:
39
diff
changeset
|
7 set path=({,/usr}/{bin,sbin} "${HOME}"/{,.ecos_}bin) |
0 | 8 set history=1000 |
9 set savehist=1000 | |
10 set nobeep | |
11 set filec | |
12 | |
13 setenv EDITOR vi | |
14 setenv PAGER less | |
15 setenv BLOCKSIZE K | |
16 setenv LC_COLLATE C | |
17 setenv LANG en_US.UTF-8 | |
18 | |
19 unset autologout | |
20 unset autoexpand | |
21 unset autolist | |
22 unset ignoreeof | |
23 | |
24 unalias \* | |
78
06fd72a78cc1
tcsh: remote desktop alias.
Edho Prima Arief <me@myconan.net>
parents:
74
diff
changeset
|
25 alias rd "rdesktop -g 1280x700 -K -a 16 -z -P -r sound:off -r clipboard:CLIPBOARD -5" |
0 | 26 alias h history 25 |
27 alias j jobs -l | |
28 alias la ls -A | |
29 alias ll ls -lA | |
30 alias ls ls -F | |
39 | 31 alias rm rm -i |
0 | 32 |
33 if ($?prompt) then | |
34 set gnuls_opts="--color=auto --group-directories-first -F" | |
35 set iscolor=0 | |
36 switch (${TERM}) | |
37 case xterm*: | |
38 case dtterm: | |
39 case screen*: | |
40 setenv CLICOLOR | |
41 set myhost=`hostname | cut -d '.' -f 1` | |
42 set prompt="[%{\033[0;33m%}%n%{\033[0m%}@%{\033[0;32m%}%m%{\033[0m%} %{\033[1;34m%}%c%{\033[0m%}]%# " | |
43 alias mypwd 'printf "%s\n" "${PWD}" | sed -e "s#^${HOME}#~#"' | |
44 alias precmd 'printf "\033]0;${USER}@${myhost}: %s\007" "`mypwd`"' | |
45 set iscolor=1 | |
46 breaksw | |
47 endsw | |
48 | |
49 if ("$TERM" == "screen") then | |
50 bindkey '\e[1~' beginning-of-line | |
51 bindkey '\e[3~' delete-char | |
52 bindkey '\e[4~' end-of-line | |
53 bindkey '\e[5~' history-search-backward | |
54 bindkey '\e[6~' history-search-forward | |
55 bindkey '\eOD' backward-word | |
56 bindkey '\eOC' forward-word | |
57 bindkey '\e\e[D' backward-word | |
58 bindkey '\e\e[C' forward-word | |
59 endif | |
60 bindkey "^W" backward-delete-word | |
61 bindkey -k up history-search-backward | |
62 bindkey -k down history-search-forward | |
63 endif | |
64 | |
65 switch (`uname -s`) | |
66 case FreeBSD: | |
67 set path=(${path} /usr/local/{bin,sbin}) | |
68 setenv LSCOLORS ExGxFxdxCxegedabagExEx | |
69 alias ls ls -FG | |
70 ( which gnuls ) > /dev/null && alias ls gnuls ${gnuls_opts} | |
71 alias man man -o | |
39 | 72 alias rm rm -I |
90
1057412834a5
[tcsh] cooler top for freebsd
Edho Prima Arief <edho@myconan.net>
parents:
80
diff
changeset
|
73 alias top top -P |
0 | 74 breaksw |
75 case NetBSD: | |
76 set path=(${path} /usr/pkg/{bin,sbin}) | |
77 breaksw | |
105 | 78 case OpenBSD: |
0 | 79 set path=(${path} /usr/local/{bin,sbin}) |
105 | 80 setenv LSCOLORS ExGxFxdxCxegedabagExEx |
0 | 81 [ "${iscolor}" -eq 1 ] && setenv TERM xterm-256color |
105 | 82 ( which colorls ) > /dev/null && alias ls colorls -FG |
0 | 83 breaksw |
84 case DragonFly: | |
85 set path=(${path} /usr/pkg/{bin,sbin}) | |
86 setenv LSCOLORS ExGxFxdxCxegedabagExEx | |
87 alias ls ls -FG | |
88 breaksw | |
89 case SunOS: | |
90 set path=(${path} /usr/{gnu,csw,xpg4}/{bin,sbin}) | |
91 [ -x /usr/gnu/bin/ls ] && alias ls /usr/gnu/bin/ls ${gnuls_opts} | |
92 breaksw | |
93 case Linux: | |
94 alias ls ls ${gnuls_opts} | |
95 alias grep grep --color=auto | |
96 breaksw | |
97 endsw | |
98 unset gnuls_opts | |
99 | |
33 | 100 ( which vim ) > /dev/null && alias vi vim && setenv EDITOR vim |
0 | 101 |
74
54a82956bb11
[tcsh,setup] updated tcsh to new naming scheme.
Edho Prima Arief <me@myconan.net>
parents:
39
diff
changeset
|
102 [ -e "${HOME}/.ecos_tcsh.after" ] && source "${HOME}/.ecos_tcsh.after" |
80 | 103 |
104 [ -x "/usr/games/fortune" ] && "/usr/games/fortune" |