source: npl/overig/mc/profile.d/mc-wrapper.sh @ 128fde4

gcc484perl-5.22
Last change on this file since 128fde4 was c5c522c, checked in by Edwin Eefting <edwin@datux.nl>, 8 years ago

initial commit, transferred from cleaned syn3 svn tree

  • Property mode set to 100644
File size: 315 bytes
Line 
1MC_USER=`id | sed 's/[^(]*(//;s/).*//'`
2MC_PWD_FILE="${TMPDIR-/tmp}/mc-$MC_USER/mc.pwd.$$"
3/usr/bin/mc -P "$MC_PWD_FILE" "$@"
4
5if test -r "$MC_PWD_FILE"; then
6        MC_PWD="`cat "$MC_PWD_FILE"`"
7        if test -n "$MC_PWD" && test -d "$MC_PWD"; then
8                cd "$MC_PWD"
9        fi
10        unset MC_PWD
11fi
12
13rm -f "$MC_PWD_FILE"
14unset MC_PWD_FILE
Note: See TracBrowser for help on using the repository browser.