Sponsored Content
Full Discussion: Renaming files
Top Forums UNIX for Advanced & Expert Users Renaming files Post 302465064 by Scrutinizer on Thursday 21st of October 2010 03:06:41 PM
Old 10-21-2010
# Assuming there are no other kind of pdf files in that directory.
Code:
for i in *.pdf; do
  t=${i% * * * * * * * *.pdf}
  mv "$i" "${t% *}_${t#* }.pdf"
done

 

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

Hello, I am looking for a command line that will rename name files : f700_abc_o_t_MASTERID_AS_AE_20130323.csv like this f700_abc_o_t_MASTERID_AS_AE_20130324.csv The great idea could be to get the date stamp 20130323 and change any part of it, instead of just change the... (4 Replies)
Discussion started by: Aswex
4 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
QPDFVIEW(1)						      General Commands Manual						       QPDFVIEW(1)

NAME
qpdfview - tabbed PDF viewer SYNOPSIS
qpdfview [options] [file(s)[#page[#top]]] DESCRIPTION
qpdfview is a simple document viewer for PDF documents. It uses the poppler library for rendering. OPTIONS
--unique If an instance of qpdfview is started with this option, any files that are opened using this option afterwards, are opened as tabs in this same window. If a file is already opened in a tab of the respective window, it is merely reloaded using this option. [file(s)[#page[#top]]] Specifies the files to open when qpdfview starts. If this is not specified, qpdfview will open a blank window. Multiple files can be loaded in separate tabs if the file names are separated by spaces. The optional parameter #page opens the file at the given page. The optional parameter #top can take values between 0 and 1 and opens the page with the given position aligned to the top of the tab. (See examples.) CONFIGURATION FILE
qpdfview uses a configuration file usually located at "~/.config/qpdfview/qpdfview.conf", which allows configuration of the toolbars and thumbnails. The keys "fileToolBar", "editToolBar" and "viewToolBar" are added to the section "mainWindow". Their values are comma-separated lists. The default (available) entries are: fileToolBar: openInNewTab, refresh (open, saveCopy, print) editToolBar: currentPage, numberOfPages, previousPage, nextPage (firstPage, lastPage, jumpToPage, search) viewToolBar: scaleFactor, zoomIn, zoomOut (onePage, twoPages, oneColumn, twoColumns, fitToPage, fitToPageWidth, doNotScale, rotateLeft, rotateRight, fullscreen, presentation) The order of the items in the list defines the order of the items in the toolbar. (See examples.) Setting the keys "thumbnailWidth" and "thumbnailHeight" in the section "documentView" specifies the size of the thumbnails. The icon theme used by Qt can be overridden by setting the key "iconTheme" in the section "mainWindow". EXAMPLES
The command qpdfview foo.pdf#3#0.5 bar.pdf opens foo.pdf in the first tab with the middle of page 3 aligned to the top of the tab and bar.pdf in the second tab at the begin- ning of the document. Subsequent execution of the following commands qpdfview --unique foo.pdf bar.pdf qpdfview --unique foo.pdf#5 opens foo.pdf and bar.pdf, then reloads foo.pdf and displays its page 5. Subsequent execution of the following commands qpdfview --unique foo.pdf qpdfview bar.pdf qpdfview --unique foo1.pdf bar1.pdf opens foo.pdf in the first window, bar.pdf in a second window and then foo1.pdf and bar1.pdf in additional tabs in the first window. Adding the lines fileToolBar=openInNewTab, refresh, saveCopy, print editToolBar=firstPage, previousPage, currentPage, numberOfPages, nextPage, lastPage, search viewToolBar=zoomOut, scaleFactor, zoomIn, oneColumn, twoColumns, rotateLeft, rotateRight in section "mainWindow" of the configuration file leads to the corresponding items being displayed in the given order in the tool- bars. BUGS
If you find a bug, please report it at https://launchpad.net/qpdfview. AUTHOR
Benjamin Eltzner <b.eltzner@gmx.de> March 2012 QPDFVIEW(1)
All times are GMT -4. The time now is 06:07 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy