{
  "slug": "glab-artifact-registry-login-accepts-config-file-for-maven-and-sbt-a380156634a6",
  "title": "glab artifact-registry login accepts --config-file for Maven and sbt",
  "tools": [
    "glab"
  ],
  "tags": [
    "agent"
  ],
  "introduced_at": "2026-10-27T12:17:04.369Z",
  "announced_at": "2026-10-27T12:17:04.369Z",
  "effective_at": null,
  "date_basis": "source-publication",
  "status": "unknown",
  "how": {
    "incantation": "When authenticating Maven or sbt against an Artifact Registry, pass `--config-file <file>` to `glab artifact-registry login` to write credentials to that file.",
    "examples": [
      "glab artifact-registry login --maven --registry <registry-url> --config-file <settings.xml>",
      "glab artifact-registry login --sbt --registry <registry-url> --config-file <credentials.sbt>"
    ],
    "gotchas": [
      "Version: v1.125.0",
      "--config-file <file>: File to write; for sbt, must be a `.sbt` file loaded by sbt.",
      "--maven / --sbt (required): Select the package manager to configure.",
      "--registry <url> (required): Artifact Registry URL to authenticate against.",
      "Prerequisite: Install GitLab CLI version 1.115.0 or later.",
      "Prerequisite: Authenticate `glab`; Maven and sbt login use `GITLAB_TOKEN` when set, otherwise stored credentials.",
      "Applies to Maven and sbt."
    ]
  },
  "why_it_matters": "Authenticate Maven or sbt to the artifact registry using a selected configuration file.",
  "sources": [
    "https://gitlab.com/gitlab-org/cli/-/releases/v1.125.0",
    "https://docs.gitlab.com/cli/artifact-registry/login/",
    "https://docs.gitlab.com/artifact-registry/authenticate/"
  ],
  "rank": 0.92021,
  "review_state": "approved",
  "provenance": {
    "run_id": "daily-20261027-20",
    "verdict_id": "daily-20261027-20:daily-20261027-20-2bdb5ee3afb04fc4-0:gate",
    "evidence_hash": "d80878fe7007b0e8be6ac39b6e216b951b573c495e9e5e1214e5799b17d8eb2e"
  }
}
