]> TLD Linux GIT Repositories - tld-ftp-admin.git/commitdiff
- comment out unused code
authorMarcin Krol <hawk@tld-linux.org>
Wed, 10 Jan 2024 20:08:48 +0000 (21:08 +0100)
committerMarcin Krol <hawk@tld-linux.org>
Wed, 10 Jan 2024 20:08:48 +0000 (21:08 +0100)
shell/bash_profile

index 45d0bacdafc12471ef132e173a93e37337c6c78d..eda55011e0ae0ee58313877cf1636bf34974ba84 100644 (file)
@@ -8,25 +8,25 @@
 #esac
 
 # identify via terminal last login (su, sudo)
-if [ -z "$FTPADM" ]; then
-       LAST_TTY=$(tty)
-       LAST_LOGIN=$(last -if /var/run/utmp | awk -vtty="${LAST_TTY#/dev/}" '$2 == tty && $0 ~ /still logged in/ { print $1; exit; }')
-       export FTPADM=$LAST_LOGIN
-       unset LAST_TTY LAST_LOGIN
-fi
+#if [ -z "$FTPADM" ]; then
+#      LAST_TTY=$(tty)
+#      LAST_LOGIN=$(last -if /var/run/utmp | awk -vtty="${LAST_TTY#/dev/}" '$2 == tty && $0 ~ /still logged in/ { print $1; exit; }')
+#      export FTPADM=$LAST_LOGIN
+#      unset LAST_TTY LAST_LOGIN
+#fi
 
 # per-admin defaults
-case "$FTPADM" in
-'')
-       export FTPADM=$USER
-       ;;
-esac
+#case "$FTPADM" in
+#'')
+#      export FTPADM=$USER
+#      ;;
+#esac
 
 # let each ftp admin have own history file
-if [ "$FTPADM" ]; then
-       export HISTFILE=$HOME/.history-$FTPADM
-       export CDHISTFILE=$HOME/.cd_history-$FTPADM
-fi
-export EDITOR=vim
+#if [ "$FTPADM" ]; then
+#      export HISTFILE=$HOME/.history-$FTPADM
+#      export CDHISTFILE=$HOME/.cd_history-$FTPADM
+#fi
+#export EDITOR=vim
 
 PATH=$PATH:~/tld-ftp-admin/bin