Sponsored Content
Top Forums Shell Programming and Scripting Recursivly rename folders removing characters as required Post 302971199 by dunryc on Sunday 17th of April 2016 02:49:34 PM
Old 04-17-2016
yeah although i got a few splinters from the scratching

I can accomplish this fine with a line of text ie

Quote:
echo "The Evil Within - a Top Murder Squad Detective Reveals the Chilling True Stories of the World's (572)" | sed 's/(.*//'
give me the output i would like to rename to but how to apply this recursively to all directories is currently evading me
 

10 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

Removing old folders

All Please help me to remove old files. For example /usr/exp/ - inside this Apr 02 - dir02 Apr 03 - dir03 Apr 04 - dir04 Apr 05 - dir05 Apr 06 - dir06 Apr 07 - dir07 Apr 03 - file03 I want to delete all the folders 2 days before created.Not the fil03 even though it is 2 days old. ... (1 Reply)
Discussion started by: DeepakXavier
1 Replies

2. UNIX for Dummies Questions & Answers

Find and rename all folders with name X.

Is there a command I can use to rename all directories with a certain name to a new name. For instance from my root directory I want to change all folders named '123' to '321' that are in the root directory or any subdirectory. Thanks in advance! (6 Replies)
Discussion started by: mkingrey
6 Replies

3. Shell Programming and Scripting

Rename files recursivly in specified directories

Hi, This is what I would like to do. 1. Find all directories named "ByHost" in a specified directory 2. Rename all .plist files inside "ByHost" directories This is the way I have been able to do it so far. #!/bin/sh # # Rename ByHost files # # Thomas Berglund, 13.07.08 # Get the... (2 Replies)
Discussion started by: Thomas Berglund
2 Replies

4. UNIX for Dummies Questions & Answers

Rename files to indexnumber in multiple folders

I have multiple subfolders with multiple jpg I want the group of files in each subfolder renamed to their index number (3 digits) in the folder, so: folder/a.jpg = folder/001.jpg folder/b.jpg = folder/002.jpg folder/c.jpg = folder/003.jpg folder2/1.jpg = folder2/001.jpg folder2/2.jpg =... (2 Replies)
Discussion started by: cmanniche
2 Replies

5. UNIX for Dummies Questions & Answers

Removing empty folders

Hello, I have a folder that contains all my music. Recently, I started using a different media player, and I let it manage my music folder. It has sorted all my music neatly in folders by artist and album. However, all the old folders that the songs used to be in are still there, yet they are... (2 Replies)
Discussion started by: emveedee
2 Replies

6. UNIX for Dummies Questions & Answers

Removing Extra Folders From a TAR

I use an extremely simple TAR function for files at work and I have a question about cleaning them up. My command is TAR -cvf ExampleTarName.tar then the folder I wish to TAR. When my TAR finishes and I double click it to check it unarchived beautifully (I don't do this with every file, duh)... (5 Replies)
Discussion started by: Dogtown24
5 Replies

7. Shell Programming and Scripting

Removing folders with specific name/part

Hi, I need a way to remove all folders that contain "Quick" in their names in a directory called /var/tmp... However all attemps I have tried won't work. :wall: I so far tried find /var/tmp -type d -name "Quick" | sudo xargs rm -rf find . -name "Quicklook" -exec rm -rf {} \; find .... (2 Replies)
Discussion started by: pasc
2 Replies

8. Shell Programming and Scripting

Moving files to folders and rename

Hello! I am new to this. I have many files from b_ap00 to b_ap80, and I need to move them to folder 00 to 80 respectively, where b_ap00 is in folder 00, b_ap01 is in folder 01. On top of this, I need to rename the file once they are inside the folder to b_ot, and subsequently run it (ifort -o... (8 Replies)
Discussion started by: krustytherusty
8 Replies

9. Shell Programming and Scripting

Rename directory removing last characters

Hello - I was looking to write a simple script trying to rename sub-directories chopping off the last n characters. For example: In /home/myname/dir there are three sub-directories: directory1_1, directory2_2, and directory3_3. Is there a simple script to chop off the last... (4 Replies)
Discussion started by: twckfa16
4 Replies

10. Shell Programming and Scripting

Help required with a file rename shell script

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
EBOOK-META(1)							      calibre							     EBOOK-META(1)

NAME
ebook-meta - part of calibre SYNOPSIS
ebook-meta ebook_file [options] DESCRIPTION
Read/Write metadata from/to ebook files. Supported formats for reading metadata: azw, azw1, cbr, cbz, chm, epub, fb2, html, imp, lit, lrf, lrx, mobi, odt, oebzip, opf, pdb, pdf, pml, pmlz, prc, rar, rb, rtf, tpz, txt, zip Supported formats for writing metadata: azw, azw1, epub, lrf, mobi, pdb, pdf, prc, rtf, tpz Different file types support different kinds of metadata. If you try to set some metadata on a file type that does not support it, the metadata will be silently ignored. Whenever you pass arguments to ebook-meta that have spaces in them, enclose the arguments in quotation marks. OPTIONS
--version show program's version number and exit -h, --help show this help message and exit -t, --title Set the title. -a, --authors Set the authors. Multiple authors should be separated by the & character. Author names should be in the order Firstname Lastname. --title-sort The version of the title to be used for sorting. If unspecified, and the title is specified, it will be auto-generated from the title. --author-sort String to be used when sorting by author. If unspecified, and the author(s) are specified, it will be auto-generated from the author(s). --cover Set the cover to the specified file. -c, --comments Set the ebook description. -p, --publisher Set the ebook publisher. --category Set the book category. -s, --series Set the series this ebook belongs to. -i, --index Set the index of the book in this series. -r, --rating Set the rating. Should be a number between 1 and 5. --isbn Set the ISBN of the book. --tags Set the tags for the book. Should be a comma separated list. -k, --book-producer Set the book producer. -l, --language Set the language. -d, --date Set the published date. --get-cover Get the cover from the ebook and save it at as the specified file. --to-opf Specify the name of an OPF file. The metadata will be written to the OPF file. --from-opf Read metadata from the specified OPF file and use it to set metadata in the ebook. Metadata specified on the command line will over- ride metadata read from the OPF file --lrf-bookid Set the BookID in LRF files SEE ALSO
The User Manual is available at http://calibre-ebook.com/user_manual Created by Kovid Goyal <kovid@kovidgoyal.net> ebook-meta (calibre 0.6.53) July 2010 EBOOK-META(1)
All times are GMT -4. The time now is 05:30 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy