03-22-2010
code like..you can use rename/mv
rename ABC.zip ABC`date '+%m%d%y'`.zip
10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hi,
I need to rename a file like this to include date and time:
Original File : error.log
Date time: Sep 20, 2007 14:10:10
New File Name: error.log.20070920_1410
How can I get date and time stame and include it in mv command.
Thanks in advance (2 Replies)
Discussion started by: tripsat
2 Replies
2. Shell Programming and Scripting
Hey Guys....
Just need some help as I am not proficient in Unix shell script...
Doubt:
---------------
Suppose there will be some of the following files inside a directory called OUT ...
Path: - /appdb1/product/batch/rms/OUT
files inside OUT directory:-
POSU_75002_20090127_20090129035442... (4 Replies)
Discussion started by: satyajit007
4 Replies
3. Shell Programming and Scripting
Hi, i need a bit of help writting a tcsh script which renames all ascii text files in the current directory by adding a number to their names before the extension
so for example, a directory containing the files
Hello.txt
Hello.t
Hello
should have the following changes,
Hello.txt... (2 Replies)
Discussion started by: yakuzaa
2 Replies
4. UNIX for Dummies Questions & Answers
I searched the forum, but there was different type of rename.
Hello.
I have files in folder.
Like:
xxxxxxxx1.html
or
xxxxxxxx2.txt
or
xxxxxxxx3.tar.gz
and how to rename or change file extension case to
xxxxxxxx1.htm
or
xxxxxxx2.TXT
or (5 Replies)
Discussion started by: Sheldon
5 Replies
5. Shell Programming and Scripting
Hi!
I need help to create a shell script to search inside a file and then copy a portion of the search result as the new file name.
Basically I was hacked over the weekend and the genius wipe out my drive from my server. I was able to recover alot of files, but biggest problem Is now the... (15 Replies)
Discussion started by: kidney514
15 Replies
6. Shell Programming and Scripting
Hello,
I am having 1800 files in a directory with a specified format, like
amms_850o_prod.000003uNy
amms_850o_prod.000003u8x
amms_850o_prod.000003taP
amms_850o_prod.000003tKy
amms_850o_prod.000003si4
amms_850o_prod.000003sTP
amms_850o_prod.000003sBg
amms_850o_prod.000003rvx... (12 Replies)
Discussion started by: atlantis
12 Replies
7. Shell Programming and Scripting
hi,
I need some help in writing shell script in a bourne shell.I am trying to rename the file..
eg.
find /root/data -type f -name "text*) | while read FILES
do
newfile=${FILES/type_2.0_20101208_34.xml / tmp.xml}
mv "$FILES" "$newfile"
done
above written script is working...If the... (7 Replies)
Discussion started by: shubhig15
7 Replies
8. Shell Programming and Scripting
How can i frame current date & time in the xml standard dateTime format in shell script
2011-10-18T12:00:00.000000
I got up to the date format using the below code
date '+%Y'-'%m'-'%d'T
---------- Post updated at 09:10 AM ---------- Previous update was at 08:53 AM ----------
... (6 Replies)
Discussion started by: vel4ever
6 Replies
9. Shell Programming and Scripting
I have 2 files sorted by numerically. I need help with shell script to read these 2 files and do a 1:1 mapping and rename the filenames with the mapped case#;
For example:
cat case.txt
10_80
10_90
cat files.txt
A BCD_x 1.pdf
A BCD_x 2.pdf
ls pdf_dir
A BCD_x 1.pdf A BCD_x 2.pdf
... (2 Replies)
Discussion started by: iaav
2 Replies
10. Shell Programming and Scripting
Hello everyone,
Posting here after a long time, been away from unix world lately and it seems I have forgotten my shell scripting completely. I have a requirement where a csv file contains following columns:
Full Registration VIN Stock... (14 Replies)
Discussion started by: tayyabq8
14 Replies
LEARN ABOUT DEBIAN
zip_errors
ZIP_ERRORS(3) Library Functions Manual ZIP_ERRORS(3)
NAME
zip_errors - list of all libzip error codes
LIBRARY
libzip (-lzip)
SYNOPSIS
#include <zip.h>
DESCRIPTION
The following error codes are used by libzip:
[ZIP_ER_OK] No error.
[ZIP_ER_MULTIDISK] Multi-disk zip archives not supported.
[ZIP_ER_RENAME] Renaming temporary file failed.
[ZIP_ER_CLOSE] Closing zip archive failed.
[ZIP_ER_SEEK] Seek error.
[ZIP_ER_READ] Read error.
[ZIP_ER_WRITE] Write error.
[ZIP_ER_CRC] CRC error.
[ZIP_ER_ZIPCLOSED] Containing zip archive was closed.
[ZIP_ER_NOENT] No such file.
[ZIP_ER_EXISTS] File already exists.
[ZIP_ER_OPEN] Can't open file.
[ZIP_ER_TMPOPEN] Failure to create temporary file.
[ZIP_ER_ZLIB] Zlib error.
[ZIP_ER_MEMORY] Malloc failure.
[ZIP_ER_CHANGED] Entry has been changed.
[ZIP_ER_COMPNOTSUPP] Compression method not supported.
[ZIP_ER_EOF] Premature EOF.
[ZIP_ER_INVAL] Invalid argument.
[ZIP_ER_NOZIP] Not a zip archive.
[ZIP_ER_INTERNAL] Internal error.
[ZIP_ER_INCONS] Zip archive inconsistent.
[ZIP_ER_REMOVE] Can't remove file.
[ZIP_ER_DELETED] Entry has been deleted.
[ZIP_ER_ENCRNOTSUPP] Encryption method not supported.
[ZIP_ER_RDONLY] Read-only archive.
[ZIP_ER_NOPASSWD] No password provided.
[ZIP_ER_WRONGPASSWD] Wrong password provided.
AUTHORS
Dieter Baron <dillo@giga.or.at> and Thomas Klausner <tk@giga.or.at>
NiH March 10, 2009 ZIP_ERRORS(3)