From 6fd647e335b332de3b4c2ea9fe6ba5f7c23a830f Mon Sep 17 00:00:00 2001 From: Marcin Krol Date: Wed, 10 Jan 2024 21:08:48 +0100 Subject: [PATCH] - comment out unused code --- shell/bash_profile | 32 ++++++++++++++++---------------- 1 file changed, 16 insertions(+), 16 deletions(-) diff --git a/shell/bash_profile b/shell/bash_profile index 45d0bac..eda5501 100644 --- a/shell/bash_profile +++ b/shell/bash_profile @@ -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 -- 2.46.0