07-05-2013
* would normaly be used for other "unwanted" cases, so you are to define precisely what you expect as argument for your third case...
10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
my description from another thread...
here's my code:
#!/bin/bash
IFS=$'\n'
function OutputName() {
input=$1
echo $input
input=`echo "$input" | sed -e 's/.//'`
input=`echo "$input".avi`
output_name=$input
}
if ]; then
echo... (5 Replies)
Discussion started by: TinCanFury
5 Replies
2. Programming
suppose the user enters: ./Myfile blah1 blah2 blah3
I want to be able to read that in as: blah1blah2blah3
IN ONE VARIABLE
Obviously I can print it out in one line excluding the white space, but I'm having trouble combining argv, argv, ....., argv together!
This is what I tried, but I... (3 Replies)
Discussion started by: hansel13
3 Replies
3. Shell Programming and Scripting
Hi all,
I want to get options from command line by perl.
usage()
options:
-h Show this help message and exit
-t Name of tester
--timeout Set the timeout
-l ... (1 Reply)
Discussion started by: Damon_Qu
1 Replies
4. Shell Programming and Scripting
Hello All,
Is there a way to make exec do a couple of operations on a single input from find?
For example,
find . -type d -exec ls -l "{}" ";"
I would like to give the result of each "ls -l" in the above to a wc. Is that possible?
I want to ls -l | wc -l inside exec. How do I... (1 Reply)
Discussion started by: prasanna1157
1 Replies
5. UNIX for Dummies Questions & Answers
I'm reading about debugging aids in bash and have come across the set command. It says in my little book that an addition to typing
set
you can also use them "on the command line when running a script..." and it lists this in a small table:
set -o option Command Line... (5 Replies)
Discussion started by: Straitsfan
5 Replies
6. Shell Programming and Scripting
Hi all
I have spent half a day trying to create a shell script which reads a configuration file on a line by line basis.
The idea of the file is that each will contain server information, such as IP address and various port numbers. The line could also be blank (The file is user created). Here... (1 Reply)
Discussion started by: haggismn
1 Replies
7. Shell Programming and Scripting
Hi All,
I am having two files (file1 & file2) and a filelist.txt file below.
file1:
$$STRINGVAR1=5
$$STRINGVAR2=10
$$LAST_UPD_DT_TBL1=12/12/2010 12:00:00
$$STRINGVAR3=100
$$LAST_UPD_DT_TBL2=01/01/2010 12:00:00... (8 Replies)
Discussion started by: Chandru_Raj
8 Replies
8. UNIX for Dummies Questions & Answers
Hi all,
What am trying do is search for a directory that is owned by cm that only exists in a path that has a particular directory
ex: what I'm using now is
find . -user cm -name '*.rel' -type d -exec ls -dl {} \;
This is giving me stuff like this
./../../foo1/../../*.rel... (2 Replies)
Discussion started by: jtmed
2 Replies
9. Shell Programming and Scripting
how can I pass multiple values from command line arguments
example
script.sh -arg1 op1 -arg2 op1 op2 op3 (2 Replies)
Discussion started by: nsk
2 Replies
10. Shell Programming and Scripting
Hi,
I'd like find multiple file options to fetch different types of files.
find /path...// -type f -name "*.log" -o -name "*.req" -o -name "*.txt" -mtime +5 -exec ls -l {} \;
Where as in the above command only the last .txt files its retriving but not .log and .req files can body help... (1 Reply)
Discussion started by: Y.balakrishna
1 Replies
LEARN ABOUT DEBIAN
tally.unwanted