https://github.com/zewebdev1337/new-repo-from-template
https://github.com/zewebdev1337/new-repo-from-template
Last synced: about 1 year ago
JSON representation
- Host: GitHub
- URL: https://github.com/zewebdev1337/new-repo-from-template
- Owner: zewebdev1337
- License: mit
- Created: 2023-11-25T00:33:14.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2023-11-25T00:33:16.000Z (over 2 years ago)
- Last Synced: 2025-02-07T11:16:51.794Z (over 1 year ago)
- Language: Shell
- Homepage:
- Size: 3.91 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# New Repo from Template
## Overview
New Repo from Template is a command line utility designed to simplify the process of creating a new GitHub repo from your existing template repositories. This tool leverages the GitHub CLI to get a new repo up and running with one command. Perfect for devs who frequently initialize new projects based on predefined templates.
### NOTE: No git LFS support.
## Features
- **Interactive Mode**: Guided prompts to select a template, define repository details, and set the local repository path.
- **Command-Line Arguments**: Support for creating a repository with parameters for template, name, description, destination, and visibility.
- **Visibility Inheritance**: Option to inherit visibility settings from the template repository.
- **Extended Repository Support**: Ability to create a repository from any GitHub repository, not limited to owned templates or template repositories (via parameters only).
## Install
1. Clone the repository or download the `new-repo-from-template.sh` and `install.sh` scripts to your local machine.
2. Navigate to the directory containing the scripts.
3. :
```bash
sudo ./install.sh
```
## Usage
To create a new repository from a template, you can use the tool in interactive mode or pass parameters directly:
### Interactive Mode
Simply run the command without arguments:
```bash
new-repo-from-template
```
Follow the interactive prompts to select a template repository, define the new repository details, and set the local repository path.
### Command-Line Arguments
To create a repository with parameters:
```bash
new-repo-from-template --template= --name= [--description=] [--destination=] [--visibility=]
```
- `--template`, `-t`: Specify the template repository (mandatory if using options).
- `--name`, `-n`: Specify the name of the new repository (mandatory if using options).
- `--description`, `-d`: Specify the description of the new repository (optional).
- `--destination`, `-D`: Specify the destination directory for the local repository (optional).
- `--visibility`, `-v`: Specify the visibility of the new repository (`public`, `private`, `inherit`) (optional).
### Help
To display the help message:
```bash
new-repo-from-template --help
```
## Uninstall
```bash
sudo ./uninstall.sh
```
## Dependencies
- Git
- GitHub CLI
## Support
For support, questions, or contributions, please open an issue or submit a pull request.
## TODO
- Code cleanup and refactoring.
- Group functionality into functions for better maintainability.
## License
This project is licensed under the MIT License - see the LICENSE file for details.