diff options
31 files changed, 17 insertions, 197 deletions
diff --git a/01_Functions.zsh b/01_Functions.zsh index 4caa5dc..f781358 100644 --- a/01_Functions.zsh +++ b/01_Functions.zsh @@ -19,11 +19,11 @@ cmd_exists () { - which -p $1 >/dev/null 2>&1 + \which -p $1 >/dev/null 2>&1 } git () { - GIT=$(which -p git) + GIT=$(\which -p git) case $1 in init|clone|config) ;; @@ -38,7 +38,7 @@ git () { ;; esac - $(which -p git) $@ + $(\which -p git) $@ } term_title() @@ -195,7 +195,7 @@ get_git_branch () if [ "$REBASE_DIR" = "$GIT_DIR/rebase-merge" ] then current=$(< $REBASE_DIR/done wc -l) - last=$(( $current + $(< $REBASE_DIR/git rebase-todo grep -v "^#\|^[[:blank:]]*$" | wc -l) )) + last=$(( $current + $(< $REBASE_DIR/git-rebase-todo grep -v "^#\|^[[:blank:]]*$" | wc -l) )) rebase=$rebase$rebase_in_progress": " else current=$(cat $REBASE_DIR/next) diff --git a/10_Environment.zsh b/10_Environment.zsh index a64c5e3..090b38a 100644 --- a/10_Environment.zsh +++ b/10_Environment.zsh @@ -62,9 +62,15 @@ typeset -gU PATH MANPATH INFOPATH PKG_CONFIG_PATH LD_LIBRARY_PATH ## Gestion de l'historique # Voir le fichier d'Options pour plus de contrôle là-dessus -HISTFILE=$ZDOTDIR/.history.$USER.$HOST # Pour éviter les conflits de conf -HISTSIZE=42000 +if [ -w $ZDOTDIR ] +then + HISTFILE=$ZDOTDIR/.history.$USER.$HOST # Pour éviter les conflits de conf +else + HISTFILE=~$USER/.zsh.history.$HOST +fi + SAVEHIST=42000 +HISTSIZE=$(( $SAVEHIST * 1.10 )) export GPG_TTY=`tty` diff --git a/20_Options.zsh b/20_Options.zsh index 89e117c..cb25a94 100644 --- a/20_Options.zsh +++ b/20_Options.zsh @@ -13,6 +13,10 @@ # see man zshoptions(1) for more details ;-) # +# Funky run-help hooks +autoload run-help-git +autoload run-help-svn + function SetOPT() { SetOPTifExists $1 on } diff --git a/host:groumpf/Colors.zsh b/host:groumpf/Colors.zsh deleted file mode 100644 index ef903a1..0000000 --- a/host:groumpf/Colors.zsh +++ /dev/null @@ -1,7 +0,0 @@ - -#PS1_USER=$color[red] -#PS1_ROOT=$color[black] - -PS1_USER="38;5;69" -PS1_ROOT=$color[red] - diff --git a/host:rmm-p1197486 b/host:rmm-p1197486 deleted file mode 120000 index f35a2fa..0000000 --- a/host:rmm-p1197486 +++ /dev/null @@ -1 +0,0 @@ -net:sagem.ads.sagem
\ No newline at end of file diff --git a/host:woot/Colors.zsh b/host:woot/Colors.zsh deleted file mode 100644 index e1ac0a9..0000000 --- a/host:woot/Colors.zsh +++ /dev/null @@ -1,7 +0,0 @@ - -#PS1_USER=$color[red] -#PS1_ROOT=$color[black] - -PS1_USER="38;5;36" -PS1_ROOT=$color[red] - diff --git a/net:eurodec/Environment.zsh b/net:eurodec/Environment.zsh deleted file mode 100644 index a70c7b4..0000000 --- a/net:eurodec/Environment.zsh +++ /dev/null @@ -1,15 +0,0 @@ -export m_SVIM=/users/picard/local/share/vim/syntax -export m_VIM_USER_NAME="H. Hiegel" - -export LOGCHECK=0 # Don't want to get fucked up by this trick... - -hash -d data=/data/$USER -#hash -d workset=~data/workset -hash -d targets=/targets/$USER - -eval $(~data/sagem-script44/set-env.pl 2>/dev/null) && source ~/.env - -export TARGET_PATH=~targets/target -export KERNEL_PATH=~data/forge/kernel-$(cat ~data/workset/project.txt) -export KERNEL_PATH_BASE=~data/forge/kernel- -export COMP=ARCH=sh\ CROSS_COMPILE=sh4-linux-uclibc- diff --git a/net:eurodec/Hashes.zsh b/net:eurodec/Hashes.zsh deleted file mode 100644 index e69de29..0000000 --- a/net:eurodec/Hashes.zsh +++ /dev/null diff --git a/net:eurodec/Prompts.zsh b/net:eurodec/Prompts.zsh deleted file mode 120000 index 3cf29e6..0000000 --- a/net:eurodec/Prompts.zsh +++ /dev/null @@ -1 +0,0 @@ -../net:osn.sagem/Prompts.zsh
\ No newline at end of file diff --git a/net:eurodec/host:osn08002/Environment.zsh b/net:eurodec/host:osn08002/Environment.zsh deleted file mode 100644 index d21d723..0000000 --- a/net:eurodec/host:osn08002/Environment.zsh +++ /dev/null @@ -1,6 +0,0 @@ - -[ "$TERM" = "rxvt-unicode" ] && export TERM=rxvt-color - - -PS1_USER=$color[white] - diff --git a/net:eurodec/user:g178241 b/net:eurodec/user:g178241 deleted file mode 120000 index ecec344..0000000 --- a/net:eurodec/user:g178241 +++ /dev/null @@ -1 +0,0 @@ -../user:hugues
\ No newline at end of file diff --git a/net:example.com/Aliases.zsh b/net:example.com/Aliases.zsh deleted file mode 100644 index f7e6048..0000000 --- a/net:example.com/Aliases.zsh +++ /dev/null @@ -1,6 +0,0 @@ - -# Marre de se faire avoir avec la reconstruction de la BDD -a cscope='cscope -d' - -# Ptit alias bien pratique, pour afficher rapidos les patches appliqués et ceux qui ne le sont pas -a q='quilt applied ; echo " -- TOP -- " ; quilt unapplied' diff --git a/net:example.com/Environment.zsh b/net:example.com/Environment.zsh deleted file mode 100644 index d86a417..0000000 --- a/net:example.com/Environment.zsh +++ /dev/null @@ -1,33 +0,0 @@ -## -## Part of configuration files for Zsh 4 -## by Hugues Hiegel <hugues@hiegel.fr> -## -## NO WARRANTY PROVIDED, USE AT YOUR OWN RISKS -## -## You are encouraged to use, modify, and redistribute -## these files with or without this notice. -## - -## Mettez le nom de votre station de travail habituelle ici ## -if [ ! -e ~/.workstation ] -then - echo >&2 "Quelle est votre station de travail attitrée ? (`hostname -s`) " && read $workstation - echo ${workstation:-$(hostname -s)} > ~/.workstation -fi -WORKSTATION=$(cat ~/.workstation) - -export LC_ALL=fr_FR -[ "$TERM" = "rxvt-unicode" ] && export TERM=rxvt - -#export PATH=${PATH:+$PATH:}~/souche_linux_pl/tools/bin:/usr/local/urd2/bin:/usr/local/urd2/openrg2_6/mips-linux-uclibc/bin/ -#export LD_LIBRARY_PATH=${LD_LIBRARY_PATH:+$LD_LIBRARY_PATH:}~/souche_linux_pl/tools/lib -#export MANPATH=${MANPATH:+$MANPATH:}/usr/local/urd2/man:~/souche_linux_pl/tools/man:~/souche_linux_pl/tools/share/man - -PATH=$PATH:/opt/edtm/bin -PATH=$PATH:/opt/openrg/mips-linux-uclibc/bin -typeset -gU PATH MANPATH - -#__PREFIX=/filer1/dev_users/hiegel/souche_linux_pl/tools/ - -export http_proxy="http://proxy:3128" -export ftp_proxy=$http_proxy diff --git a/net:example.com/Hashes.zsh b/net:example.com/Hashes.zsh deleted file mode 100644 index ef2666f..0000000 --- a/net:example.com/Hashes.zsh +++ /dev/null @@ -1,6 +0,0 @@ -hash -d dev=/developpement/$WORKSTATION/sagem-box/$(whoami) -hash -d public=/public/$WORKSTATION -hash -d Public=/public/$(hostname -s) -hash -d archives=/projets/sagem-box/archives -hash -d doc=/projets/sagem-box/doc -hash -d tftp=/public/$WORKSTATION/tftp diff --git a/net:example.com/KeyBindings.zsh b/net:example.com/KeyBindings.zsh deleted file mode 100644 index 0691d95..0000000 --- a/net:example.com/KeyBindings.zsh +++ /dev/null @@ -1,5 +0,0 @@ - -# Lance l'alias ``q'' (voir le fichier d'aliases) pour -# afficher rapidement la pile des patches, avec une marque -# au niveau du dernier patch appliqué. - diff --git a/net:lan.theoris.fr/Colors.zsh b/net:lan.theoris.fr/Colors.zsh deleted file mode 100644 index f0ec6fc..0000000 --- a/net:lan.theoris.fr/Colors.zsh +++ /dev/null @@ -1,6 +0,0 @@ -if [ "$TMUX" != "" ] -then - PS1_USER="38;5;53" -else - PS1_USER="38;5;40" -fi diff --git a/net:lan.theoris.fr/Environment.zsh b/net:lan.theoris.fr/Environment.zsh deleted file mode 100644 index 05be04d..0000000 --- a/net:lan.theoris.fr/Environment.zsh +++ /dev/null @@ -1 +0,0 @@ -export MUSICPLAYER=audacious diff --git a/net:opera.openwide.fr/Sanity.zsh b/net:opera.openwide.fr/Sanity.zsh deleted file mode 100644 index 300e92f..0000000 --- a/net:opera.openwide.fr/Sanity.zsh +++ /dev/null @@ -1 +0,0 @@ -umask 002 diff --git a/net:opera.openwide.fr/host:groumpf b/net:opera.openwide.fr/host:groumpf deleted file mode 120000 index 3f46d13..0000000 --- a/net:opera.openwide.fr/host:groumpf +++ /dev/null @@ -1 +0,0 @@ -../host:groumpf
\ No newline at end of file diff --git a/net:opera.openwide.fr/host:openwide-desktop/Environment.zsh b/net:opera.openwide.fr/host:openwide-desktop/Environment.zsh deleted file mode 100644 index f5588d0..0000000 --- a/net:opera.openwide.fr/host:openwide-desktop/Environment.zsh +++ /dev/null @@ -1,4 +0,0 @@ - -PS1_USER=$color[yellow] - -source /etc/dash.conf diff --git a/net:opera.openwide.fr/host:patate/user:hugues/Aliases.zsh b/net:opera.openwide.fr/host:patate/user:hugues/Aliases.zsh deleted file mode 100644 index a2832cd..0000000 --- a/net:opera.openwide.fr/host:patate/user:hugues/Aliases.zsh +++ /dev/null @@ -1,3 +0,0 @@ - -a vim=$EDITOR - diff --git a/net:opera.openwide.fr/host:patate/user:hugues/Environment.zsh b/net:opera.openwide.fr/host:patate/user:hugues/Environment.zsh deleted file mode 100644 index 7862fa1..0000000 --- a/net:opera.openwide.fr/host:patate/user:hugues/Environment.zsh +++ /dev/null @@ -1,3 +0,0 @@ -export EDITOR=~/sbin/vim -export VISUAL=$EDITOR -export FCEDIT=$EDITOR diff --git a/net:opera.openwide.fr/host:vlab/Environment.zsh b/net:opera.openwide.fr/host:vlab/Environment.zsh deleted file mode 100644 index 17a5003..0000000 --- a/net:opera.openwide.fr/host:vlab/Environment.zsh +++ /dev/null @@ -1,3 +0,0 @@ - -PS1_USER=$color[red] - diff --git a/net:osn.sagem/Prompts.zsh b/net:osn.sagem/Prompts.zsh deleted file mode 100644 index eae5bfa..0000000 --- a/net:osn.sagem/Prompts.zsh +++ /dev/null @@ -1,13 +0,0 @@ - -redisplay_prompt () -{ - # Reprise du redisplay_prompt officiel + ajout du mode workset - - local KERNEL_MODE - [ -e ../../kernel_mode.txt ] && KERNEL_MODE="$C_$color[bg-black];$color[blue]$_C `cat ../../kernel_mode.txt` $C_$prompt_colors[generic]$_C " - - PS1="$AGENTS""$MAILSTAT""$ERROR""$BATTERY"$C_$prompt_colors[bar]$_C"$HBAR""$DATE -"$C_$prompt_colors[user]$_C"%n"$C_$prompt_colors[arob]$_C"@"$C_$prompt_colors[host]$_C"%m $CURDIR$SVNREV$GITBRANCH $KERNEL_MODE"$C_$prompt_colors[dies]$_C"%#"$C_$prompt_colors[cmd]$_C" " -} - - diff --git a/net:osn.sagem/host:osnp1260077/Environment.zsh b/net:osn.sagem/host:osnp1260077/Environment.zsh deleted file mode 100644 index f868f12..0000000 --- a/net:osn.sagem/host:osnp1260077/Environment.zsh +++ /dev/null @@ -1,3 +0,0 @@ - -export PATH=$PATH:/opt/openoffice.org3/program - diff --git a/net:osn.sagem/host:osnp1260077/user:g178241 b/net:osn.sagem/host:osnp1260077/user:g178241 deleted file mode 120000 index 5f7df0c..0000000 --- a/net:osn.sagem/host:osnp1260077/user:g178241 +++ /dev/null @@ -1 +0,0 @@ -user:hugues/
\ No newline at end of file diff --git a/net:osn.sagem/host:osnp1260077/user:hugues/Environment.zsh b/net:osn.sagem/host:osnp1260077/user:hugues/Environment.zsh deleted file mode 100644 index 26ddb04..0000000 --- a/net:osn.sagem/host:osnp1260077/user:hugues/Environment.zsh +++ /dev/null @@ -1,53 +0,0 @@ -#--------[ UserDir ]------------------------------------------------- -[ "$LOGNAME" = "g178241" ] && HOME=~hugues - -#--------[ Hashes ]------------------------------------------------- -hash -d work=~/Wr0k -hash -d targets=/targets -hash -d tools=~work/t00lz - -#--------[ Generic Config ]----------------------------------------- -#eval $(~tools/sagem-script44/set-env.pl 2>/dev/null) -source ~/.env - -#--------[ Specific Config ]---------------------------------------- - -#STLinux 2.2 -#export STLINUXRELEASE=${STLINUXRELEASE:-2.2} -#export ST40RELEASE=${ST403RELEASE:-3.1.1_patch1} -#STLinux 2.3 -export STLINUXRELEASE=${STLINUXRELEASE:-2.3} -export ST40RELEASE=${ST403RELEASE:-4.1.1} - -export STLINUXBASE=/opt/STM/STLinux-$STLINUXRELEASE -export STLINUXROOT=$STLINUXBASE/devkit/sh4/ - -#export FORGE=http://g178241@forge-urd44.osn.sagem/svn/ -export GET_KERNEL_METHOD=svn -#export GET_KERNEL_METHOD=git - -export KERNEL_PATH_BASE=~work/Kernel/exports/ -export COMP=ARCH=sh\ CROSS_COMPILE=sh4-linux- -export TARGET_PATH=~targets/target - - -export THIRDPARTYLIBS=~work/3rdparty/lib - -export PATH=$PATH:$STLINUXROOT/bin -export PATH=$PATH:$STLINUXBASE/host/bin -export PATH=$PATH:/opt/STM/ST40R$ST40RELEASE/bin -export PATH=~/local/bin:~/local/sbin:$PATH - -#--------[ Shared Folders ]----------------------------------------- -hash -d K:=/media/osn01001/Projets_STB -hash -d J:=/media/osn02001/Echanges - -# proxy -if cmd_exists tsocks -then - . tsocks -on -else - export http_proxy="http://190.99.3.97:3128" - export ftp_proxy=$http_proxy -fi - diff --git a/net:osn.sagem/user:g178241 b/net:osn.sagem/user:g178241 deleted file mode 120000 index 1941e64..0000000 --- a/net:osn.sagem/user:g178241 +++ /dev/null @@ -1 +0,0 @@ -../user:hugues/
\ No newline at end of file diff --git a/net:osn.sagem/user:root/Exec.zsh b/net:osn.sagem/user:root/Exec.zsh deleted file mode 100644 index 6522a96..0000000 --- a/net:osn.sagem/user:root/Exec.zsh +++ /dev/null @@ -1,3 +0,0 @@ - -< /var/log/sudo.log sed 's/^\([^ ]\)/---> \1/' | awk 'BEGIN { RS="---> " ; FS=" ;" } ! /COMMAND=\/usr\/bin\/zsh/ { printf $0 }' > /var/log/.sudo.log && mv -f /var/log/.sudo.log /var/log/sudo.log - diff --git a/net:sagem.ads.sagem/Colors.zsh b/net:sagem.ads.sagem/Colors.zsh deleted file mode 100644 index ce8fe26..0000000 --- a/net:sagem.ads.sagem/Colors.zsh +++ /dev/null @@ -1,6 +0,0 @@ -if [ "$TMUX" != "" ] -then - PS1_USER="38;5;55" -else - PS1_USER="38;5;54" -fi diff --git a/user:hugues/Environment.zsh b/user:hugues/Environment.zsh index bfb341d..6dc32aa 100644 --- a/user:hugues/Environment.zsh +++ b/user:hugues/Environment.zsh @@ -23,7 +23,7 @@ export GIT_COMMITTER_NAME=$FULLNAME export BC_ENV_ARGS="-q" ## Editeur par défaut -export EDITOR=`which -p vim || which -p vi || which -p emacs` +export EDITOR=`\which -p vim || \which -p vi || \which -p emacs` export VISUAL=$EDITOR export FCEDIT=$EDITOR |