10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hello
Does the unix korn shell provide a function to convert number entered in command line argument to text or Character so that in next step i will convert Chr to Hex (6 Replies)
Discussion started by: aadityapatel198
6 Replies
2. Shell Programming and Scripting
I am trying to create a script that will accept multi input from the user (really just me), then execute those command on a remote device.
My question is if the I enter "No" at the confirmation point "Are these statements correct y or n ?", what is the best way to go back and start over ? I... (3 Replies)
Discussion started by: popeye
3 Replies
3. Shell Programming and Scripting
Hi folks,
I'm trying to work on a script that will grab a router interface report and generate the numbers of "in use" and "un-used" ports per device. Right now, I've got a cut down of the report as follows:
sing /usr/apps/siteName/etc/DCAFT-9K.cmds for send text
Connecting using... (11 Replies)
Discussion started by: Marc G
11 Replies
4. Shell Programming and Scripting
Say I have a ksh program called test.ksh which has several defined arrays inside it such as array1,array2,array3...These arrays contain strings.
I also have a method in the program:
for x in $1
do
....(#do something)
done
So, when the user enteres: ./test.ksh array1, I want to... (3 Replies)
Discussion started by: mrskittles99
3 Replies
5. Shell Programming and Scripting
My code to "Delete empty files from a directory entered in command promt"
#/bin/sh
echo "Enter directory"
read gh
for file in `ls $gh`
do
# to get the size of file
a=$( ls -l file | awk ' {print $7} ');
echo $a
if
then
echo "removing file "
rm file
fi
done (6 Replies)
Discussion started by: adirajup
6 Replies
6. Shell Programming and Scripting
I have a text file like this
...
B 16 1.340E+05
A 18 3.083E+02
Wu123 1.365E+02
...
I would like to get rid of the 7th character of each line if this is a space character.
Thank you,
Sarah (5 Replies)
Discussion started by: f_o_555
5 Replies
7. Shell Programming and Scripting
Hi,
how to do that ? I mean only print it but not execute. I'm using putty to interact with ksh.
(in windows cmd up arrow does the job)
thanks
vilius (5 Replies)
Discussion started by: vilius
5 Replies
8. UNIX for Dummies Questions & Answers
I have a script like this--
#!/bin/ksh
echo "To pad a 0 before digits from 1-9"
for i in $*
do
echo $i | sed 's//'0'/g'
done
I run this script as
ksh name 1 2 23 34
The output should be
01 02 23 34
Help me in modifying this script.
Thanks
Namish (2 Replies)
Discussion started by: namishtiwari
2 Replies
9. Shell Programming and Scripting
I have to process a data file in Ab Initio. This data file is pipe delimited. BUt the file may have a Disclaimer line at the end. So before picking it for processing, I need to check if this line is there I need to remove it. ANy suggestions.
Thanks
Shalu (1 Reply)
Discussion started by: shalua
1 Replies
10. Shell Programming and Scripting
Hi, I have a flat text file which contains blank line between each text line. Is there any command to get rid of it?
Thanks for your help (11 Replies)
Discussion started by: xfang
11 Replies