Skip to main content

CLI for Buildify bundle publish server (machine Bearer auth)

Project description

buildify-publish-cli

Command-line client for the Buildify bundle publish HTTP API. Use it to check health, validate publish keys, query bundle metadata, and upload JAR bundles from your terminal or CI.

Requires: Python 3.10 or newer.

Install

From PyPI:

pip install buildify-publish-cli

Other installers:

pipx install buildify-publish-cli
uv tool install buildify-publish-cli

After install, the command is buildify-publish.

Authentication

The API uses Bearer credentials: Authorization: Bearer <keyId>.<secret>.

Set the full secret (both parts after Bearer) as:

  • Environment variable BUILDIFY_PUBLISH_API_KEY, or
  • buildify-publish config set-api-key (reads from stdin — avoids putting the secret on the command line).

Publish keys are created and rotated in the Buildify console, not through this CLI.

Quick start

export BUILDIFY_PUBLISH_API_KEY='yourKeyId.yourSecret'

buildify-publish health
buildify-publish key test
buildify-publish bundle info --name 'my/group/plugin'
buildify-publish bundle upload \
  --name 'my/group/plugin' \
  --version '1.0.0-SNAPSHOT' \
  --file ./plugin.jar \
  --overwrite \
  --release-notes-file ./CHANGELOG.md

发布说明: bundle upload 支持 --release-notes-file(UTF-8 Markdown,通常为本仓库根目录 CHANGELOG.md),随 JAR 以 multipart 字段 releaseNote 提交至 POST /v1/bundles/versions;服务端写入 bundle_version_release_note(与控制台开发者上传、§十八 一致)。规范要求见 docs/spec/dev-spec.md §17.7。

API base URL

Default: https://publish.buildify.cn

Override for self-hosted or other environments:

export BUILDIFY_PUBLISH_BASE_URL='https://your-publish-host.example.com'
# or per invocation:
buildify-publish --base-url 'https://your-publish-host.example.com' health

Persist in ~/.buildifyrctwo separate settings (set either or both; order does not matter):

  • base_url — which publish API host to call (default host above if unset).
  • api_key — your publish credential keyId.secret, unrelated to the URL.
# Set only the API host (skip if the default https://publish.buildify.cn is fine)
buildify-publish config base_url https://publish.buildify.cn

# Set only the key (stdin avoids putting the secret in shell history)
printf '%s' 'keyId.secret' | buildify-publish config set-key api_key

buildify-publish config show

Use config set-key / config set_key with base_url or api_key. For api_key, omit the value or use - to read from stdin.

Shortcuts config set-base-url and config set-api-key update the same two fields.

File: ~/.buildifyrc (Unix) or %USERPROFILE%\.buildifyrc (Windows). Precedence: CLI flags → BUILDIFY_PUBLISH_BASE_URL / BUILDIFY_PUBLISH_API_KEY → file → default base URL.

Built-in reference

Full Markdown reference (commands, env vars, HTTP mapping, exit codes, JSON schema):

buildify-publish help

Same content ships as usage.md inside the package.

Scripting and CI

Machine-readable output (one JSON object per run):

export BUILDIFY_PUBLISH_JSON=1
buildify-publish --json key test

Environment: BUILDIFY_PUBLISH_BASE_URL, BUILDIFY_PUBLISH_API_KEY, BUILDIFY_PUBLISH_JSON, NO_COLOR.

Global flags: --json, --api-key, --base-url, --quiet.

Developing from source

If you have the Git repository checked out:

cd tools/buildify-publish-cli
python3 -m venv .venv && source .venv/bin/activate
pip install -U pip
pip install .

Run without installing into the environment:

python -m buildify_publish --help

License

Same as the upstream project repository unless stated otherwise.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

buildify_publish_cli-1.0.3.tar.gz (12.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

buildify_publish_cli-1.0.3-py3-none-any.whl (13.7 kB view details)

Uploaded Python 3

File details

Details for the file buildify_publish_cli-1.0.3.tar.gz.

File metadata

  • Download URL: buildify_publish_cli-1.0.3.tar.gz
  • Upload date:
  • Size: 12.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.9.6

File hashes

Hashes for buildify_publish_cli-1.0.3.tar.gz
Algorithm Hash digest
SHA256 65374c1f1495f234a027028f54f5176558292ab8d6505fb01da625d6508c2cf0
MD5 b3b23e77d61b139ab4c43c1e5dff78b4
BLAKE2b-256 569826b985893c9477551a6457d14f14af7b5bb22ca1edc07eb5d427fe9a11f0

See more details on using hashes here.

File details

Details for the file buildify_publish_cli-1.0.3-py3-none-any.whl.

File metadata

File hashes

Hashes for buildify_publish_cli-1.0.3-py3-none-any.whl
Algorithm Hash digest
SHA256 f3af998dbe53a5f32fba367f69d1d2a9995287f5a9f4768e1fa0e6e82aa8a3b2
MD5 b233404a0299bc1ba7a1b4e561194535
BLAKE2b-256 f6c99ab303256f98bf2e18bf03de435630cb114b620516f87cdc6469f0df7c46

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page