Hi,
I need to prompt for a response from a user to enter a path
read dest_dir?"Please Enter Directory :"
How do I do this until a valid directory is entered by the user. I can use
to check the existence of the directory. However when I try the following I cannot get it to work.
while ... (2 Replies)
I'm trying to write a script that identifies whether a directory of the form AWL.????????.IP exists. I have one that exists which is AWL.05301032.IP.
When I test like this: If ]
I get true, but when I test like this:
If ]
Or like this
If ]
Or any other variation of wild cards, I... (4 Replies)
Hi.
I what to write a make file that inside a target I want to check if a directory exists.
some like:
### make
a:
if ;then
<command 1>
else
<command 2>
fi
### make end
Thanks a lot
---------------------- (2 Replies)
Hello:
Can someone please help me figure out what is wrong here, my script does not move on to the "else" part even though there is no .ssh directory on my remote server:
$more putkey.sh
#!/bin/ksh
for server in `cat list`
do
if ; then
cat $HOME/.ssh/id_rsa.pub |ssh $server ' cat >>... (4 Replies)
Hey guys im trying to check if the directory exists
i get a syntax error on the elif statement iv tried using else and still same result im not sure. If the directory does not exist can i just insert mkdir /tmp/old under the elif once that part gets working
if ; then
#do nothing
elif
echo... (20 Replies)
I want to perform SQL *Loader operation only if a file named "load.txt" exists in a directory "/home/loc/etc". Please help how to check this with a if condition. (8 Replies)
Hi,
I am using solaris 10 OS and bash shell.just checking for small code snippet which follows below.
/export/home/vomappservers/spa/common/5.0
/export/home/vomappservers/spa/common/scripts
/export/home/vomappservers/spa/tools
/export/home/vomappservers/spa/scm5.0/SCCS... (5 Replies)
Hi Gurus,
I have a requests to find if all the file in the filelist exist in certain directory.
example:
my filelist
abc
def
ddd
cde
afg
how can I find these 5 files exists at director /home/abc
Thanks in advance (7 Replies)
Hi guys,
I am beginner trying to learn unix. So any help is welcomed.
My requirement is to check whether is a file exists in a particular directory or not.
The directory path and filename are taken dynamically with user interaction. So the program should continue only if the $filename... (1 Reply)
There are some files with suffix dates like abc_20032019.dat abc_17032019.dat
If at least one file exists then perform some operation else exit from execution.
Korn shell
----------------------------------
array=($inputdir/abc*.dat)
If ] ]
then
echo " file exits"
else
echo " file does... (10 Replies)
Discussion started by: Rajesh123
10 Replies
LEARN ABOUT LINUX
shtool-arx
SHTOOL-ARX.TMP(1) GNU Portable Shell Tool SHTOOL-ARX.TMP(1)NAME
shtool-arx - GNU shtool ar(1) extensional command
SYNOPSIS
shtool arx [-t|--trace] [-C|--command cmd] op archive file [file ...]
DESCRIPTION
shtool arx is a wrapper around the archiving tool ar(1). It provides the ability to create archives out of existing archives, i.e., if one
of file matches ""*.a"", the archive member files of file are used instead of file itself.
The trick of this command is the automatic handling of archive members which is especially interesting if one wants to construct a (usually
top-level) library archive out of pre-built sub-library archives (usually staying inside subdirs) in a large source tree. For GNU libtool
based projects, a similar functionality is provided by GNU libtool internally, too.
OPTIONS
The following command line options are available.
-t, --trace
Shows the actually involved shell commands.
-C, --command cmd
Set the used ar(1) command to cmd instead of just "ar" (searched in $PATH).
EXAMPLE
# Makefile
AR=ar
RANLIB=ranlib
:
OBJS=foo.o bar.o
LIBS=baz/libbaz.a quux/libquux.a
:
libfoo.a: $(OBJS) $(LIBS)
shtool arx -C $(AR) rc libfoo.a $(OBJS) $(LIBS)
$(RANLIB) libfoo.a
HISTORY
The GNU shtool arx command was originally written by Ralf S. Engelschall <rse@engelschall.com> in 1999 for GNU shtool. It was prompted by
need to build libraries out of sub-libraries inside the OSSP project.
SEE ALSO shtool(1), ar(1).
18-Jul-2008 shtool 2.0.8 SHTOOL-ARX.TMP(1)