Home Download Docs Code Community

Installation

go get perkeep.org/cmd/pk-put

Overview

The pk-put tool mainly pushes blobs, files, and directories. It can also perform various related tasks, such as setting tags, creating permanodes, and creating share blobs.

Usage:

pk-put [globalopts] <mode> [commandopts] [commandargs]

Modes:

delete: Create and upload a delete claim.
attr: Add, set, or delete a permanode's attribute.
file: Upload file(s).
init: Initialize the pk-put configuration file. With no option, it tries to use the GPG key found in the default identity secret ring.
permanode: Create and upload a permanode.
rawobj: Upload a custom JSON schema blob.
share: Grant access to a resource by making a "share" blob.
blob: Upload raw blob(s).

Examples:

pk-put file [opts] <file(s)/director(ies)
pk-put file --permanode --title='Homedir backup' --tag=backup,homedir $HOME
pk-put file --filenodes /mnt/camera/DCIM

pk-put blob <files>     (raw, without any metadata)
pk-put blob --permanode --title='My Blob' --tag=backup,my_blob
pk-put blob -           (read from stdin)

pk-put permanode                                (create a new permanode)
pk-put permanode --title="Some Name" --tag=foo,bar (with attributes added)

pk-put init
pk-put init --gpgkey=XXXXX

pk-put share [opts] <blobref to share via haveref>

pk-put rawobj (debug command)

pk-put attr <permanode> <name> <value>         Set attribute
pk-put attr --add <permanode> <name> <value>   Adds attribute (e.g. "tag")
pk-put attr --del <permanode> <name> [<value>] Deletes named attribute [value

For mode-specific help:

pk-put <mode> -help

Global options:

-help=false: print usage
-secret-keyring="~/.gnupg/secring.gpg": GnuPG secret keyring file to use.
-server="": Perkeep server prefix. If blank, the default from the "server" field of
~/.camlistore/config is used.
Acceptable forms: https://you.example.com, example.com:1345 (https assumed),
or http://you.example.com/alt-root
-verbose=false: extra debug logging
-verbose_http=false: show HTTP request summaries
-version=false: show version
Website layout inspired by memcached.
Content by the authors.