switchbox
=========
A collection of small tools for git workflows.
![A screenshot displaying the output of 'switchbox finish'.](./docs/screenshot.png)
Installation
------------
Clone the repository and install the package with `pip`.
```zsh
pip install --user .
```
Usage
-----
Invoke `switchbox` directly or run it via `git switchbox`.
Switchbox commands assume your git repository has a default branch and a
default remote. When Switchbox is used for the first time (or you run
`switchbox setup`) it will find and remember names for these.
* The default branch will use a branch named `main` or `master`.
* The default remote will use a remote named `upstream` or `origin`.
Switchbox options are set in a repository's `.git/config` file under a
`switchbox` section.
### `switchbox config`
Show config options that Switchbox has set.
### `switchbox config init`
Detect a default branch and default remote, and save them to the repository's
git configuration. This will be done automatically when you first use a command
that works on a default branch or default remote.
### `switchbox config default-branch $branch`
Change the default branch.
### `switchbox config default-remote $remote`
Change the default remote.
### `switchbox finish [--update/--no-update]`
* Update all git remotes.
* Update the local default branch to match the remote default branch.
* Switch to the default branch.
* Remove branches **merged** into the default branch.
* Remove branches **squashed** into the default branch.
### `switchbox tidy [--update/--no-update]`
* Update all git remotes.
* Remove branches **merged** into the default branch.
* Remove branches **squashed** into the default branch.
### `switchbox update`
* Update all git remotes.
Raw data
{
"_id": null,
"home_page": "https://pypi.org/project/switchbox/",
"name": "switchbox",
"maintainer": null,
"docs_url": null,
"requires_python": "<4.0,>=3.10",
"maintainer_email": null,
"keywords": null,
"author": "Sam Clements",
"author_email": "sam@borntyping.co.uk",
"download_url": "https://files.pythonhosted.org/packages/34/83/acebc5662af26d5ce3ed0bfef7bde4b4d74825bab361b7858eec42287a42/switchbox-0.5.0.tar.gz",
"platform": null,
"description": "switchbox\n=========\n\nA collection of small tools for git workflows.\n\n![A screenshot displaying the output of 'switchbox finish'.](./docs/screenshot.png)\n\nInstallation\n------------\n\nClone the repository and install the package with `pip`.\n\n```zsh\npip install --user .\n```\n\nUsage\n-----\n\nInvoke `switchbox` directly or run it via `git switchbox`.\n\nSwitchbox commands assume your git repository has a default branch and a\ndefault remote. When Switchbox is used for the first time (or you run\n`switchbox setup`) it will find and remember names for these.\n\n* The default branch will use a branch named `main` or `master`.\n* The default remote will use a remote named `upstream` or `origin`.\n\nSwitchbox options are set in a repository's `.git/config` file under a\n`switchbox` section.\n\n### `switchbox config`\n\nShow config options that Switchbox has set.\n\n### `switchbox config init`\n\nDetect a default branch and default remote, and save them to the repository's\ngit configuration. This will be done automatically when you first use a command\nthat works on a default branch or default remote.\n\n### `switchbox config default-branch $branch`\n\nChange the default branch.\n\n### `switchbox config default-remote $remote`\n\nChange the default remote.\n\n### `switchbox finish [--update/--no-update]`\n\n* Update all git remotes.\n* Update the local default branch to match the remote default branch.\n* Switch to the default branch.\n* Remove branches **merged** into the default branch.\n* Remove branches **squashed** into the default branch.\n\n### `switchbox tidy [--update/--no-update]`\n\n* Update all git remotes.\n* Remove branches **merged** into the default branch.\n* Remove branches **squashed** into the default branch.\n\n### `switchbox update`\n\n* Update all git remotes.\n",
"bugtrack_url": null,
"license": "MPL-2.0",
"summary": "Tools for working with Git repositories.",
"version": "0.5.0",
"project_urls": {
"Homepage": "https://pypi.org/project/switchbox/",
"Repository": "https://github.com/borntyping/switchbox"
},
"split_keywords": [],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "88980593092d8f4ecbdae24fd3e52090670126222b83f570a76fa977bea6585d",
"md5": "01dc677d03907e9b25cfce53aecd7ec6",
"sha256": "1283e153a733ef2870a2250f51fbf60673220d46b001a54bb2a92fc41bef2199"
},
"downloads": -1,
"filename": "switchbox-0.5.0-py3-none-any.whl",
"has_sig": false,
"md5_digest": "01dc677d03907e9b25cfce53aecd7ec6",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": "<4.0,>=3.10",
"size": 10633,
"upload_time": "2024-05-16T15:44:28",
"upload_time_iso_8601": "2024-05-16T15:44:28.194182Z",
"url": "https://files.pythonhosted.org/packages/88/98/0593092d8f4ecbdae24fd3e52090670126222b83f570a76fa977bea6585d/switchbox-0.5.0-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "3483acebc5662af26d5ce3ed0bfef7bde4b4d74825bab361b7858eec42287a42",
"md5": "f8c8fbfa0afcab92e6c5fe7e75c26d34",
"sha256": "a7bc2efd8faf9554d02bcd66f12a9a644d2f7726a57c215b5aea183a400ea795"
},
"downloads": -1,
"filename": "switchbox-0.5.0.tar.gz",
"has_sig": false,
"md5_digest": "f8c8fbfa0afcab92e6c5fe7e75c26d34",
"packagetype": "sdist",
"python_version": "source",
"requires_python": "<4.0,>=3.10",
"size": 9099,
"upload_time": "2024-05-16T15:44:31",
"upload_time_iso_8601": "2024-05-16T15:44:31.104633Z",
"url": "https://files.pythonhosted.org/packages/34/83/acebc5662af26d5ce3ed0bfef7bde4b4d74825bab361b7858eec42287a42/switchbox-0.5.0.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2024-05-16 15:44:31",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "borntyping",
"github_project": "switchbox",
"travis_ci": false,
"coveralls": false,
"github_actions": false,
"lcname": "switchbox"
}