https://github.com/tnychn/tapgen
🛠️ Tony's Almighty Project Generator
https://github.com/tnychn/tapgen
bootstrap cli generator rust scaffold template
Last synced: 3 months ago
JSON representation
🛠️ Tony's Almighty Project Generator
- Host: GitHub
- URL: https://github.com/tnychn/tapgen
- Owner: tnychn
- License: mit
- Created: 2023-12-30T01:55:16.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2024-03-28T13:42:45.000Z (about 2 years ago)
- Last Synced: 2025-04-11T13:53:13.745Z (about 1 year ago)
- Topics: bootstrap, cli, generator, rust, scaffold, template
- Language: Rust
- Homepage:
- Size: 31.3 KB
- Stars: 2
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE.txt
Awesome Lists containing this project
README
tapgen
Tony's Almighty Project Generator
A general-purpose, language-agnostic, yet simple and fast (i.e. *almighty*)
project generator to bootstrap and scaffold your projects easily.
Wanna start developing your new project real quick?
Run a single command and you can start coding right away.
Productivity++: No more wasting your time copy-and-pasting boilerplate starter code.
## Features
- Just run the binary: No intepreters or environment setup needed.
- Bloat-free command line tool: No more overwhelmed by tons of flags and options, i.e. it just simply works.
- Full power of the [`MiniJinja`](https://github.com/mitsuhiko/minijinja/) template engine.
- fast and lightweight
- familiar syntax of Jinja2
- extensible filters and functions etc.
- Customizable prompts and template variables.
- conditional prompts
- range for integers
- regex pattern validation for strings
- single choice or multiple choices prompts
- Scripts as hooks that are run before and after generation.
- Like [Cookiecutter](https://github.com/cookiecutter/cookiecutter), but *faaaster* (written in Rust).
## Usage
```console
$ tapgen [DST]
```
Currently, `SRC` can be one of the following:
- shorthand for git source[1](#git-source):
- `github:/`
- `gitlab:/`
- `bitbucket:/`
- shorthand for prefix source[2](#prefix-source): `@:`
- path to local `tapgen.toml` file or directory that contains a `tapgen.toml` file
1: You can specify additional path in case when
the repository contains multiple templates, or when the template is several levels deep inside the repository,
e.g. `github:tnychn/templates/subdir1/subdir2`.
2: Relative to the prefix path, e.g. if the prefix path is `/Users/tony/.tapgen`,
then `@:foo/bar` becomes `/Users/tony/.tapgen/foo/bar`.
## TODO
- [ ] Override variable values in CLI.
- [ ] Replay previous generation.
- [ ] Support templated defaults.
- [ ] Extend template filters/functions/tests via scripting.
---
~ crafted with ♥︎ by tnychn ~
MIT © 2024 Tony Chan