10 More Discussions You Might Find Interesting
1. UNIX for Dummies Questions & Answers
original post --
I have a korn shell script that does some things that depend on creating and writing a file in a directory. I'm looking for a more elegant/efficient way to do the check than what I'm using now:
if ]
then
print "Creating ${STGDIR}/${SHOW}"
mkdir... (3 Replies)
Discussion started by: Dalej
3 Replies
2. Shell Programming and Scripting
Hi,
I have used expdp for datapump. The .dmp file is created by the "oracle" user.
my requirement is to make a zipped file of this .dmp file.
What i am trying to do is change the permissions of this .dmp file from 0640 to 0644 and then do a gzip and zip it. Is there any way i can change... (3 Replies)
Discussion started by: qwertyu
3 Replies
3. Shell Programming and Scripting
I am trying to test the output of a file. What I have so far is this:
if ]; then echo "yes";fi
The problem with this is it works but I only want it to print out if the file contains the word "Compacted." The == sign means identical or equal to so it won't work. I tried ~ but that doesn't... (4 Replies)
Discussion started by: newbie2010
4 Replies
4. Shell Programming and Scripting
Hi, I am creating a ksh script to search for a string of text inside files within a directory tree. Some of these file are going to be read/execute only. I know to use chmod to change the permissions of the file, but I want to preserve the original permissions after writing to the file. How can I... (3 Replies)
Discussion started by: right_coaster
3 Replies
5. Shell Programming and Scripting
i have written this simple script called isdir.sh
#! /bin/bash
dir=$1
_ls=`ls $dir`
for file in $_ls
do
if
then
echo "D $file"
fi
donethe output is not right.
for example
$ ./isdir.sh src
***no output***
but i have in ~/src some directories
drwxr-xr-x 2... (5 Replies)
Discussion started by: and77
5 Replies
6. Shell Programming and Scripting
Hello.
I have written a bash script that I am sharing with an OS X community I am a member of. The purpose of the script is to execute a series of commands for members without them having to get involved with Terminal, as it can be daunting for those with no experience of it at all. I have renamed... (4 Replies)
Discussion started by: baza210
4 Replies
7. Shell Programming and Scripting
Hello,
I need to determine if a file I have is empty or not. How can I go about doing this in shell scripting? Some sample code would be appreciated?
Thanks, (6 Replies)
Discussion started by: mojoman
6 Replies
8. HP-UX
Hi,
I am a Unix Admin. I have to give the permissions to a user for creating new file in a directory in HP-Ux 11.11 system since he cannot able to create a new file in the directory.
Thanks in advance.
Mike (3 Replies)
Discussion started by: Mike1234
3 Replies
9. UNIX for Dummies Questions & Answers
hey guys
How can i test existence of a file /directory in a directory in a script
thanks (2 Replies)
Discussion started by: ajaya
2 Replies
10. UNIX for Dummies Questions & Answers
Has anyone got a few tips on how I can test if the file size is 0?
I am moving files on a regular basis from one location to another with ftp. The files which are 0 bytes in size we want to discard.
Thankyou in advance. (3 Replies)
Discussion started by: Ivo
3 Replies