> ## Documentation Index
> Fetch the complete documentation index at: https://docs.foks.pub/llms.txt
> Use this file to discover all available pages before exploring further.

# Installation

> Install the FOKS CLI on your platform.

## Managed Installers

<Tabs>
  <Tab title="macOS">
    ```bash theme={null}
    brew install foks
    ```

    The Homebrew package is signed by the FOKS developers, allowing keychain access without repeated password prompts.
  </Tab>

  <Tab title="Debian / Ubuntu">
    ```bash theme={null}
    curl -fsSL https://pkgs.foks.pub/install.sh | sh
    ```

    This registers the FOKS apt repository. Subsequent updates use the normal package manager:

    ```bash theme={null}
    sudo apt-get install foks
    ```
  </Tab>

  <Tab title="Fedora">
    ```bash theme={null}
    curl -fsSL https://pkgs.foks.pub/install.sh | sh
    ```

    This registers the FOKS dnf repository. Subsequent updates:

    ```bash theme={null}
    sudo dnf install foks
    ```
  </Tab>

  <Tab title="Arch Linux">
    ```bash theme={null}
    yay -Sy go-foks
    ```
  </Tab>

  <Tab title="Windows">
    ```
    winget install foks
    ```
  </Tab>

  <Tab title="Static Linux Binary">
    For systems without a supported package manager:

    ```bash theme={null}
    curl -fsSL https://pkgs.foks.pub/install-static.sh | sh
    ```

    Static binaries do not auto-update.
  </Tab>
</Tabs>

## Build from Source

Requires Go 1.23+ with CGO enabled (for SQLite).

```bash theme={null}
go install github.com/foks-proj/go-foks/client/foks@latest
(cd $(dirname $(which foks)) && ln -s foks git-remote-foks)
foks ctl start
```

The symlink makes `foks` available as a Git remote helper under the name `git-remote-foks`.

## Linux: YubiKey Setup

YubiKey support requires the PCSC lite daemon and development library:

```bash theme={null}
sudo apt-get install libpcsclite-dev pcscd        # Debian/Ubuntu
sudo dnf install pcsc-lite-devel pcsc-lite         # Fedora
```

If your distribution restricts access to `pcscd` for non-root users, add a polkit rule:

```bash theme={null}
cat <<EOF > /etc/polkit-1/rules.d/90-pcscd.rules
polkit.addRule(function(action, subject) {
    if (action.id == "org.debian.pcsc-lite.access_pcsc" &&
        subject.isInGroup("pcscd")) {
        return polkit.Result.YES;
    }
});
EOF

sudo groupadd pcscd
sudo usermod -aG pcscd $USER
sudo systemctl daemon-reload
sudo systemctl restart polkit
sudo systemctl restart pcscd
```

Log out and back in for the group change to take effect.

## Verify Installation

```bash theme={null}
foks version
```

## Next Steps

Once installed, [start the agent and sign up](/quickstart).
