Sponsored Content
Full Discussion: Renaming files
Top Forums Shell Programming and Scripting Renaming files Post 302785273 by Aswex on Monday 25th of March 2013 07:36:48 AM
Old 03-25-2013
Thanks PiKK45, but this wont work as all files dont have the same name.

The only part that doesn't change is the date stamp in the file name.

And this is the part a need to change in the file name.

Any idea ?

it's about 100 files to change ... Smilie
 

10 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

renaming files

i have a set of *.lst files. now i want to change the names from "lst" to "dat". how to do it? ex.: -rw-r--r-- 1 rram group 22 Sep 21 13:10 a.lst -rw-r--r-- 1 rram group 22 Sep 21 13:09 b.lst -rw-r--r-- 1 rram group 22 Sep 21 13:10 c.lst... (4 Replies)
Discussion started by: raguramtgr
4 Replies

2. UNIX for Dummies Questions & Answers

renaming the files

Hi All, Today I got a small problem while handling zipped files in PROD support. There are files in this format and I had to grep them reading some contents A.B.gz.C.D where A,B,C and D stand for variables (like FIRST.NAME.gz.MIDDLE.LAST). I know that these files are zipped files and If I... (1 Reply)
Discussion started by: adurga
1 Replies

3. UNIX for Dummies Questions & Answers

renaming files

