An open API service indexing awesome lists of open source software.

https://github.com/raphgl/syngit

Cross-client repository synchronization tool
https://github.com/raphgl/syngit

git mirroring synchronization

Last synced: 12 months ago
JSON representation

Cross-client repository synchronization tool

Awesome Lists containing this project

README

          



Syngit

Synchronize repositories across Git clients





Table of Contents



  1. About The Project



  2. Getting Started


  3. Usage

  4. License

  5. Acknowledgements

Syngit is a CLI and daemon that lets you synchronize repositories across different clients (Github, Codeberg, Gitlab, etc) with a very simple configuration file.
Syngit is a tool with no external dependencies (not even git). It contains everything you need, just compile it and run it.

### Built With

- [Go](https://go.dev/)
- [go-git](https://github.com/go-git/go-git)

## Getting Started

To use Syngit, make sure you got the tokens/passwords needed to authenticate for your target Git clients (ie Github, GitLab, Codeberg, etc).
After you've gotten your tokens/passwords you need a `syngit.toml` in your system's [default config directory](https://pkg.go.dev/os#UserConfigDir). The config file has the following structure:

```toml
# your main git client
main_client = "github"
# ignores all files that match the glob pattern, unimplemented!
glob_ignore = ["*cpp"]
# where the cache for syngit should be stored, defaults to https://pkg.go.dev/os#UserCacheDir
cache_dir = "~/Documents/Test"

[client.codeberg]
username = "RaphGL"
token = "my_token"

[client.github]
username = "RaphGL"
token = "my_token"
# temporarily disable synchronization to this client
disable = true

[client.gitlab]
username = "RaphGL"
token = "my_token"
# repositories to be ignored on this client
ignore = ["repo1", "repo2"]
```

### Installation

```sh
$ git clone https://github.com/RaphGL/Syngit
$ cd Syngit
$ go build
```

## Usage

1. Create a `$HOME/.config/syngit.toml` file
2. Fill out the configuration file
3. Enable the syngit service (WIP):

```sh
$ systemctl enable syngit --now
```

## License

Distributed under GPLv3 License. See [`LICENSE`](https://github.com/RaphGL/Syngit/blob/main/LICENSE) for more information.