Skip to content

Instantly share code, notes, and snippets.

@anil1kuppa
anil1kuppa / Renamefiles.sh
Created April 12, 2023 03:01
List the number of files in sftp
#!/bin/bash
username=
hostname=
currentdir=
filename=
(
echo cd $currentdir
for file in `(sed -n -e '1,2p' $filename)`
do
echo rename $file /nfiIndustries/Historical_candidate_`echo $file|cut -d'_' -f2-`