{"id":22694874,"url":"https://github.com/f1nnix/rc","last_synced_at":"2026-05-01T15:34:44.012Z","repository":{"id":70538374,"uuid":"151267969","full_name":"f1nnix/rc","owner":"f1nnix","description":"Simple and effective CLI-frontend for rclone. rc provides a flexible command subset for advanced bi-directional sync over multiple rclone remotes.","archived":false,"fork":false,"pushed_at":"2018-10-07T12:32:03.000Z","size":6,"stargazers_count":2,"open_issues_count":1,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-02-04T18:42:34.131Z","etag":null,"topics":["automation","bash","go","golang","rclone","sync","synchronization"],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/f1nnix.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2018-10-02T14:25:47.000Z","updated_at":"2023-02-10T10:38:42.000Z","dependencies_parsed_at":"2023-05-18T02:45:29.673Z","dependency_job_id":null,"html_url":"https://github.com/f1nnix/rc","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/f1nnix%2Frc","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/f1nnix%2Frc/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/f1nnix%2Frc/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/f1nnix%2Frc/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/f1nnix","download_url":"https://codeload.github.com/f1nnix/rc/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246223274,"owners_count":20743158,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["automation","bash","go","golang","rclone","sync","synchronization"],"created_at":"2024-12-10T03:10:07.145Z","updated_at":"2026-05-01T15:34:43.964Z","avatar_url":"https://github.com/f1nnix.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# rc\n\nSimple and effective CLI-fronted for [rclone](https://github.com/ncw/rclone).\n\n`rc` provides a flexible command subset for advanced bi-directional sync over multiple [rclone](https://github.com/ncw/rclone) remotes.\n\n## How it works\n\nLet's say we have several configured remotes in rclone config:\n\n* `db` — Dropbox remote;\n* `yd` — Yandex Disk remote;\n* ...any other remotes with supported backend.\n\nAssuming this, let's see how `rc` helps to manage vaults over these storage backends:\n\n| Command                  | Description                                                                                 |\n|:-------------------------|:--------------------------------------------------------------------------------------------|\n| `rc db`                  | Sync local folder `~/db/` to remote `db:/`                                                  |\n| `rc yd:/vim`             | Sync local folder `~/yd/vim/` to `yd:/vim/`                                                 |\n| `rc docs`                | Encrypt local folder `~/Documents/work` and sync encrypted files to remote `db:/encrypted`, |\n| `rc books:/Zelazny down` | Sync remote folder `db:/library/Zelazny/` to  `~/calibre/Zelazny`                             |\n\nThe core idea of `rc` is to define several higher-level remotes in rc config, which inherit actual `rclone` ones. When you run `rc books:/Zelazny down` command, the following pipeline is applied:\n\n1. `rc` parses provided arguments:\n    * `books` — remote name;\n    * `/Zelazny` — so-called userPath;\n    * `down` — sync direction. Down means \"from remote to local\", and vice versa.\n2. `rc` searches for remote `books` in `.config.yml`. Let's say config is:\n    ```yml\n    base_dir: /Users/user\n    options:\n      exclude: [\".DS_Store\"]\n    remotes:\n      books:\n        remote: db\n        path: /library\n        local_path: /calibre\n    ```\n3. `rc` build local dir path and remote one:\n    1. **Local:** `base_dir + (remote | local_path) + userPath`. Will generate `/Users/user/calibre/Zelazny/`.\n    2. **Remote:** `remote:remote_path + userPath`. Will generate `db:/library/Zelazny/`.\n4. `rc` applies options from global config options, such as `exclude`.\n5. `rc` runs `rclone --exclude=.DS_Store sync db:/library/Zelazny /Users/user/calibre/Zelazny`\n\n### Encryption\n\nYou may wish to encrypt remote files and sync to remote directory like `enc_storage`. To do this:\n\n1. Create with `rclone config` actual storage backend in rclone, for example `db\u003cDropbox\u003e`, or use existing.\n2. Create with `rclone config` crypt storage backend in rclone. For `path`, specify actual `remote` and `path`, where encrypted files will be physically placed on remote storage. Example: `db:/enc_storage`.\n3. Create rc-remote in config, e. g. `docs`. For `remote` specify crypt storage from step 2.\n    1. By default, the same `local_path` rules are applied: decrypted files locally will be placed to `\u003cbase_dir\u003e/\u003cremote_path\u003e`. If you specify `local_path`, decrypted files will be stored in `\u003cbase_dir\u003e/\u003clocal_path\u003e`.\n4. Run `rc docs`. It will encrypt `\u003cbase_dir\u003e/\u003cremote_path | local_path\u003e` and upload to `\u003cremote\u003e:\u003cpath\u003e`, specified in rclone config.\n\n## Usage\n\n`rc \u003cremote:path\u003e \u003cdirection\u003e`\n\n* `\u003cremote:path\u003e`: rc-remote and userPath to specify nested sync directory\n* `\u003cdirection\u003e`: `up` or `down`, sync direction. `up` is default and my be omited.\n\n## Configuration\n\nExample config:\n\n```yaml\nbase_dir: /Users/user\nremotes:\n  stuff:\n    remote: yd\n  books:\n    remote: yd\n    path: /library\n    local_path: /calibre\n  docs:\n    remote: crypt_docs\n    remote_path: /\n    local_path: /Documents/docs\n```\n\n`Config` params:\n\n* `base_dir`: absolute path on filesystem, which all other remotes are relative to.\n* `remotes`: a named list of Remotes.\n\n`Remote` params:\n\n* **`remote`, required**: rclone remote to use, should exist in rclone config;\n* `remote_path`, optional: directory to sync on remote storage. Used as local_path, if the last is not provided.\n* `local_path`, optional: directory to sync on local storage. *Overwrites* `remote_path` for building local target path.\n\n## Known bugs and features\n\nThere are several bugs and featured, I'm going to implement in future. Please, feel free to open PR.\n\n* `local_path` cannot contains spaces. For some reasons running `exec.Command()` with spaces in one of args raises incorrect argument parsing, even with quoting / escape. Running the same arguments in bash works properly.\n* rc must failback to rclone remotes with the same argparse logic if requested remote was not found in rc config. Right now this code block is commented.\n\nPlease, note, **`rc` is in alpha.** Though critical functions are partly tested, use it at your own risk.\n\n## License\n\nCopyright (c) 2018 Ilya Rusanen\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\nIMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\nFITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\nAUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\nLIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\nOUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\nSOFTWARE.","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ff1nnix%2Frc","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ff1nnix%2Frc","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ff1nnix%2Frc/lists"}