find is not shell, it does not expand * inside commandlines. It does inside -name and -path arguments however.
\ is taken literally inside single quotes anyway, so probably won't do what you want it to do.
I don't think find can do everything you want all by itself, but it can at least find the names for you, and print them one-by-one. Shell can do the rest.
Remove the 'echo' once you've tested and are sure it does what you want.
Last edited by Corona688; 01-11-2013 at 04:44 PM..
cat .servers | while read LINE; do
ssh jason@$LINE $1
done
exit 1
./command.ksh "ls -l ~jason"
Why does this ONLY iterate on the first server in the list? It's not doing the command on all the servers in the list, what am I missing?
Thanks!
JP (2 Replies)
Howdie everyone...
I have a shell script RemoveFiles.sh
Inside this file, it only has two commands as below:
rm -f ../../reportToday/temp/*
rm -f ../../report/*
My problem is that when i execute this script, nothing happened. Files remained unremoved. I don't see any error message as it... (2 Replies)
Hello, the ls -d command to only list directories in a directory doesn't seem to work on Solaris and the man command says to use that combination: ls -d
Anyone have the same problem and find a resolve?
Thanks
BobK (9 Replies)
Hi. I've been playing around a bit. This isn't for any practical purpose-- it's really just a theoretical exercise. I wrote this little thing:
foreach num ( 6 5 4 )
awk -v "number=$num" 'BEGIN{for(x=0;x<$number;x++) printf "-"; printf "\n"}'
end
I would expect the following output:
... (3 Replies)
Hi
I have put alias ll='ls -la' in .profile file but it doesn't work.
On hand it works it looks like the .profile file is not beeing read.
How to check whitch file is loaded? ,profile? .bash_profile?
My system: SunOS mion 5.10 Generic
Shell: /bin/pfksh
Thanks (2 Replies)
i want to get the value for column 4rth when i =4. please guide what i am doing wrong. thanks
var=`cat file.csv`
for i in $var; do {
if ; then
var4=$var4+$i
fi
echo $i
}
done
I am geting this error message "0403-009 The specified number is not valid for this command." (8 Replies)
I edited sudoers like this:vi /etc/sudoers
subex ALL =(root) NOPASSWD: /usr/ccs/bin/pstack
But the respective user still is prompted for password, and even when the right password is used, the command is still not launched.$sudo usr/ccs/bin/pstack 26557
We trust you have received the usual... (5 Replies)
Hi,
I am using korn shell.
until ]
do
echo "\$# = " $#
echo "$1"
shift
done
To the above script, I passed 2 parameters and the program control doesn't enter inside "until" loop. If I change it to until ] then it does work.
Why numeric comparison is not working with -ne and works... (3 Replies)
Discussion started by: ab_2010
3 Replies
LEARN ABOUT DEBIAN
vstp
VSTP(1) BrlNet User's Manual VSTP(1)NAME
vstpg, vstpp - VisioBraille file transferring
SYNOPSIS
vstpg [-ifbnd] [-s socketport] [-k keyname] [-o configname] file ...
DESCRIPTION
vstpg (resp. vstpp) gets (resp. puts) files from (resp. onto) a VisioBraille terminal.
For communicating with the terminal, you must launch brltty with the BrlNet driver, and telling BrlNet to use the VisioBraille driver.
Before putting on the terminal, file names are truncated to 8 characters without any extension.
Before getting from terminal, leading path and trailing extensions are removed, but put back for local filename.
COMMAND-LINE OPTIONS-i ask for confirmation of transfer, for each file (on the terminal)
-f don't ask for such a confirmation (default)
-b if they exists, recursively rename the old files with an added .x suffix, just like logrotate does
-n do not keep such backup file (default)
-s socketport
use socketport as the port number instead of default for connecting to BrlNet
-k filename
use filename as key path instead of default for reading BrlNet's authentication key
-d use current directory rather than the download directory (see vbs_dir below)
-o filename
also read filename as config file
CONFIG FILE
vstpg and vstpp read a configuration file $HOME/.vstprc which contains keywords or equalities, one per line (what follows a # is ignored).
You can ask them to also read any other file thanks to the -o option.
Here are keywords:
backup make -b option the default
nobackup
make -f option the default
and equalities:
keyname = filename
use this file instead of default, to find BrlNet's authentication key
socketport = port
use this port number, instead of default, to connect to BrlNet
vbs_ext = .ext
use .ext as an extension for downloaded files (.vis by default) this is overriden on command line if an extension is provided in the
file name
vbs_dir = path
use path instead of current directory for putting files, except when using the -d option, or if the filename begins with '.'
RETURNED VALUE
1 syntax error on command line
2 connection with BrlNet error
3 Unix file error
4 Protocol error
16 interrupted by user
SHELL EXPANSIONS
Beware of special chars: * and . are often expanded by your shell, hence vstpp * will probably do what you want, putting every file exist-
ing in the current directory onto the terminal, but vstpg * may not do what you want: it will only get every file which already exist in
the current directory, skipping those you just created on your terminal ! If you want to get every file which exist in the terminal, you
should use vstpg '*' or something similar (please read your shell manual).
The same warning applies to other special chars, such as $, ~, &,... which should be protected by surrounding arguments by quotes (') or by
using single backslashes () just before them (please read your shell manual).
BUGS
The one we could find has been corrected :)
AUTHOR
Samuel Thibault <samuel.thibault@ens-lyon.org> and Sebastien Hinderer <sebastien.hinderer@ens-lyon.fr>
BrlNet Jul 15, 2002 VSTP(1)