10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hi,
can someone explain how this aliases work:
alias m 'if ( \!:$ =~ *gz) set status = 1 && most \!:$ || gzcat \!:1 | most '
I mean, I know what it does, but I don't know how
- what is \!:$ and \!:1
- how do it used the && and ||
- what it does with status variable?
thanks (3 Replies)
Discussion started by: tzvikao
3 Replies
2. Shell Programming and Scripting
Hey all,
I would like to ask your help and sorry in advance for my ignorance since I am a complete beginner in this.
I need to create a UNIX script that will:
- scan a small number of folders and subfolders (see a similar file tree in the attachment)
-
- for each final folder (each of... (8 Replies)
Discussion started by: McNulty
8 Replies
3. Shell Programming and Scripting
List directories at the home directory in increasing order.
First of all is this correct?
cd ~/
du -h|sort -n|more
First command is to go to the home directory and second does the rest.
Is there a way to do them in single command.
Thanks in advance. (1 Reply)
Discussion started by: kevincobain2000
1 Replies
4. Shell Programming and Scripting
Hello,
I am new to shell scripting. I have a question I would greatly appreciate any suggestions on. I am writing a ksh script that will launch bin files. The files are owned root and the application runs under root. The application administrators do not get root access. The script is intended... (1 Reply)
Discussion started by: inakajin
1 Replies
5. Shell Programming and Scripting
Hey all,
Writing a program that searches for a username and if they are online creates a 'beep' and sends the username and date to a log file.
the error i am getting is:
paul.obrien16@aisling:~/os$ bash checklogin
: command not found
Enter username
paul.obrien16
': not a valid... (2 Replies)
Discussion started by: sexyladywall
2 Replies
6. Shell Programming and Scripting
hi and sorry for crossposting...
I have data, the first column is the date ("2011 02 03 12 45") and follow I have the measurements . What I would like to do is:
to read the data line by line and write the data of "today" in a new file and "yesterday" as well in another file, separated by... (2 Replies)
Discussion started by: jurgen
2 Replies
7. Shell Programming and Scripting
I am having an issue with using cygwin (on Windows XP). My script errors on if -command. The script here works fine on Linux, but cygwin fails...
#!/bin/sh
if then
echo "Test"
fi
The error -message:
./ShellTest.sh: line 4: syntax error near unexpected token `fi'
./ShellTest.sh:... (1 Reply)
Discussion started by: jussist
1 Replies
8. Shell Programming and Scripting
i write a shell program and i execute that after i made a bin directiry in my home directory(i didnt give any permissions)
now i change to other directory.then i execute it bit it is saying " no such a file or directory"
can any one help me please (2 Replies)
Discussion started by: wkbn86
2 Replies
9. Shell Programming and Scripting
Hello!
I have somo problems with simple scripts like this:
#!/bin/bash
echo -n "Enter your name and press : "
read var_name
echo "Your name is: $var_name"
When I try to run it, this error occurs: ':not a valid identifier var_name.
Why?? (I work in cygiwin)
Is there anybody out... (10 Replies)
Discussion started by: blianna
10 Replies
10. UNIX for Dummies Questions & Answers
How can I redirect all stdout and stderr messages from a command to /dev/null (or to a file if need be) except messages that start with the word 'foo'? Messages that start with 'foo' need to be displayed in real time (i.e., when they are sent to stdout/stderr by the command). Thanks. (5 Replies)
Discussion started by: darwin_886
5 Replies