Skip to content

Contributing to File Browser Next

File Browser Next is an actively maintained project. Pull requests, bug reports, and feature proposals are welcome.

Project Structure

The backend is written in Go and the frontend (in the frontend/ subdirectory) is written in Vue.js. Some features are tightly coupled between the two layers, so a basic understanding of both is recommended.

Clone the repository:

git clone https://github.com/FilebrowserNext/filebrowserNEXT

Build

Build the complete project (frontend + backend) in two steps:

# 1. Build the frontend assets
cd frontend
pnpm install
pnpm run build
cd ..

# 2. Compile the Go binary (embeds the built frontend)
go build -o filebrowser .

Development

Frontend

Requirements: Node.js >= 24.0.0, pnpm >= 10.0.0.

cd frontend

# Install dependencies
pnpm install

# Watch mode — serves the UI with hot reload
pnpm run dev

When using pnpm run dev, access the interface through the Vite development server URL, not through the Go binary directly.

To produce a static build of the frontend (required before building the Go binary):

pnpm run build

Backend

# Download Go module dependencies
go mod download

# Build
go build -o filebrowser .

# Run directly
go run . -r /path/to/your/files

Documentation

Documentation lives in docs/ and is built into a static site with MkDocs and published to GitHub Pages.

To preview the documentation locally:

pip install mkdocs-material
mkdocs serve

The CLI reference pages in docs/cli/ are generated from the commands themselves. After changing any CLI command, regenerate them:

go run . cmds generate-docs docs/cli/

Translations

Locale files live in frontend/src/i18n/ and can be edited directly. To add a new language, copy an existing locale file and translate the strings.

Release

Releases are created via GitHub Actions. To trigger a release, push a Git tag:

git tag v3.x.x
git push origin v3.x.x

The CI workflow builds binaries for all supported platforms (Linux amd64/arm64, macOS amd64/arm64, Windows amd64), packages them as archives, and publishes them to the GitHub release.

Authentication Provider

To build a custom authentication provider, implement the Auther interface defined in auth/auth.go:

// Auther is the authentication interface.
type Auther interface {
    // Auth is called to authenticate a request.
    Auth(r *http.Request, usr users.Store, stg *settings.Settings, srv *settings.Server) (*users.User, error)
    // LoginPage indicates if this auther needs a login page.
    LoginPage() bool
}

After implementing the interface:

  1. Add it to the auth/ directory.
  2. Register it in the configuration parser (addConfigFlags).
  3. Register it in the auth storage backend.

Code of Conduct

By participating in this project you agree to abide by the Code of Conduct.