Hello,
I am making an increment counter in ksh. So i write a number in a temporary file and when I execute my script I read this file and I make +1.
But how can I make this with a number with 6 digits , example
000009 + 1 = 000010
...
....
....
000099 + 1 = 000100
Do anyone know... (5 Replies)
Hi guys,
Can someone help me out with this:
I have a directory with files like the following,
GHost++ 2010-03-14 04-01 DotaCash RD us_ca LC #7 (44m19s).w3g
GHost++ 2010-03-14 04-06 DotaCash AP us_ca LC #8 (42m24s).w3g
GHost++ 2010-03-14 04-07 DotaCash AR us_ca LC #10 (08m23s).w3g ... (4 Replies)
Hello Everyone,
I'm in need of assistance on creating a script with a counter on a certain string.
Basically this script opens a log file and displays certain log data. There are two key words in the log. START and FINISH. In between the START and FINISH is a variable ACTNUMBER. It will... (1 Reply)
Hi,
I would like to add a suffix to a file name but maintain the suffix length to 5 digits.
For eg,
output > 1st_file.00001, 2nd_file.00002...10th_file.00010....100th_file.00100
Can anyone please advise me on how to go about it?
Platform: SunOS mps201a 5.9 Generic_118558-39 sun4u... (7 Replies)
Hello There,
I have been trying to increment the value of variable to 1, 2, 3 etc. but, it displays
1
1+1
1+1+1
.....
:wall:
Could anyone help out with this?
for i in *.*
do
s=`expr $s+1`
echo $s
j=$i$j
mv $i $j
done
Any help is appreciated? (24 Replies)
Hi there everyone!
This is my first post so be gentle.
I have a small bash script that is extracting 3 line every 3 lines. I got the AWK part but i cant do the loop part.
#!/bin/bash
export line=`awk 'END { print NR }' btnew`
echo $line
for i in {1..$line..3} #increment
do
echo... (2 Replies)
Hi,
i have a scenario were i should compare a few fields from each line then increment a variable based on that.
Example file
989878|8999|Y|0|Y|N|V
989878|8999|Y|0|N|N|V
989878|8999|Y|2344|Y|N|V
i have 3 conditions to check and increment a variable on every line
condition 1 if ( $3... (4 Replies)
We have a simple menu with prompt of menu numbers to user.
It is still under construction.
Is there a way to "count" the menu choices so the prompt maximum count can be changed dynamically?
See attached TODO note in code
read_options(){
local choice
# the... (7 Replies)