]> git.madduck.net Git - etc/zsh.git/blob - .zsh/zshrc/90_cleanfiles

madduck's git repository

Every one of the projects in this repository is available at the canonical URL git://git.madduck.net/madduck/pub/<projectpath> — see each project's metadata for the exact URL.

All patches and comments are welcome. Please squash your changes to logical commits before using git-format-patch and git-send-email to patches@git.madduck.net. If you'd read over the Git project's submission guidelines and adhered to them, I'd be especially grateful.

SSH access, as well as push access can be individually arranged.

If you use my repositories frequently, consider adding the following snippet to ~/.gitconfig and using the third clone URL listed for each project:

[url "git://git.madduck.net/madduck/"]
  insteadOf = madduck:

0aa9df9f3364c53d1e8a3779bd04238e051f9987
[etc/zsh.git] / .zsh / zshrc / 90_cleanfiles
1 # zlogout/90_cleanfiles
2 #
3 # remove files we never want to keep around
4 #
5 # Copyright © 1994–2008 martin f. krafft <madduck@madduck.net>
6 # Released under the terms of the Artistic Licence 2.0
7 #
8 # Source repository: http://git.madduck.net/v/etc/zsh.git
9 #
10
11 typeset -la rmfiles
12
13 rmfiles+=~/plugin131.trace
14 rmfiles+=~/minicom.log
15 rmfiles+=~/.cshrc
16 rmfiles+=~/java.log.*(N)
17 rmfiles+=~/unison.log
18 rmfiles+=~/.bzr.log
19 rmfiles+=~/.fonts.cache-1
20 rmfiles+=~/.gksu.lock
21 rmfiles+=~/.*.sw[mnop](N)
22 rmfiles+=~/.viminfo
23 rmfiles+=~/.bash_history
24 rmfiles+=~/core
25 rmfiles+=~/nohup.out
26 rmfiles+=~/typescript
27 rmfiles+=~/jpilot.log
28 rmfiles+=~/srtp.log
29 rmfiles+=~/hs_err_pid[0-9]*.log
30
31 typeset -la _rmfiles
32
33 for f in ${~rmfiles}; do
34   [[ -f $f ]] || continue
35   _rmfiles+="$f"
36 done
37
38
39 if (( $#_rmfiles )); then
40   _rmfiles=(${_rmfiles#$HOME/})
41   info "Removing files: ${_rmfiles[@]}..."
42   rm -f ${_rmfiles[@]}
43 fi
44
45 unset _rmfiles
46
47 # vim:ft=zsh