gcmd-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [gcmd-dev] advanced renaming


From: Piotr Eljasiak
Subject: Re: [gcmd-dev] advanced renaming
Date: Fri, 03 Nov 2006 21:42:56 +0100

> I guess i have to test advrename no more often, since i'm going to rename
> many of my 5GB space images...and i try to puzzle out how to do
> it with advrename. I have to admit I'm too lazy to just find out everything 
> myself 
> (the hard way, since gcmd still crashes occasionally), and so I'm going to 
> give 
> asking you for help a try =)

Please feel free to report all gcmd crashes ;o)

> Here's my first problem. I have files like
> 
>         Andromeda-NGC224=M31-1.tif
>         Andromeda-NGC224=M31-2.jpg
>         Andromeda-NGC224=M31-2.tif
>         Andromeda-NGC224=M31-3.tif
>         Andromeda-NGC224=M31-4.tif
>         Andromeda-NGC224=M31_heic0512a.jpg
>         Andromeda-NGC224=M31_heic0512d.jpg
>         BlackEyeGalaxy-NGC4826=M64_opo0404a.tif
>         CanisMajor-NGC2207-1.jpg
>         Circinus-1.tif
>         Cygni52-Witchsbroom.jpg
>         deepspace-2.jpg
>         deepspace_opo0413c.jpg
>         HCG87.tif
>         I_Zwicky_18.tif
>         M81-01_detail.tif
>         MagellanLarge-01.tif
>         MagellanSmall-NGC346_infantstars.jpg
>         MagellanSmall-NGC346.jpg
>         MagellenLarge-N11+N11B_heic0411d.jpg
>         
> I want to rename only those who are already numbered = those 
> where the filename (without extension) ends with  '-' plus a single 
> digit (num char), like the Andromeda ones above.
> 
> The new numbering scheme requires them to have two digits, like 
> Andromeda-NGC224=M31-01.tif
> To ease the task, it's affordable to select only those in question.

First select only those you need. If I grok you properly you want to rename 
files numbering 
with counter restarting from 1 for each object, right? If so, there is no other 
solution 

than repeating the following steps for each object (Andromeda-NGC224=M31,
CanisMajor-NGC2207, Circinus, ...) File selection can be done on regex basis 
(you may need change this at Options|General) with GREY_PLUS - pattern for that 
may be like '^Andromeda.*-[0-9]*\.'


Than in advrename:

Template: '$n###$c(2).$e'

Regex replacing: 
      * Replace this:      '-[0-9]+###' 
      * With this:            '-' 

That should do the work (of course, please, do remove apostrophes ;o)


Hope it'll help,

Piotr





reply via email to

[Prev in Thread] Current Thread [Next in Thread]