Unzipping files with the same names but in very many different folders..Aim to unzip them and rename
I dont mind renaming them to the creation date. They are text files.
I tried option above Lohith..
Code:
for I in `cat FILE_LIST`
do
cp ${I} ${I//\//__}
gunzip ${I//\//__}
done
but
Code:
cp ${I} ${I//\//__}
creates the files with the same name while i want them with new random names.
I was trying this but the mv cmd error: cannot access file
Code:
#!/usr/bin/ksh
Home=/var/tmp
cd $Home
for zip in `find $Home -depth -name "*.zip"`
do
file="$(unzip -l -qq "${zip}" | sed 's/.*:[0-9]\+[[:space:]]*//')"
newname=$(echo "${file}" | sed 's/ /_/g')
mv {$newname} $Home
done
I'm getting the following errors when I try to write a script to unzip some zip files. When I use the free trial copy of the commerical winzip program, however, they work fine. When I use -l or -t on unzip it indicates no errors. When I use the -o switch interactively from the bash command line it... (1 Reply)
Hello experts,
I run Solaris 9. I have a below script which is used for gunzip the thousand files from a directory.
----
#!/usr/bin/sh
cd /home/thousands/gzipfiles/
for i in `ls -1`
do
gunzip -c $i > /path/to/file/$i
done
----
In my SAME directory there thousand of GZIP file and also... (4 Replies)
As part of an audit at work I need to review a lot of Windows workstations. One thing I need to do is review all of the .doc files. My problem is that I guessed a number of these files would be in zip archives. This is the case but they are mixed in with a lot of other file types that I am not... (1 Reply)
Variations of multiple renames seems to come up a lot but i can't find the answer to this situation.
Tidying up a directory where people rename files to .working, .bob, .attempt1 & so on.
what i am trying to do is: list the file type, & rename from ".whatever" to .fixed.
As the ".whatever" is... (5 Replies)
Requirement Details:
We have a folder named 'Inbound Files' that has many folders in it containing source files that have to be processed by Informatica system. We have zipped files, text files and csv files in those folders that have to be moved (cut and paste) from 'Inbound_Files' folder to... (3 Replies)
I have a folder (C:\shellprg\input\) containing .CSV, .zip, .gz files.
1] I want to find all .zip/.gz files from folder (C:\shellprg\input\).
2] unzip/uncompress files into the same folder (C:\shellprg\input\) through shell script.
I am using below commands for unzip files,
unzip <filename>... (2 Replies)
Hello All,
I need help in writing a batch script.
I have 100 zip files in a folder. Each zip file has a unique name starting with XYZ_12345.zip Each zip file contains single csv file
I would like to batch extract the files and also rename the extracted csv as per the original zip name... (6 Replies)
Hi Expert,
We have some shell scripts which Internally uses Perl Script to Unzip the source zip files which comes to inbound directory. So now our requirement is to avoid the dependency on Perl Script and us Shell Script to unzip the files. I have the Perl script with me attached can some one... (3 Replies)
Hi frnds,
My requirement is I have a zip file with name say eg: test_ABC_UH_ccde2a_awdeaea_20150422.zip
within that there are subdirectories on each directory we again have .zip files and in that we have files like mama20150422.gz and so on.
Iam in need of a bash script so that it unzips... (0 Replies)
Hey guys,
I have wrote the following script to apply a module named "trinity" on my files. (it takes two input files and spit a trinity.fasta as output)
#!/bin/bash -l
#SBATCH -p node
#SBATCH -A <projectID>
#SBATCH -n 16
#SBATCH -t 7-00:00:00
#SBATCH --mem=128GB
#SBATCH --mail-type=ALL... (1 Reply)
Discussion started by: @man
1 Replies
LEARN ABOUT DEBIAN
fontypython
FONTYPYTHON(1)FONTYPYTHON(1)NAME
fontypython - Find, view and manage font files of all kinds.
SYNOPSIS
fontypython [OPTIONS]... [VIEW]... [TARGET]...
DESCRIPTION
fontypython is a GUI utility written in Python and WxPython that will help you do font stuff on GNU/Linux system. You can quickly view and
filter arbitrary* TTF, TTC, OTF or Type1 font files and then gather them together into 'Pogs' which can be installed or removed as needed.
In this way you control which fonts are installed on a per-project basis.
If you have gucharmap or kfontview installed, (there is an option in Settings to choose which one) you can view any font's character maps
etc.
*Arbitrary means you can see and/or use any fonts in a local directory (or a mount). They do not need to be installed on your system.
OPTIONS
VIEW A place where fonts are. A Pog or a folder someplace.
TARGET
A "Pog". A place to keep those fonts (just references to them).
OPTIONS
Below are the various command-line options. You don't need to use them, but they are handy. The program will run as a GUI if you
only invoke 'fontypython'.
-e, --examples
Show some %$@#$ examples!
-l, --list
List the names of all the Pogs.
-i Pog, --install=Pog
Install the fonts in this Pog to your fonts folder.
-u Pog, --uninstall=Pog
Uninstall the fonts in this Pog.
-p Pog, --purge=Pog
Purge the Pog of font files that are no longer really there.
-s num, --size=num
Set a new default point size.
-n num, --number=num
Set a new default for how many fonts to view at one go. Don't overdo this.
-c folder --check=folder
Check for bad fonts that crash the program. It will recurse through sub-folders. This will build a file: ~/.fontypython/segfonts
After using this tool you should be able to browse safely. (The reason it's not done by default is that it's very slow.) NOTE: The
fonts that crash the program are probably still perfectly good and can be used in other apps.
-a folder Pog, --all=folder Pog
Puts all fonts in this folder into the Pog. If the Pog already exists, it will add only *new* fonts, this means fonts are not
repeated in that Pog.
-A folder Pog, --all-recurse=folder Pog
Puts all fonts in this folder and *all* sub-folders into the Pog. Rest same as -a.
-z Pog, --zip=Pog
All the fonts inside Pog will be zipped and the zipfile will be named after the Pog. The file will be placed in the current direc-
tory.
--version
Show program's version number and exit.
-h, --help
Show help message and exit.
SEE ALSO
Homepage: <https://savannah.nongnu.org/projects/fontypython>
AUTHOR
fontypython was written by Donn.C.Ingle <donn.ingle@gmail.com>.
This manual page was updated by Donn Ingle in October 2009. It was originally written by Kartik Mistry <kartik@debian.org>, for the Debian
project (but may be used by others).
2009-09-28 FONTYPYTHON(1)