Skip to content
/ IDEv2 Public

πŸ‘½οΈ My CLI to fastly initalize new projects ! πŸ“¦οΈ

Notifications You must be signed in to change notification settings

Piarre/IDEv2

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

26 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

πŸš€ IDE v2

πŸ‘½οΈ A CLI tool to quickly initialize new projects with custom templates! πŸ“¦οΈ

NPM License: MIT

✨ Features

  • 🧩 Create projects from custom templates
  • πŸ” Define project structure with simple YAML files
  • πŸ”§ Execute commands as part of the setup process
  • 🧰 Modify JSON files automatically
  • πŸ”„ Support for variables within templates
  • βš™οΈ Multiple version formats (v1 and v2)

πŸ“₯ Installation

bun install -g @piarre/idev2

🏁 Quick Start

1. Create a template directory

Templates are stored in ~/.ide/ folder. Create this folder if it doesn't exist yet:

mkdir -p ~/.ide

2. Create a template file

Create a YAML file in the ~/.ide/ directory with your template definition:

# ~/.ide/ts.yml
name: ts
description: Create a TypeScript project

commands:
  - "npm init -y"
  - "npm i -D typescript @types/node tsup ts-node"

options:
  - name: "name"
    command: "-n, --name <n>"
    description: "Project name"
  - name: "git"
    command: "-g, --git"
    description: "Initialize git repository"
    execute:
      - "git init"

files:
  - path: src/index.ts
    content: |
      console.log("Hello, {{ name }}!");
  - path: tsconfig.json
    content: |
      {
        "compilerOptions": {
          "module": "CommonJS",
          "target": "ESNext",
          "outDir": "./out",
          "skipLibCheck": true
        },
        "include": ["src/**/*"],
        "exclude": ["node_modules"]
      }

3. Use your template

# Create a new project in a new directory
ide ts -n my-project

# Create a project in the current directory
cd my-empty-project
ide ts

πŸ”„ Template Variables

You can use variables in your templates using the {{ variable }} syntax. These variables correspond to the options defined in your template.

options:
  - name: "username"
    command: "-u, --username <username>"
    description: "Your username"

files:
  - path: README.md
    content: |
      # Project by {{ username }}

When running the command with -u john, the template will replace {{ username }} with john.

πŸ“š Documentation

For more detailed documentation, visit ide.piarre.app.

πŸ“œ License

This project is MIT licensed.

πŸ‘¨β€πŸ’» Author

Piarre - GitHub

About

πŸ‘½οΈ My CLI to fastly initalize new projects ! πŸ“¦οΈ

Resources

Stars

Watchers

Forks