README.md

June 6, 2024 ยท View on GitHub

git-sync

License People Stars Forks Watches Last Updated

Hassle Free Git Syncing ๐Ÿ™๐Ÿ”„

git-sync is a simple tool that silently syncs all your git repos.

If you have a bunch of git repos to maintain and switch devices often, a lot of time is wasted on syncing those repos.

This is as simple as running git-sync

โœจ Features

  • Sync all your git repos silently
  • Plain text based configuration

Setup

โšก Requirements

You will need a config file with repo paths: "$HOME/.config/git-sync"

$HOME/Projects/repo1
$HOME/Projects/GitHub/repo2

๐Ÿš€ Installation

git clone https://github.com/2kabhishek/git-sync
cd git-sync
# symlink to a directory in your PATH
ln -sfnv $PWD/git-sync.sh $HOME/.local/bin/git-sync

git-sync config # Edit the config file located at $HOME/.config/git-sync.conf
# or
git sync config

๐Ÿ’ป Usage

USAGE:
    git-sync or git sync [c | config | -c | --config]
Example:
    git-sync # Sync repos in config file
    git-sync c # Edit the config file

Behind The Code

๐ŸŒˆ Inspiration

Maintaining all of the repos I have was becoming a major hassle, faced some issues too, needed a tool to do this quietly.

๐Ÿ’ก Challenges/Learnings

  • I learned about using IFS for reading data for files
  • Used case for command line flags in bash

๐Ÿงฐ Tooling

๐Ÿ” More Info

  • entry โ€” Make daily entries
  • committer โ€” Easy commits and backups

โญ hit the star button if you found this useful โญ

Source | Blog | Twitter | LinkedIn | More Links | Other Projects