mirror of
https://github.com/buildplan/du_setup.git
synced 2025-12-29 16:14:59 +00:00
Fix shellcheck warning variable declaration
This commit is contained in:
@@ -2248,7 +2248,8 @@ EOF
|
|||||||
log "Successfully created temporary .bashrc source at $temp_source_bashrc"
|
log "Successfully created temporary .bashrc source at $temp_source_bashrc"
|
||||||
|
|
||||||
if [[ -f "$BASHRC_PATH" ]] && ! grep -q "generated by /usr/sbin/adduser" "$BASHRC_PATH" 2>/dev/null; then
|
if [[ -f "$BASHRC_PATH" ]] && ! grep -q "generated by /usr/sbin/adduser" "$BASHRC_PATH" 2>/dev/null; then
|
||||||
local BASHRC_BACKUP="$BASHRC_PATH.backup_$(date +%Y%m%d_%H%M%S)"
|
local BASHRC_BACKUP
|
||||||
|
BASHRC_BACKUP="$BASHRC_PATH.backup_$(date +%Y%m%d_%H%M%S)"
|
||||||
print_info "Backing up existing non-default .bashrc to $BASHRC_BACKUP"
|
print_info "Backing up existing non-default .bashrc to $BASHRC_BACKUP"
|
||||||
cp "$BASHRC_PATH" "$BASHRC_BACKUP"
|
cp "$BASHRC_PATH" "$BASHRC_BACKUP"
|
||||||
log "Backed up existing .bashrc to $BASHRC_BACKUP"
|
log "Backed up existing .bashrc to $BASHRC_BACKUP"
|
||||||
|
|||||||
Reference in New Issue
Block a user