Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #!/bin/sh
- c=`pwd | sed s'#^.*/Casework/\([0-9]*\).*#\1#'`
- [ $c -lt 0 ] > /dev/null 2>&1
- if [ "$?" -eq 2 ] ; then
- exit 1;
- fi
- for d in ~/NCCs/${c}-NCC-* ; do
- n=`echo $d | sed "s#.*/NCCs/${c}-\(NCC-.*\)#\1#"`
- if [ ! -e "./$n" ]; then
- ln -s "$d" "./$n"
- echo $n " linked"
- else
- echo $n " already exist"
- fi
- done
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement