https://github.com/9999years/git-upstream
Quickly push a branch and set its remote-tracking information
https://github.com/9999years/git-upstream
git
Last synced: 12 months ago
JSON representation
Quickly push a branch and set its remote-tracking information
- Host: GitHub
- URL: https://github.com/9999years/git-upstream
- Owner: 9999years
- Created: 2024-03-28T18:14:41.000Z (about 2 years ago)
- Default Branch: main
- Last Pushed: 2025-05-06T22:06:42.000Z (about 1 year ago)
- Last Synced: 2025-05-06T22:36:09.839Z (about 1 year ago)
- Topics: git
- Language: Rust
- Homepage:
- Size: 44.9 KB
- Stars: 4
- Watchers: 2
- Forks: 1
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# git-upstream
[](https://crates.io/crates/git-upstream)
A shortcut for `git push --set-upstream "$(git remote)" "$(git rev-parse --abbrev-ref HEAD)"`.
Usage: `git-upstream [--fail-fast] [--branch BRANCH] [--remote REMOTE]`.
Unless `--fail-fast` is given, all remotes are tried until one succeeds.
## Installation
Statically linked binaries are uploaded to GitHub for each release.
With Nix, you can `nix run github:9999years/git-upstream -- ...`.
You can also `cargo install git-upstream`.
## Configuration
You can set `~/.config/git-upstream/config.toml` to configure `git-upstream`:
```toml
# Remote names to attempt to push to, highest preference first.
remotes = [
# "my-employer",
# "my-github-username",
# "fork",
"origin",
]
```