Results 1 to 4 of 4

Thread: [command-line]renaming and gzipping by mask

  1. #1
    Join Date
    Jul 2008
    Location
    ukraine/mk/pervomaysk
    Posts
    528

    Default [command-line]renaming and gzipping by mask

    i have made some strange thing
    when I try make iso image genisoimage cut some charecters...
    so i want to gzip them...

    i try to gzip folder with

    gzip -r myarcive.gz MyArchiveDIR/

    but I have gziped every single file in the directory... even I did not shure if they gziped... i think they just renamed oldname.file>oldname.file.gz

    so i have three questions with this...
    1.how can i know that file is gzip or not?
    2.how can I rename all files back(in case they is renamed)?
    3.how can I unzip them back with deletting *.gz ones(in case they is gziped)?

    also please can you comment what i am doing wrong with gzip, i want to gzip folder with all file structure as is from current directory in one single file...
    --
    thank you
    intelGMA3100#amd|radeonHD4200+radeonHD5450@catalyst12.4
    WC5020B,PagePro1480MF,LBP2900,hpCP1510,PHOTO1290,Scanmaker3600,PerfectionV200

  2. #2
    Join Date
    Mar 2008
    Location
    Bochum, Germany
    Posts
    3,587

    Default Re: [command-line]renaming and gzipping by mask

    * didencool,

    It's the "-r" option. It makes gzip descend into the subdirs, grab each file and gzip it.
    Try "gunzip -r /path/to/dir"

    HTH
    Uwe

  3. #3
    Join Date
    Jul 2008
    Location
    ukraine/mk/pervomaysk
    Posts
    528

    Default Re: [command-line]renaming and gzipping by mask

    thank you buckesfeld

    I run this and waiting...

    yeeeha that's it

    --
    thank you.... I'll try to be more accurate in future
    intelGMA3100#amd|radeonHD4200+radeonHD5450@catalyst12.4
    WC5020B,PagePro1480MF,LBP2900,hpCP1510,PHOTO1290,Scanmaker3600,PerfectionV200

  4. #4
    Join Date
    Mar 2008
    Location
    Bochum, Germany
    Posts
    3,587

    Default Re: [command-line]renaming and gzipping by mask

    On 11/06/2008 didencool wrote:
    > thank you.... I'll try to be more accurate in future


    I did exactly the same thing once, i.e. I wanted to zip a directory and ended up with a ton of zipped files. That -r option is kinda misleading IMHO, I don't know why.
    Uwe

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •