Skip to content

Other Commands

A grab-bag of utility commands that don’t fit the main resource families.

Make authenticated requests to any Redmine REST API endpoint.

Terminal window
redmine api /users/current.json
redmine api /issues.json -f project_id=myproject -f limit=5
Flag Description
-X, --method HTTP method (default: GET, or POST when a body is provided)
-f, --field Query parameter as key=value (repeatable)
-F, --raw-field JSON body field as key=value (repeatable)
--input Read request body from file (- for stdin)
-i, --include Show response status line and headers
--silent Suppress response output
Terminal window
redmine categories list --project <identifier>

Lists issue categories for a project.

Terminal window
redmine trackers list
redmine trackers get Bug

Lists all available trackers. The list view includes the default status for each tracker, and trackers get shows richer metadata such as enabled standard fields when the Redmine server exposes them.

Terminal window
redmine statuses list

Lists all issue statuses.

Terminal window
redmine custom-fields list
redmine custom-fields get "Severity"
redmine custom-fields get 7 --output json

Lists or inspects custom field definitions. The list view surfaces target resource type, field format, and the required/filter/searchable/multiple flags. custom-fields get adds the default value, length and regexp constraints, possible values for list fields, plus the trackers and roles a field is restricted to.

Terminal window
redmine completion bash > /etc/bash_completion.d/redmine

Completion candidates such as tracker, version, category and member names come from the server. The bash script quotes them before bash sees them, so a name like $(cmd) is offered as text and never run; candidates containing line breaks are dropped and control characters are neutralized. Bash scripts generated by older versions passed candidates to bash unquoted: if you saved the output of redmine completion bash to a file, regenerate it after upgrading.

Completion honors the global flags already on the command line, so redmine --profile work issues list --project <TAB> (likewise --config, --server, --api-key-file) completes against that profile or server. With --api-key-file -, completions that need the server are skipped instead of reading the key from the terminal.

checksum verified attestation verified
Terminal window
redmine update

Checks GitHub for the latest release, downloads it, and replaces the current binary only after two checks pass:

  1. Checksum — the archive’s SHA256 must match the release’s checksums file.
  2. Attestation — the archive’s SHA256 must have a GitHub artifact attestation (SLSA build provenance, signed through Sigstore and recorded in its transparency log) issued by this repository’s release.yml workflow for exactly the release tag being installed.

Besides the repository, the built-in check pins the signer workflow and the source ref, so it is stricter than gh attestation verify --repo aarondpn/redmine-cli alone. The equivalent gh command is below (Windows archives end in .zip). install.sh runs it when a recent gh is installed and logged in; otherwise the script installs after the checksum check only and prints the command so you can run it yourself (see Installation):

Terminal window
gh attestation verify redmine-cli-<os>-<arch>.tar.gz --repo aarondpn/redmine-cli \
--signer-workflow aarondpn/redmine-cli/.github/workflows/release.yml \
--source-ref refs/tags/<tag>

The checksums come from the same place as the archive, so only the attestation proves the binary was built by the project’s release pipeline. The update is refused if the attestation is missing, invalid, or signed by any other identity. A release is attested a few minutes after it is published; if you update within the first 30 minutes and its attestation is not there yet, redmine update says so and asks you to try again shortly instead of reporting a failed verification.

When installed via Homebrew, delegates to brew upgrade.

Flag Description
--skip-attestation Install with checksum verification only. Prints a warning.

Verification needs to reach api.github.com (attestations API) and tuf-repo-cdn.sigstore.dev (Sigstore trusted root, cached for a day under your user cache directory). If either is unreachable, redmine update refuses to install and suggests --skip-attestation. Set GITHUB_TOKEN or GH_TOKEN to avoid GitHub API rate limits; it is only sent to api.github.com.

If the binary’s directory is not writable, the error suggests reinstalling with the install.sh from the same release tag rather than from main.

On every invocation, redmine checks GitHub for a newer release in the background. When one is available, a notice is printed to stderr after the command output:

A new version of redmine is available: v1.2.0 → v1.3.0
https://github.com/aarondpn/redmine-cli/releases/tag/v1.3.0
Run "redmine update" to upgrade

The check starts in the background together with the command and gives up 2 seconds after startup. Its result is only printed after a command that succeeded; a failed command exits right away. If the check is still running when the command finishes, the CLI waits for it, at most until that 2-second deadline, and prints Checking for updates... to stderr once the wait exceeds 200 ms. A fresh cached result (see below) answers immediately, so the delay only happens when GitHub has to be asked: once a day after a successful check, but on every run while checks fail or time out (failures are not cached). It is automatically skipped when:

  • the command is redmine update itself;
  • stderr is not a TTY (piped output, CI);
  • REDMINE_NO_UPDATE_CHECK is 1 or true.

The result is cached for 24 hours in ~/.redmine-cli-update-check.json (readable only by you). A cache entry whose release URL is not a release page under https://github.com/aarondpn/redmine-cli/releases/tag/ is ignored, so a tampered cache cannot inject a link into the notice.

To disable permanently:

Terminal window
export REDMINE_NO_UPDATE_CHECK=1