Skip to main content

Sync all your local projects to GitHub automatically

Project description

GitHub Sync Agent

Automatically syncs every local project directory to its own GitHub repository.

For each project it will:

  1. git init if not already a repo
  2. Create the GitHub repo if it doesn't exist yet
  3. Ensure the remote uses SSH
  4. Stage + commit any uncommitted changes
  5. Push to origin

Runs daily via a systemd user timer, and on-demand via CLI.


Installation

pip install github-sync-agent

First-time setup

github-sync init

The wizard will:

  • Check git and gh are installed
  • Authenticate with GitHub (gh auth login)
  • Ask which folder to scan for projects
  • Set up your SSH key automatically
  • Write a config file to ~/.config/github-sync/config.yaml

Usage

# Sync all projects
github-sync sync

# Sync a single project
github-sync sync --project my-project

# Preview without making changes
github-sync sync --dry-run

# Show status of all projects
github-sync status

Configuration (~/.config/github-sync/config.yaml)

Generated by github-sync init. You can edit it at any time.

Key Default Description
github_user (detected from gh auth) Your GitHub username
projects_root ~/projects Scans all subdirectories here
schedule_time 02:00 Daily run time
default_visibility private private or public for new repos
auto_commit_message chore: auto-sync Commit message for auto-commits
exclude [] Directory names to skip
log_file ~/.local/share/github-sync/github-sync.log Log file path
log_level INFO DEBUG / INFO / WARNING / ERROR

Excluding a project

exclude:
  - SomeProjectToSkip

Requirements


License

MIT

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

github_sync_agent-0.1.3.tar.gz (9.3 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

github_sync_agent-0.1.3-py3-none-any.whl (9.9 kB view details)

Uploaded Python 3

File details

Details for the file github_sync_agent-0.1.3.tar.gz.

File metadata

  • Download URL: github_sync_agent-0.1.3.tar.gz
  • Upload date:
  • Size: 9.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.10.12

File hashes

Hashes for github_sync_agent-0.1.3.tar.gz
Algorithm Hash digest
SHA256 4004ba46a82e0e573053de13510f61f3a016193afd8e42cfa0ec8e8513fd76dc
MD5 ab9f0fd1ada21184aefe583a77ce7d62
BLAKE2b-256 a051c4de62df89db6e5cac2a1a72d6e7e2a6c04febf4e7b836580476c1003c91

See more details on using hashes here.

File details

Details for the file github_sync_agent-0.1.3-py3-none-any.whl.

File metadata

File hashes

Hashes for github_sync_agent-0.1.3-py3-none-any.whl
Algorithm Hash digest
SHA256 e0e92c2cbd0e61eee12fd1d16b7698fa7aeb629b578ae9ded7b5ed7b485282ef
MD5 39596b53eb223d90e19ac58258a7b197
BLAKE2b-256 0d6d9bc2ebbd63981272612057f5e6da06437876d74950f6f68f299fb783343d

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page