| Crates.io | fws-rs |
| lib.rs | fws-rs |
| version | 0.1.0 |
| created_at | 2025-04-13 17:29:58.363517+00 |
| updated_at | 2025-04-13 17:29:58.363517+00 |
| description | an open source utility that facilitates selected tasks for creative usage of self-hosted Forgejo instances. |
| homepage | https://werkzeuge.techne.schloosser.com |
| repository | https://git.schloosser.net/werkzeuge/fws-rs |
| max_upload_size | |
| id | 1632012 |
| size | 104,162 |
fws-rs is an open source [command-line] utility designed to reduce reliance on the web-interface for management of repositories and users on self-hosted Git platforms, with Forgejo as its primary target platform. It facilitates repository creation, user mangement, and repository mirroring across multiple platforms.
The name fws-rs is derived from the German word "FWS" which stands for "Forgejo Werkstatt", and the suffix "-rs" indicates that it is written in Rust.
To build and install fws-rs, ensure you have Rust installed, then run:
cargo install fws-rs
cargo install --git https://git.schloosser.net/werkzeuge/fws-rs
Create a configuration file named fws.toml in your home directory in a folder named dotfiles with the following structure:
base_url = "https://your.forgejo.instance/api/v1"
token = "your_forgejo_token"
[mirrors.github]
platform = "GitHub"
token = "your_github_token"
org = "your_github_org"
[mirrors.codeberg]
platform = "Forgejo"
token = "your_codeberg_token"
org = "your_codeberg_org"
base_url = "https://codeberg.org/api/v1"
Replace the placeholders with your actual Forgejo, GitHub, and Codeberg credentials and organization names.
Run the following commands from your terminal:
fws create-repo <repository-name>
Prompts for repository visibility (public/private) and description, then creates the repository on your Forgejo instance.
fws assign-member <username>
Invites an existing user to your Forgejo organization.
fws new-member <email>
Registers a new user with the provided email and adds them to your Forgejo organization.
fws gen-mirrors <repository-name>
Creates mirror repositories on configured platforms (e.g., GitHub, Codeberg) and adds them as remotes to your local Git repository.
fws reflect-on-mirrors [--branch <branch-name>] [--mirror]
Pushes the specified branch (default: current branch) or all branches and tags (--mirror flag) to all configured mirror remotes.
This project is licensed under the MIT License. See the LICENSE file for details.