10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
HI Guys,
I have some 8 files with different name and extensions. I need to check if they are present in a specific folder or not and also want that script to show me which all are not present. I can write if condition for each file but from a developer perspective , i feel that is not a good... (3 Replies)
Discussion started by: shankarpanda003
3 Replies
2. Shell Programming and Scripting
Is it possible to use case when checking if a folder exist?
I need to check if these folder exist . All of them could be present but I still need to check. If a folder is present, something will be processed. Different folder do different stuff.
is this possible?'
Thanks (4 Replies)
Discussion started by: erin00
4 Replies
3. Shell Programming and Scripting
I am trying to delete old file in ftp server, after transferring new file successfully .
but here i am checking both the file available or not using ls command.
if both the file available means i need to get file_new and file_old file size as greater than zero.
but i am getting only for... (3 Replies)
Discussion started by: elango963
3 Replies
4. Shell Programming and Scripting
Hi guys,
I am new to shell script, i want to write shell script, the script details has mentioned below
Two files are to be check in one particular directory, if the file exist in particular folder then the file is existed and also if the file exist more than three hours then send... (2 Replies)
Discussion started by: madhavi_bodi
2 Replies
5. UNIX for Dummies Questions & Answers
I need to create multiple directories if those directories do not exist already. How would you go by doing this.
What I have so far.
array=(one two three)
for I in ${array}
do
if ]
then
mkdir ${I}
fi
doneI have a good feeling this is done incorrectly. The error I am... (2 Replies)
Discussion started by: jrymer
2 Replies
6. Shell Programming and Scripting
Hello
Im trying to build a script that (among other stuff) checks each line in a file for the $4 "variabel" and if there are a folder in the directory that has that not has the same name as that it create a folder, otherwise it wont do anything. I guess i could just send the errors to /dev/null,... (2 Replies)
Discussion started by: fisk4
2 Replies
7. Web Development
Hi,
I am sharing this tip with you all.The codes given below will explain
/**
* Checking a folder is empty or not.
* @param string $folderName
* $folderName should be folder name or path
* @return TRUE/FALSE (If any file or folder found/Empty folder)
*/
function... (1 Reply)
Discussion started by: elizas
1 Replies
8. Shell Programming and Scripting
Hi ,
I need a script which basically deltes all files in folder a which are alreasy present in folder b
say folder a has files abc.txt
pqr .txt
and b has abc.txt
pqr.txt
rmr.txt
then file abc.txt and pqr.txt from a should be deleted (6 Replies)
Discussion started by: viv1
6 Replies
9. Shell Programming and Scripting
Hi all,
I have following code:
export USERID=user
export BATCHHOSTIP=190.113.3.324
remotePath=/home/user
fileName=redbook.txt
EXIST=`ssh $USERID@$BATCHHOSTIP 'if ; then echo 0; else echo 1 ; fi'`
echo $EXIST
II run the code from other server. The redbook.txt file is exist in... (1 Reply)
Discussion started by: suigion
1 Replies
10. Shell Programming and Scripting
Alogorithm:
=============
Whenever any user open any specific directory:
1) cd /usr/lib
The prompt should show an Alert message like
2) echo "You have opened this folder"
How should I write shell script this one?..
It should be irrespective of users and... (11 Replies)
Discussion started by: Niroj
11 Replies