Install
CLI

Artifacts

Upload, download, search, copy, move and delete artifacts, set properties, and run cleanup and holds.

Upload a file. The command prints its <repository>/<path> and SHA-256:

relic artifact upload app-1.0.jar libs-local/org/app/1.0/app-1.0.jar

Upload into a folder, keeping the file's name (libs-local/app/app.tar.gz):

relic artifact upload dist/app.tar.gz libs-local/app/

Download a file to ./app-1.0.jar:

relic artifact download libs-local/org/app/1.0/app-1.0.jar

Write a file to standard output:

relic artifact download libs-local/notes.txt -o - | less

Find items whose name contains a text (at least two characters, any case):

relic artifact search app-1.0 --repository libs-local

Copy, move and delete

Copy a file to another repository:

relic artifact cp libs-local/org/app/1.0/app.jar libs-release/org/app/1.0/app.jar

Check that copying a folder into a folder would work:

relic artifact cp libs-local/org/app/1.0 libs-release/org/app/ --dry-run

Move several files into a folder:

relic artifact mv libs-local/a.txt libs-local/b.txt libs-archive/2026/

Delete a folder and a file, ignoring items already gone:

relic artifact rm libs-local/org/app/0.9 libs-local/tmp.txt --ignore-not-found
  • A destination ending in / is a folder, as is any destination of several sources. Sources keep their names in it.
  • Folders go with everything below them.
  • Deleted items go to the trash.

Cleanup policies

Cleanup policies are CleanupPolicy resources (Repositories), run daily by the worker. Viewers and administrators can preview a policy; administrators can run it.

List what a policy would move to the trash now:

relic cleanup preview old-snapshots

Run it now:

relic cleanup run old-snapshots

A held item, or a held folder with everything under it, cannot be deleted, moved, overwritten or cleaned up. Administrators place and release holds (Repositories).

Place a hold on a folder:

relic hold add libs-local/org/app/1.4.0 --reason "audit 2026-14"

List the holds:

relic hold list

Release the hold:

relic hold remove libs-local/org/app/1.4.0

Properties

Set properties on a folder and everything below it. set replaces the values of the keys it names and leaves other keys alone:

relic artifact props set libs-local/org/app/1.0 release=1.0 qa=passed,signed --recursive

Print a file's properties as JSON:

relic artifact props get libs-local/org/app/1.0/app.jar -o json

Delete a property from a folder and everything below it:

relic artifact props delete libs-local/org/app/1.0 qa --recursive

Git LFS objects

A Git LFS repository serves the Git LFS API at https://relic.example.com/lfs/<repo> and keeps one file per object, named by its sha256 id, at objects/<id[0:2]>/<id[2:4]>/<id>. Point git-lfs at it in .lfsconfig:

[lfs]
url = https://relic.example.com/lfs/lfs-local

git-lfs reads your credentials from the Git credential helper. Relic answers the batch API with the basic transfer adapter, through links valid for an hour. It does not lock files: lock verification finds no locks, and git lfs lock answers 501.

relic artifact lfs clean, run in a Git working tree, deletes the objects no LFS pointer in the matching references names. Without a repository argument, it uses the repository in lfs.url of .lfsconfig or the Git config.

Preview the cleanup:

relic artifact lfs clean --dry-run -v

Clean a repository against the local branches and tags:

relic artifact lfs clean lfs-local --refs 'refs/heads/**,refs/tags/**' -o json

--refs takes git for-each-ref patterns (* stops at /, ** does not) and defaults to refs/remotes/**. Files not named like LFS object ids are left alone.

Output and completion

Commands that print lists or reports take -o text|json|yaml (relic get also name). Scripts should read JSON; text tables may change. In relic artifact download, -o is the file to write, or a directory (existing, or ending in /) to write into.

On a terminal, slow commands show a spinner on standard error, except commands that ask a question (relic auth login, relic server setup, stop, uninstall).

relic completion bash|zsh|fish|powershell prints a shell completion script. It completes names from the server: repositories and paths, the resources of relic get, releases, builds, webhooks, cleanup policies, and the values of --repository and --watch.