5 releases

0.1.4 Sep 10, 2023
0.1.3 Sep 10, 2023
0.1.2 Sep 10, 2023
0.1.1 Sep 10, 2023
0.1.0 Sep 10, 2023

#1482 in Development tools

MIT license

8KB
151 lines

cli-gitignore

Description

cli-gitignore is a simple ignore file generator written in Rust.

Author

Chloe

License

MIT

Repository

https://github.com/Chloe199719/cli-gitignore

Version

0.1.4

Usage

The tool provides several command-line options:

  • --help, -h: Show the help message.
  • --version, -v: Show the version.
  • --language, -l: Specify a Programming Language (typescript, javascript, rust ,append). (append is used to not use a language template and append custom commands only)
  • --remove, -r: Remove the current .gitignore file if it exists and generate a new one.
  • --custom, -c: Add custom entries to the .gitignore file. Example: -c .idea .vscode.

If no language is specified, the tool will prompt the user to enter a language. The tool currently supports generating .gitignore files for Typescript, Javascript, and Rust.

Installation

From Source

  1. Clone the repository:
https://github.com/Chloe199719/cli-gitignore
  1. Build the project:
cargo build --release
  1. Run the executable:
./target/release/cli-gitignore

From Crates.io

  1. Install the tool:
cargo install cli-gitignore
  1. Run the executable:
cli-gitignore

Examples

Generate a .gitignore file for Typescript

cli-gitignore -l typescript

Generate a .gitignore file for Rust

cli-gitignore -l rust

Generate a .gitignore file for Rust with custom entries

cli-gitignore -l rust -c .idea .vscode

Generate a .gitignore file in Append mode

cli-gitignore -l append -c .idea .vscode

No runtime deps