directory name = /usr/tom/1997 files - ABC_1997_ST1_BCD.SQL BCD_1997_ST1_EFG_SAB.SQL TTT_EBC_1997_ST1_A.SQL sub directory - /usr/tom/1997/jan a) I want to just rename the all files ending with '.SQL' and also its contents in the 1997 directory(excluding subdirectories eg... (3 Replies)
Discussion started by: systemsb
3 Replies

4. UNIX for Dummies Questions & Answers

Renaming files

Hello! I am not familiar with UNIX and I have this problem: I need to move files from a UNIX machine to a PC. UNIX file names contain ":" as special character which is not recognized in a PC. How can I change ":" for "_" in the name of a bunch of files in UNIX? Thanks for your help. (7 Replies)
Discussion started by: Tygoon
7 Replies

5. UNIX for Dummies Questions & Answers

renaming files

I have a list of files named ab_*.csv I would like to remane them all by removing the ab_ and have *.csv I did the following but I am surely missing something. /* wrong script */ for i in `ls -1 ab_*`; do mv ab_$i $i; done Thanks in advance. (1 Reply)
Discussion started by: jxh461
1 Replies

6. Shell Programming and Scripting

renaming files

Hi all, using a utility image file was named starting with blank space and a blank space in between. I want to rename the files. file names are in the format " sb 12.tif"," sb 13.tif"," sb 14.tif" the files are in thousands. i want to rename as 12.tif, 13.tif, 14.tif.... thanks. (3 Replies)
Discussion started by: ahkverma
3 Replies

7. Shell Programming and Scripting

renaming files or adding a name in the beginning of all files in a folder

Hi All I have a folder that contains hundreds of file with a names 3.msa 4.msa 21.msa 6.msa 345.msa 456.msa 98.msa ... ... ... I need rename each of this file by adding "core_" in the begiining of each file such as core_3.msa core_4.msa core_21.msa (4 Replies)
Discussion started by: Lucky Ali
4 Replies

8. Shell Programming and Scripting

renaming files

Hi, I have a list of files in a folder with the same name ending (over 1000 files) joe.jpy.jpeg joe1.jpy.jpeg joe2.jpy.jpeg jon3.jpy.jpeg jor5.jpy.jpeg .....jpy.jpeg etc. I want to change jpy to hhk So the output will be: joe.hhk.jpeg joe1.hhk.jpeg joe2.hhk.jpeg jon3.hhk.jpeg... (3 Replies)
Discussion started by: kylle345
3 Replies

9. Shell Programming and Scripting

Renaming files

Hi i have to achieve the following i have files as xyz001.csv, xyz002.csv.......xyz0025.csv in a folder, i need to keep xyz001.csv as it is but want to remove the extra zero on filename from 10 say xyz0010 should be renamed to xyz010 xyz0025 should be renamed as xyz025 Note xyz... (8 Replies)
Discussion started by: mad_man12
8 Replies

10. Shell Programming and Scripting

Renaming multiple files in sftp server in a get files script

Hi, In sftp script to get files, I have to rename all the files which I am picking. Rename command does not work here. Is there any way to do this? I am using #!/bin/ksh For eg: sftp user@host <<EOF cd /path get *.txt rename *.txt *.txt.done ... (7 Replies)
Discussion started by: jhilmil
7 Replies
CVSUTILS(1)						      General Commands Manual						       CVSUTILS(1)

NAME
cvsutils - CVS utilities for use in working directories SYNOPSIS
cvsu [options] cvsco [ options ] cvsdiscard [ options ] cvspurge [ options ] cvstrim [ options ] cvschroot [ options ] cvsdo [ options ] DESCRIPTION
The idea of cvsutils is to facilitate working with the files in the working directory of a developer using CVS (Concurrent Versions Sys- tem). From the point of view of CVS, working directories have low value, since they can easily be recreated using the cvs checkout command. Also the cvs update command will show the status of the files, i.e. whether they have been modified, added or removed. CVS in it's current state is a client-server system that does most of its work on the server side. CVS provides only few (if any) means for managing the working directory without communicating with the server. There are, however, several reasons why such means are necessary: * There is enough information on the client side to create fast tools for sorting and purging the working directory without contacting the CVS server. * Checking out a big module over a slow line can take too much time. * There should be support for disconnected operations. * CVS poses certain unnecessary restrictions on read-only users, e.g. cvs add command doesn't work for them. CVSU
cvsu is "cvs update offline". It lists the files found in the current directory (or in the directories which you specify). Following is taken into account: * Attributes of the file. * Information about the file in CVS/Entries. * Timestamp of the file compared to the timestamp stored in CVS/Entries. Run cvsu --help to see supported command line options. The options can be abbreviated. This functionality is provided by Perl, and can vary from one machine to another. CVSCO
cvsco is a "cruel checkout". In other words, it removes results of compilation and discards local changes. It deletes all the files except listed unmodified ones and checks out everything which seems to be missing. Please note, that cvsco doesn't update files which haven't been modified locally. It only reloads missing files and files which it erases. CVSDISCARD
cvsdiscard is "discard my changes". In other words, it discards local changes but keeps results of compilation. It works like cvsco, but it only deletes files which are likely to cause merge conflicts. CVSPURGE
cvspurge leaves all files known to CVS, but removes the rest. Unlike cvsco, it doesn't remove local changes. It is useful to test local changes in the otherwise clean source tree. CVSTRIM
cvstrim removes files and directories unknown to CVS. Files listed in .cvsignore are not removed. The idea is to remove the files that are not resulted from the normal build process - backups, coredumps etc. cvstrim relies on .cvsignore files being correct. Note that the back- ups for modified files are removed. CVSCHROOT
cvschroot makes it possible to change CVS/Root in all subdirectories to the given value. Currently the only argument accepted is the new CVSROOT value. Old-style CVS/Repository files that contain the full path to the repository are updated to reflect the change. New-style CVS/Repository don't need to be changed. If the environment variable CVSROOT is defined, it overrides the contents of CVS/Root. In other words, it is treated as the old CVS root. CVSDO
cvsdo simulates some of the CVS commands (currently add, remove and diff) without any access to the CVS server. Using cvsdo add and cvsdo remove allows you to create diffs with cvs diff -N, and all removed and added files will appear in the diff correctly, as if you had used cvs add and cvs remove respectively. cvsdo diff tries to locate the backup copies of the modified files. If they can be found, they are compared with the current version using diff. Only those backup copies are used that have the modification date equal the date listed in CVS/Entries for the modified file. cvsdo diff patches the diff output to make it more robust to apply. An exception is made for files named "ChangeLog" - in this case diff will be instructed to omit all context lines, so that the patch can be applied even if other changes have been written to the ChangeLog. Also the added files are handled properly. The header of the diff output is patched in such way that at least GNU patch will create a new file when the resulting patch is applied and remove that file when the patch is reverted. LICENCE
cvsutils is covered by the GNU General Public License (GPL). SEE ALSO
cvs(1), cvs2cl(1). AUTHOR
This manual page was written by Uwe Hermann <uwe@debian.org>, for the Debian GNU/Linux system (but may be used by others). February 27, 2002 CVSUTILS(1)
All times are GMT -4. The time now is 12:07 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy