|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
|
|
Stay one step ahead of the competition. Evaluate and give feedback
on some of the hottest web development tools on the market today.
Make your opinion heard! Click
Here
|
|
#1
|
|||
|
|||
|
Appending to the end of the string
I have a directory containing files. To the end of each file name, i want to append '.55A'.
There are several files and hence, i would like to write an unix script. I tried with SED , but I am not successful in attaching to the end of the string. Any suggestions? Thanks. |
|
#2
|
||||
|
||||
|
shell?
what shell are you working in?
christo
__________________
. Spiration channels: Free scripts, programming tutorials and articles Dotcut alerts: Online Press cuttings / news alerts Clearprop: UK microlight school, wiltshire Uk dating: UK safe dating with Topdates About Christo . . |
|
#3
|
|||
|
|||
|
c shell
|
|
#4
|
||||
|
||||
|
I know that you are working in C Shell, but here is a quick ksh script to do it. I created a directory called temp and then executed the script outside the temp directory.
#!/usr/bin/ksh for filename in `ls -1 temp` do mv temp/$filename temp/${filename}.55a done Hope this helps. Regards, jlk |
![]() |
| Viewing: Dev Shed Forums > Operating Systems > UNIX Help > Appending to the end of the string |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|
|