PDFs mal schnell Taggen

by hubi on 11/06/2009

Ich möchte gerade meinen persönlichen Papierstapel digitalisieren. Dabei hilft mir ein cooler Multi-Funktions-Drucker, der mir die eingescannten Seiten direkt als PDF auf den Rechner kopiert. Jetzt stehe ich nur vor dem Problem, dass ich die Dateien zwar auch entsprechend benennen möchte, aber in erste Linie über Schlagwörter sortieren möchte, die Spotlight ja auch indiziert. Die Vorschau (wohl seit 10.4) und auch Adobe Acrobat können diese Keywords in die Metadaten schreiben, nur ist das heftigst umständlich! Da ich für einige PDF-Skripte pdftk installiert habe, habe ich mir kurzerhand ein weiteres Skript-Programm erstellt, mit dem die Meta-Daten von PDF-Dateien leicht abändern lassen. Damit lassen sich vor allen Dingen auch die Schlagworte (Keywords) der PDF-Dateien schön schnell erweitern. Also, bevor das Programm genutzt werden kann, muss pdftk installiert sein. Ein Installer gibt es z.B. hier oder einfach selber über die Darwin-Ports kompilieren.PDF Meta Edit Screenshot

Update v0.2 (07.09.2009):

DOWNLOAD
PDF Meta Edit v.0.2
363.71 KB (2364 hits)

Kleiner Bugfix, damit mit PDFs auch korrekt gespeichert werden unter 10.6

Updates 15.02.2011

Für Snow Leopard gibt es mittlerweile eine fertig kompilierte Version direkt vom "Hersteller" von pdftk

