Skip to content

Latest commit

 

History

History
107 lines (89 loc) · 3.88 KB

File metadata and controls

107 lines (89 loc) · 3.88 KB

CLI reference

ptsync

Merge Google Takeout and iCloud photo exports into one deduplicated, date-organized archive of
ordinary files and Markdown notes

Usage: ptsync [OPTIONS] <COMMAND>

Commands:
  info  Show info for an individual photo or video
  db    Scan files in an archive or directory and collect meta info into a sqlite database
  sync  Sync files in an archive or directory into a standardised directory structure
  help  Print this message or the help of the given subcommand(s)

Options:
  -d, --debug                Turn debugging information on
  -z, --timezone <TIMEZONE>  UTC offset to use when localizing UTC dates - `+12:00`, `-04:00`,
                             `+0545` or `+00:00` (else `TZ` env var, else the machine's zone)
  -h, --help                 Print help
  -V, --version              Print version

ptsync info

Show info for an individual photo or video

Usage: ptsync info [OPTIONS] --root <ROOT> --input <INPUT>

Options:
  -r, --root <ROOT>          The takeout or iCloud zip/directory
  -i, --input <INPUT>        Photo, video or album to view info for
  -z, --timezone <TIMEZONE>  UTC offset to use when localizing UTC dates - `+12:00`, `-04:00`,
                             `+0545` or `+00:00` (else `TZ` env var, else the machine's zone)
  -h, --help                 Print help

ptsync db

Scan files in an archive or directory and collect meta info into a sqlite database

Usage: ptsync db [OPTIONS] --input <INPUT>

Options:
  -i, --input <INPUT>
          The takeout or iCloud zip/directory
  -o, --output <OUTPUT>
          Path to the sqlite database file to write [default: db.sqlite]
  -z, --timezone <TIMEZONE>
          UTC offset to use when localizing UTC dates - `+12:00`, `-04:00`, `+0545` or `+00:00`
          (else `TZ` env var, else the machine's zone)
      --clear <CLEAR>
          Clear existing rows before scanning; also rebuilds the database if its schema is out of
          date [default: false] [possible values: true, false]
      --skip-media
          Skip inspecting photo and video files; leaves the media_item tables untouched, so only the
          classified tables are written
      --skip-albums
          Skip inspecting albums
      --s3-region <S3_REGION>
          AWS region for `s3://` paths (else `AWS_REGION` / the profile's region)
      --s3-endpoint-url <S3_ENDPOINT_URL>
          Custom S3 endpoint URL for S3-compatible stores like MinIO; enables path-style addressing
      --s3-profile <S3_PROFILE>
          AWS profile name for `s3://` paths (else `AWS_PROFILE` / `default`)
  -h, --help
          Print help

ptsync sync

Sync files in an archive or directory into a standardised directory structure

Usage: ptsync sync [OPTIONS] --input <INPUT>

Options:
  -n, --dry-run
          If set, don't do anything, just print what would be done
      --input <INPUT>
          Google Takeout or iCloud input directory or zip file
  -z, --timezone <TIMEZONE>
          UTC offset to use when localizing UTC dates - `+12:00`, `-04:00`, `+0545` or `+00:00`
          (else `TZ` env var, else the machine's zone)
  -o, --output <OUTPUT>
          Directory to sync photos and videos into
      --skip-markdown
          Skip generating markdown files
      --skip-media
          Skip inspecting and copying photo and video files
      --skip-albums
          Skip inspecting and copying albums
      --s3-region <S3_REGION>
          AWS region for `s3://` paths (else `AWS_REGION` / the profile's region)
      --s3-endpoint-url <S3_ENDPOINT_URL>
          Custom S3 endpoint URL for S3-compatible stores like MinIO; enables path-style addressing
      --s3-profile <S3_PROFILE>
          AWS profile name for `s3://` paths (else `AWS_PROFILE` / `default`)
  -h, --help
          Print help