Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/guidesmiths/gs-hygen
Remote hygen templates generator
https://github.com/guidesmiths/gs-hygen
generator hygen npm-package template yeoman
Last synced: 22 days ago
JSON representation
Remote hygen templates generator
- Host: GitHub
- URL: https://github.com/guidesmiths/gs-hygen
- Owner: guidesmiths
- License: mit
- Created: 2021-03-05T11:49:05.000Z (almost 4 years ago)
- Default Branch: master
- Last Pushed: 2021-12-17T16:11:05.000Z (about 3 years ago)
- Last Synced: 2024-12-18T09:45:21.594Z (29 days ago)
- Topics: generator, hygen, npm-package, template, yeoman
- Language: TypeScript
- Homepage:
- Size: 767 KB
- Stars: 1
- Watchers: 9
- Forks: 1
- Open Issues: 4
-
Metadata Files:
- Readme: README.md
- License: LICENSE
- Code of conduct: CODE_OF_CONDUCT.md
Awesome Lists containing this project
README
# gs-hygen
## Installation
This is a [Node.js](https://nodejs.org/en/) module available through the
[npm registry](https://www.npmjs.com/).Before installing, [download and install Node.js](https://nodejs.org/en/download/).
Node.js v14 or higher is required.Installation is done using the
[`npm install`](https://docs.npmjs.com/getting-started/installing-npm-packages-locally) command:```bash
$ npm install -g gs-hygen
```## Install from git repository
```bash
git clone https://github.com/guidesmiths/gs-hygen
npm install --quiet
npm pack
npm i -g gs-hygen-*.tgz
gs-hygen --help
```## Usage examples
```bash
gs-hygen \
template \
--url [email protected]:guidesmiths/infinitas-hygen-template-generators.git \
--generator service-systemic-basics,nvm,commitlint,jest-systemic,jest-systemic-mock-bus \
--output /tmp/generator-demo-repo \
git \
--private-key ~/.ssh/id_rsa \
--public-key ~/.ssh/id_rsa.pub
```## CLI options
### Getting help
```
gs-hygen --help
```
```
gs-hygen [command]Commands:
gs-hygen template Template command
gs-hygen git Git commandOptions:
--version Show version number [boolean]
--url the template git repository url [string] [default: ""]
--generator the template generators, example: "docker,git,eslint"
[string]
--output the template generator output files [string] [required]
--username git username [string] [default: "git"]
--credentials git username credentials [string] [default: ""]
--public-key git user public key [string] [default: ""]
--private-key git user provate key [string] [default: ""]
-h, --help Show help [boolean]
```### Optional parameters
You can also choose the generators manually avoiding to provide the `--generator` argument, the output will look like this:
![image](https://user-images.githubusercontent.com/16175933/145254497-bf6f27f6-62d9-4079-bb7e-a9865f356d11.png)
## Creating templates
This project only supports templates for hygen.
So what we need is to generate a new project with the hygen templates section already generated.```bash
mkdir new-templates
cd new-templates
git init -b main
mkdir generator _shared
# Visit the hygen docs for generating some basic hygen generator
# http://www.hygen.io/docs/quick-start
git add .
git commit -m "New template generators"
git remote add origin
git push origin main
```This templates project repo is a good starting point