Sponsored Content
Top Forums Shell Programming and Scripting sed to rename files in bash loop Post 302994617 by cmccabe on Saturday 25th of March 2017 09:02:15 AM
Old 03-25-2017
Thank you very much for your help and explanations Smilie.
 

9 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Hello - new here - bash script - need to rename and zip files.

I'm working on a project that basically unzips three zip files. When these unzip they create about 70+ directories with subdirectories of year/month with about 3 to 9 pdf files in each directory. Basically, I'm needing to figure out a way to zip these pdf files up. for instance the script... (1 Reply)
Discussion started by: Aixia
1 Replies

2. UNIX Desktop Questions & Answers

Rename files without using for loop

Hi, Is it possible to rename files at a time in a directory without using the for loop. (ex: intial filename- abc.txt to abc.tmp or abc.txt.tmp) I need to rename the files in a remote directory to which I'm connecting thru tectia sftp. The commands 'mv', 'for', 'echo' do not work. I have... (3 Replies)
Discussion started by: Qwerty123
3 Replies

3. UNIX for Dummies Questions & Answers

Rename files with sed in an until loop (double post)

I want to change the name of some of my files (mypics-0001, mypics-0002, mypics-0003.....mypics-0240) and I want to double check to see if this code is right: x=0 until do sed 's/mypics\-*/bday/g' done Would this change all of my file names to "bday0001....bday0240"? Please let me... (0 Replies)
Discussion started by: jvpike
0 Replies

4. Linux

rename files using loop with different name

Hi, i need to write a shell script where i have to loop through all the file in a directory and rename them based on below condition. file1.dat file2.dat file3.dat the above files has to be moved to another directory like below file1_201001.dat file2_201002.dat file3_201003.dat... (3 Replies)
Discussion started by: feroz
3 Replies

5. UNIX for Dummies Questions & Answers

For Loop To Rename Multiple Files Finds One Non-existant File

Okay so here's something that's confusing me: I have a script that's designed to remove the words "new_" from the front of any file except two exceptions and it looks something like this... for i in new_* do if ] && ]; then j=`echo "$i"|cut -c5-` mv $i $j fi done ... (5 Replies)
Discussion started by: Korn0474
5 Replies

6. UNIX for Dummies Questions & Answers

Split and Rename files using Terminal and bin/bash

I have a file named Me_thread_spell.txt that I want to split into smaller files. I want it to be split in each place there is a ;;;. For example, blah blah blah ;;; blah bhlah hlabl awasnceuir asenduhfoijhacseiodnbfxasd;;; oabwcuhaweoir;;; This full file would be three separate files... (7 Replies)
Discussion started by: mschpers
7 Replies

7. UNIX for Dummies Questions & Answers

Bash script to rename all files within a folder...

Hi. I don't have any experience with making scripts in bash. I need a simple script to rename all files in a folder to the format file1.avi, file2.avi, file3.avi, and so on..... Please note that the original files have different filenames and different extensions. But they all need to be... (2 Replies)
Discussion started by: dranzer
2 Replies

8. UNIX for Dummies Questions & Answers

Bash script to rename files in a directory

Dear friends, I have created a script to rename all files in a directory by appending the file name with username (who created the file), the date it was created. For example, "apple.doc" should be renamed to "johnFeb23apple.doc" where "john" is the owner and "Feb23" is file created date. It... (4 Replies)
Discussion started by: djsnifer
4 Replies

9. Shell Programming and Scripting

Loop through the dir and Rename zip files and their underlying text file.

I have files in the ABC_YYYYMMDD.zip format under a directory. Each zip file contains A text file in the ABC_YYYYMMDD.txt format. I am trying to create a script that will Rename the zip files and their underlying text file replacing the datepart in them with . For eg: in the case of... (1 Reply)
Discussion started by: bash987
1 Replies
EDOS-BUILDDEBCHECK(1)					      General Commands Manual					     EDOS-BUILDDEBCHECK(1)

NAME
Edos-builddebcheck - Check satisfiability of Debian package build-dependencies SYNOPSIS
edos-builddebcheck [option] ... Packagefile Sourcepackagefile DESCRIPTION
edos-builddebcheck reads a set of Debian package descriptions from the file Packagefile, each of which is in the format of deb-control(5), and a set of source package descriptions from the file Sourcepackagefile. All packages described in the file Packagefile must have the same value of their Architecture (if it is different from all). For instance, the Packages and Sources files as found on a Debian mirror server, or in the directory /var/lib/apt/lists/ of a Debian sys- tem, are suitable as input files. edos-builddebcheck verifies for every of the source packages (from Sourcepackagefile) whether its build-dependencies, build-indep-dependen- cies and build-conflicts can be satisfied from the binary packages provided in Packagefile. Only build-relations that apply to the archi- tecture (see below on how the architecture is determined) are taken into account. Note that this is not the same thing as checking whether a distribution can be rebuild from scratch, for several reasons: 1. No actual compilation is taking place, this tool only does a static analysis of package relationships. 2. The binary packages in Packages are not necessarily those that are the result of the compilation of the source packages in Sourcepack- agefile. 3. We do not check for cycles. For instance, suppose that we have source packages a and b both generating one binary package of respec- tively the same name, and that a build-depends on b and b build-depends on a. Then we can not rebuild the set of packages from scratch because of the cycle. However, if we already have binary packages a and b then we can recompile both of them. Consequently, edos-buildde- bcheck will not report an error in this case. 4. The underlying logical machine does a complete analysis of alternatives, and might report satisfiability of constraints in case actual tools (like apt) fail to find a solution. Build-essential packages are ignored in unversioned build-dependencies. The (architecture dependant) list of build-essential packages is read from the configuration file. If that file is not available than an architecture independent default value is used. OPTIONS
-a, --architecture architecture Check for compilation on architecture. Usually it is not necessary to specify the architecture since it can be derived from the Packages file. -be, --binexplain Add all explanations why build-dependencies are not satisfiable. Without that option some of these explanations may be missing from the output in case a source package build-depends on a binary package that exists in Packagefile file but that edos-debchecks finds not to be installable inside Packagefile. FILES
/etc/edos-builddebcheck.conf Configuration file for edos-builddebcheck AUTHOR
Edos-builddebcheck has been written by Stefano Zacchiroli <zack@debian.org> and Ralf Treinen <treinen@debian.org>. It heavily relies on edos-debcheck which has been written by Jerome Vouillon for the EDOS project. SEE ALSO
deb-control(5),edos-debcheck(1) EDOS
2010-04-22 EDOS-BUILDDEBCHECK(1)
All times are GMT -4. The time now is 10:03 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy