Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/tetzng/gh-clone-repo
This GitHub CLI extension is a tool for cloning GitHub repositories in a specified manner.
https://github.com/tetzng/gh-clone-repo
cli gh-extension go
Last synced: 4 days ago
JSON representation
This GitHub CLI extension is a tool for cloning GitHub repositories in a specified manner.
- Host: GitHub
- URL: https://github.com/tetzng/gh-clone-repo
- Owner: tetzng
- License: mit
- Created: 2023-07-19T03:59:41.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2023-07-19T04:22:47.000Z (over 1 year ago)
- Last Synced: 2024-12-25T04:45:54.129Z (9 days ago)
- Topics: cli, gh-extension, go
- Language: Go
- Homepage:
- Size: 6.84 KB
- Stars: 3
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# gh-clone-repo
This GitHub CLI extension is a tool for cloning GitHub repositories in a specified manner.
## Features
- When executing `gh clone-repo [repo]`, a directory named after **the currently logged-in username** is created, and the repository is cloned into it. If the directory already exists, the repository is cloned into that directory.
- When executing `gh clone-repo [owner/repo]`, a directory named after `owner` is created, and the repository is cloned into it. If the directory already exists, the repository is cloned into that directory.
- When executing `gh clone-repo [repo url]`, `owner/repo` is extracted from the URL, a directory named after owner is created, and the repository is cloned into it. If the directory already exists, the repository is cloned into that directory.
- When specifying `-u ` or `--upstream-remote-name ` option, it changes the remote name of the upstream to the specified name.## Installation
1. Install the `gh` CLI - see the [installation](https://github.com/cli/cli#installation)
2. Install this extension:
```sh
gh extension install tetzng/gh-clone-repo
```## Usage
```sh
gh clone-repo [repo | owner/repo | repo url] [-u, --upstream-remote-name ]
```