There are 13 comments in this article:

  1. 12/06/2009fidel says:

    hi,

    wenns dir nur um die Auffindbarkeit via Spotlight gehen würde ... würde sich das ganze auch via Finder-Selections and Spotlight Tags im Get-Info Feld leicht halbautomatisch erschlagen lassen a la


    tell application "Finder"
    activate

    -- get selected items
    set fileList to selection

    -- Check if there is something selected in Finder
    if (count result) is 0 then
    try
    get (target of front Finder window) as alias
    on error
    choose folder with prompt "Set comments of files in this folder:"
    end try

    try
    set theFolder to result
    set fileList to every file of folder (result) as alias list
    end try
    end if

    -- Comment Dialog
    display dialog "Comment:" default answer "" buttons {"Overwrite", "Cancel", "Append"} default button 3 with title "Set Spotlight Comments"

    -- Save Result
    set userInput to the result
    set newComment to text returned of userInput

    -- If Overwrite
    if (button returned of userInput) is "Overwrite" then
    if (class of first item of fileList) is alias then
    set comment of every file of folder theFolder to newComment
    else
    repeat with thisFile in fileList
    set comment of thisFile to newComment
    end repeat
    end if
    else
    -- If Append
    repeat with thisFile in fileList
    tell thisFile
    if length of (comment as text) is not 0 then
    get ", " & newComment
    else
    get newComment
    end if
    set comment to (comment & result)
    end tell
    end repeat
    end if
    end tell

    Gruß
    fidel

  2. 13/06/2009Hubi says:

    Ja, auch möglich... Der Weg wäre mir aber zu speziell, die Keywords aus den PDF Tags kann jeder auslesen, deshalb mache ich ja pdfs draus. Spotlight Kommentare werden aber nicht in der Datei selben gespeichert.
    Was würde ich also machen, wenn ich auf einmal auf Windows 7 umsteige ;-)

  3. 30/07/2009VLC says:

    Gut!

  4. 8/09/2009hubionmac.com » Kleiner Bugfix in PDF MetaEdit says:

    [...] September, 2009 (00:04) | Software I Use, hubionmac.com, pdf | By: hubi PDF MetaEdit Ist ein kleines Tool, dass ich zum Editieren der Meta-Daten von PDFs nutze, damit diese leichter [...]

  5. 24/11/2009adam says:

    hiya. thanks for the tool. would really really appreciate it if you can repeat the instructions again in english :) thanks for the tool!

  6. 7/01/2011bas_der_gruene says:

    Hallo hubi,

    ich habe gerade dein kleines Progrämmchen gefunden und für hilfreich befunden. Vorher hatte ich das: http://www.sybrex.com/products/macgui/infomanager/ gefunden aber für nicht hilfreich befunden. Macht nur murks mit irgendwelchen Sonderzeichen. Ein shellscript hab ich auch gefunden, was nach anpassung (stat verhält sich auf os x anders) auch lief: http://bloc.eurion.net/archives/2010/command-line-script-to-edit-pdf-file-meta-data/

    Nun stelle ich aber fest, dass Acrobat (hier Version 8) diese Informationen nicht anzeigt und stattdessen andere anzeigt. Weißt du was davon? Vielleicht hat das irgendwas mit einer anderen PDF-Version zu tun und unterschiedliche Arten wie Meta-Daten gespeichert werden? Irgendeinen Plan wie man sowas ergooglen kann?

    Vorschau wiederum zeigt die per pdftk (oder pdf MetaEdit) hinzugefügten Daten an...

    (und wo ich es gerade bemerke: Dein captcha-Plugin collidiert mit der WordPress-Schutzfunktion gegen doppelt Kommentare - geht man von der captcha-abfrage wieder zurück um etwas zu ändern meint wordpress den kommentar ablehne zu müssen)

  7. 7/01/2011bas_der_gruene says:

    Nochmal Ich.

    Ich habe jetzt endlich herausgefunden, dass Acrobat xmp-Metainformationen für die pdfs nutzt und diese über die pdfformat-spezifischen setzt. xmp kann man wohl mit exiftool editieren oder mit BeCyPDFMetaEdit (win, läuft aber gut über wine) löschen. Falls du das irgendwann in PDF MetaEdit implementieren möchtest oder leser hier vor dem gleichen Problem stehen wie ich.

    Guten Gruß, bas

  8. 7/01/2011Hubi says:

    Nun der Entwickler von pdftk schrieb da dazu..
    # Also, the author of pdftk (Sid Steward) has this to say about the
    # XMP stream:
    #
    # PDFs store this metadata is two places: the Info dictionary and
    # the XMP (RDF/XML) stream. Pdftk updates only the Info dictionary,
    # but newer versions of Acrobat/Reader defer to the XMP stream.
    #
    # I am currently working on new features for updating both the Info
    # dictionary and the XMP stream.
    #
    # One workaround might be to remove the PDF's XMP stream. You can do
    # this using pdftk, but it also removes bookmarks and other PDF
    # features. Run:
    #
    # pdftk mydoc.xmp.pdf cat output mydoc.no_xmp.pdf
    #
    # to burn of the XMP stream. Then maybe the viewer will fall back to
    # the Info dictionary with your updated data.

  9. 7/01/2011Hubi says:

    könntest Du mir vielleicht mal ein solches PDF mit XMP-Informationen zukommen lassen?

  10. 7/01/2011bas_der_gruene says:

    ist unterwegs

  11. 25/01/2011» Edit Pdf Metadata jsilence.org says:

    [...] for a convenient tool to solve this I came across pdftk, which can be installed via MacPorts or other sources (Link target in german). pdftk allows you to manipulate a couple of aspects of a pdf file, among [...]

  12. 3/10/2011Micke De Geer says:

    Hi,

    I tried your tool, PDF_MetaEdit, and got it to work with Pdftk. But I think I may be doing something wrong...when I change a meta tag, e.g. Title, I get strange characters:

    䠀☀䴀 儀㄀ ㈀ ㄀㄀

    I'll appreciate any help :)

    Best regards,
    Micke
    PS. Sorry - my German is not really up to speed..

  13. 20/10/2011Hubi says:

    Hi Micke,

    hm... did you add any special characters or does this even happen on normal strings like "abc"?
    Because pdftk has a really hard stand on working with special characters :-/

Write a comment:

CAPTCHA:


− one = 1