Table of Contents
Pre-built
Pre-built binaries are available for x86_64 Windows and Linux (GNU) on the
releases tab.
Download the appropriate one for your platform and place it somewhere in your PATH
Alternatively, use cargo-binstall:
cargo binstall forgejo-cli
From source
If you have Rust installed, you can install fj with cargo install
# Latest version
cargo install forgejo-cli
# From `main`
cargo install --git https://codeberg.org/forgejo-contrib/forgejo-cli.git --branch main
From Package Managers
Debian and Ubuntu
forgejo-cli is included in the official repositories as of Debian unstable and Ubuntu questing (25.10).
sudo apt install forgejo-cli
Fedora and RHEL
An unofficial COPR repository is available. Fedora users can install forgejo-cli with
sudo dnf copr enable lihaohong/forgejo-cli
sudo dnf install forgejo-cli
The above commands also works for RHEL 9+ and alikes (e.g. AlmaLinux)
If you see an error about copr not being an available command, run sudo dnf install dnf-plugins-core.
Guix
If it's not already done, you need to update Guix (Guix is rolling release):
guix pull
Once done you can then install forgejo-cli with the following command:
guix install forgejo-cli
Homebrew
forgejo-cli is included in Homebrew
brew install forgejo-cli
Nix
forgejo-cli is available in nixpkgs. As well, a Nix flake is included in this
repository that you may use. You could install it into your Nix profile, for example:
nix profile install git+https://codeberg.org/forgejo-contrib/forgejo-cli
...or include it in the flake inputs of your NixOS system:
{
inputs = {
# ...
forgejo-cli.url = "git+https://codeberg.org/forgejo-contrib/forgejo-cli";
};
# ...
}
OCI Container
forgejo-cli is available as an OCI container for use in CI, at
codeberg.org/cyborus/forgejo-cli:latest