glab(1)

NAME
glab-packages-download - Download a file from a project's package registry.

SYNOPSIS
glab packages download --name --version --filename [flags]

DESCRIPTION
Download a generic package file, identified by its package name, version, and file name.

Use --path to choose where the file is saved. If it names a directory (it ends with a separator or already exists as one), the file is saved there under its original name. Otherwise it is saved as that exact path, letting you rename the file. By default the file is saved in the current directory under its original name.

By default, the downloaded file is verified against the checksum stored in the registry. This requires extra API calls to look up the file's metadata. Use --no-verify to skip verification. This can allow corrupted or tampered files; use with caution.

If the target file already exists, the download fails. Use --force to overwrite it.

By default, files are downloaded from the current project. Use --repo to target another project.

OPTIONS
--filename=""
    Name of the file within the package to download.

--force[=false]
    Overwrite the target file if it already exists.

-n, --name=""
    Name of the package.

--no-verify[=false]
    Do not verify the checksum of the downloaded file. Warning: when enabled, this setting allows the download of files that are corrupt or tampered with.

-p, --path=""
    Directory to save the file in (keeps its original name) or a full file path to rename it. Defaults to the original name in the current directory.

--version=""
    Version of the package.

OPTIONS INHERITED FROM PARENT COMMANDS
-h, --help[=false]
    Show help for this command.

-R, --repo=""
    Select another repository. You can use either OWNER/REPO or GROUP/NAMESPACE/REPO. The full URL or Git URL is also accepted.

EXAMPLE
    # Download a package file to the current directory
    glab packages download --name my-package --version 1.0.0 --filename app.zip
    # Download into a directory, keeping the original file name
    glab packages download -n my-package --version 1.0.0 --filename app.zip --path ./downloads/
    # Download to an exact path, renaming the file
    glab packages download -n my-package --version 1.0.0 --filename app.zip --path ./downloads/renamed.zip
    # Download without verifying the checksum
    glab packages download -n my-package --version 1.0.0 --filename app.zip --no-verify
    # Overwrite an existing file
    glab packages download -n my-package --version 1.0.0 --filename app.zip --force
    # Use the 'dl' alias and target another project
    glab packages dl -n my-package --version 1.0.0 --filename app.zip -R owner/repo

SEE ALSO
glab-packages(1)