Go Back

Command line tool

Usage pmedit-cli [OPTIONS] COMMAND [METADATA FIELD(S)] file [files...]

OPTIONS

  -h,  --help                     show this help message
  -rt, --renameTemplate=STRING    set a rename template for 'rename' command
                                  any metadata field enclosed in {} will be substituted
                                  with the actual field value
       --license=email,key        install Pro license and quit
                                  pass email and license ID separated with comma (no spaces) to 
                                  install Pro license from the command line.
       --releaseLicense           release current Pro license and quit
       --showLicense              show current Pro license and quit
       --offline                  set/release Pro license in offline mode

COMMANDS

  edit                            Set metadata
  clear                           Clear metadata
  rename                          Rename files from metadata
  fromfilename                    Set metadata from file names
  fromjson                        Set metadata from JSON
  tojson                          Export metadata as JSON
  fromyaml                        Set metadata from YAML
  toyaml                          Export metadata as YAML
  fromcsv                         Set metadata from CSV file
  tocsv                           Export metadata as CSV file
  xmptodoc                        Copy XMP to Document metadata
  doctoxmp                        Copy Document to XMP metadata

METADATA FIELDS

Enable field : [!]FIEDLNAME
  A field is enabled by specifying it's name. If the name is prefixed wiht ! it will be disabled.
  There are two special fields `all` and `none` which respectively enable and disable all of the fields.
  By default all fields are disabled, so you must enable at least one or the command will be a no-op.

Set a value: FIEDLNAME=value
  A field can be assigned a value with =, for example doc.title=WeeklyReport.
  Assigning a value to field also enables it.
  Fields that represent lists can be specified multiple times. 
  Dates can be specified in ISO format, e.g : 
    "2016-06-16'T'00:15:00.000'Z'" or "2016-06-16'T'00:15:00"  or
    "2016-06-16 00:15:00" or "2016-06-16"

Available fields :
  doc.title                        doc.author                       doc.subject                    
  doc.keywords                     doc.creator                      doc.producer                   
  doc.creationDate                 doc.modificationDate             doc.trapped                    
  basic.creatorTool                basic.createDate                 basic.modifyDate               
  basic.baseURL                    basic.rating                     basic.label                    
  basic.nickname                   basic.identifiers                basic.advisories               
  basic.metadataDate               pdf.pdfVersion                   pdf.keywords                   
  pdf.producer                     dc.title                         dc.description                 
  dc.creators                      dc.contributors                  dc.coverage                    
  dc.dates                         dc.format                        dc.identifier                  
  dc.languages                     dc.publishers                    dc.relationships               
  dc.rights                        dc.source                        dc.subjects                    
  dc.types                         rights.certificate               rights.marked                  
  rights.owner                     rights.usageTerms                rights.webStatement            
  viewer.hideToolbar               viewer.hideMenuBar               viewer.hideWindowUI            
  viewer.fitWindow                 viewer.centerWindow              viewer.displayDocTitle         
  viewer.nonFullScreenPageMode     viewer.readingDirection          viewer.viewArea                
  viewer.viewClip                  viewer.printArea                 viewer.printClip               
  viewer.duplex                    viewer.printScaling              viewer.pageLayout              
  viewer.pageMode                  prop.version                     prop.compression               
  prop.encryption                  prop.keyLength                   prop.ownerPassword             
  prop.userPassword                prop.canPrint                    prop.canModify                 
  prop.canExtractContent           prop.canModifyAnnotations        prop.canFillFormFields         
  prop.canExtractForAccessibility  prop.canAssembleDocument         prop.canPrintFaithful          
  file.fullPath*                   file.sizeBytes*                  file.size*                     
  file.nameWithExt*                file.name*                       file.createTime*               
  file.modifyTime*               

  * field is read only, assignment to it will be ignored
EXAMPLES

Clear all metadata:
  pmedit-cli clear all file1.pdf file2.pdf

Clear only author and title:
  pmedit-cli clear doc.title doc.author file1.pdf file2.pdf

Clear all except author and title:
  pmedit-cli clear all !doc.title !doc.author file1.pdf file2.pdf

Set author and title:
  pmedit-cli edit "doc.title=The funniest book ever" "doc.author=Funny Guy" file1.pdf file2.pdf

Rename file from author and title:
  pmedit-cli --renameTemplate "{doc.author} - {doc.title}.pdf" rename file1.pdf file2.pdf