]> git.draconx.ca Git - zshconf.git/blob - zshenv
Add functions for manipulating PATH, and use them to set the default.
[zshconf.git] / zshenv
1 # Common functions used by all startup scripts.
2 #
3 # Copyright (C) 2009 Nick Bowler
4 #
5 # Copying and distribution of this file, with or without modification,
6 # are permitted in any medium without royalty provided the copyright
7 # notice and this notice are preserved.  This file is offered as-is,
8 # without any warranty.
9
10 path_front() {
11         local i
12         for i in $@; do
13                 path=($i ${path:#$i})
14         done
15 }
16
17 path_back() {
18         local i
19         for i in $@; do
20                 path=(${path:#$i} $i)
21         done
22 }