Startsidan  ▸  Texter  ▸  Teknikblogg

Anders Hesselbom

Programmerare, skeptiker, sekulärhumanist, antirasist.
Författare till bok om C64 och senbliven lantis.
Röstar pirat.

Photoname Portable

2010-04-10

The portable version of Photoname (pnp.exe) doesn’t have a GUI, but it is pretty simple to use anyway. You can either start it from the command interface and pass arguments to it to tell it what to do, or you can double click on it, and then tell it what to do. If you want to control pnp.exe from another application, you must know what arguments you can pass to it.

So, pnp.exe is a portable, lightweight GUI-less version of Photoname.
Some of the commands that you can run if you start it without arguments, that is, just by double clicking it:

Load {Filename} loads an image into memory. If the path or filename contains a space, you need quotation marks around it. Example:

Load "C:\Images\CW005132.jpg"

To view information about the loaded image, type Info. If you provide a filename, that file is loaded and info about that file is displayed. Example:

Info

Info "C:\Images\CW005133.jpg"

To rename one single file, use Rename File {Filename}. Example:

Rename File "C:\Images\CW005134.jpg"

If you ignore the filename, the currently loaded file will be renamed. To rename all files, use Rename Dir {Directory name}. Example:

Rename Dir "C:\Images"

Files that already match the RegEx pattern \d{14}_\d*\.(jpg|jpeg) will be ignored. If photodate is missing in the file, the change date will be used instead. The renamed file will be unloaded from memory in the process of renaming.

Photoname Portable can only handle full path, not relative paths.

For each file that Photoname Portable tries to rename, the output will be a text line that starts with “Ok.” for successful name change and “Rename failed.” for unsuccessful name change.

If you want to use the portable version to rename all images that need renaming, without any tricky typing, you can just type Dir? in the command prompt. Photoname Portable will ask you for a directory, do the name changes and then exit. Example:

Dir?

If you are automating Photoname Portable from another application, consider not sending “Dir?” to it. 😉 The folder browser might show up behind the console window.

Download Photoname Portable (25kb).

Categories: Programs

Tags: PhotoName, Photoname Portable

2 responses to “Photoname Portable”

  1. […] This post was mentioned on Twitter by Anders Hesselbom. Anders Hesselbom said: New blog post: Photoname Portable https://www.winsoft.se/2010/04/photoname-portable/ […]

  2. […] is basically a Swedish version of this […]

Leave a Reply

Your email address will not be published. Required fields are marked *



En kopp kaffe!

Bjud mig på en kopp kaffe (20:-) som tack för bra innehåll!

Bjud på en kopp kaffe!

Om...

Kontaktuppgifter, med mera, finns här.

Följ mig

Twitter Instagram
GitHub RSS

Public Service

Folkbildning om public service.

Hem   |   linktr.ee/hesselbom   |   winsoft.se   |   80tal.se   |   Filmtips