A tool to clone and set up git repositories
npm install @coderjamie/coldstartColdstart is a command-line tool that simplifies the process of cloning and setting up Git repositories. It automates the process of cloning a repository, with options to remove Git-related files, initialize a new Git repository, and install dependencies.
- Clone any Git repository
- Remove Git-related files and directories (.git, .gitmodules) while preserving .gitignore
- Optionally keep all Git-related files
- Optionally initialize a new Git repository
- Optionally install npm dependencies if package.json is present
- Flexible directory naming
- Node.js (version 12 or higher)
- npm (usually comes with Node.js)
- Git
To install Coldstart globally, run:
``bash`
npm install -g @coderjamie/coldstart
If you prefer to install it locally in your project:
`bash`
npm install @coderjamie/coldstart
`bash`
coldstart
- : The URL of the Git repository you want to clone (required)[target-directory]
- : The directory where you want to clone the repository (optional)
If no target directory is specified, Coldstart will use the repository name as the directory name.
- --keep-git-files: Keep the original Git-related files (.git, .gitignore, .gitmodules)--init-git
- : Initialize a new Git repository after cloning--install-deps
- : Automatically install npm dependencies if a package.json file is present
1. Clone a repository into a new directory:
`bash`
coldstart https://github.com/username/repo.git my-new-project
2. Clone a repository, initialize a new repo, and install dependencies:
`bash`
coldstart https://github.com/username/repo.git --init-git --install-deps
3. Clone a repository and only initialize a new Git repo:
`bash`
coldstart https://github.com/username/repo.git --init-git
1. Clones the specified Git repository
2. Removes Git-related files (unless --keep-git-files is used)--init-git
3. Optionally initializes a new Git repository (if is used)package.json
4. Optionally installs npm dependencies if a file is present (if --install-deps` is used)
Contributions are welcome! Please feel free to submit a Pull Request.
If you encounter any problems or have suggestions for improvements, please open an issue on the GitHub repository.