Skip to content

boiler 0.5.0

Latest

Choose a tag to compare

@github-actions github-actions released this 12 Jul 17:35
Immutable release. Only release title and notes can be modified.
2083c60

🚀 bl Engine - Scripting, Local Scopes & Silent Scaffolding

Boiler v0.5.0 is the biggest release yet. Boiler is no longer just a snippet/stack manager - it's a full code automation engine. Write .bl scripts once, run them anywhere.


✨ What's New

🧠 bl Scripting Engine (bl new <script>)

Write automation scripts in .bl files and run them with bl new:

__desc = "Scaffolds a new React Component"
__author = 'Abhinav Prakash'
__version = 1.0.0
__var bl__name = bl__1.capitalize()
__var bl__content = bl__2.kebabCase()

create ./src/components/bl__name.jsx `
const bl__name = () => {
    return (
        <div>
           bl__content
        </div>
    )
}

export default bl__name
`

inject ./src/App.jsx -d imports -a -c `
 import bl__name from './components/bl__name'
`

inject ./src/App.jsx -d components -a -c ` <bl__name/> `

#if bl__lint
 run pnpm run lint
#endif

**You can use the above script directly using bl **

bl use rishiyaduwanshi/boiler-snippets:bl/cmp.bl bl/commands     

How to run the above script:

bl new cmp button "this-is-the-2nd-argument" --lint

--lint is passed as a flag — when present, pnpm run lint runs after scaffolding.

  • Variable system - positional args (bl__1, bl__2) and named flags (--name=MyApp)
  • Variable modifiers - .capitalize(), .camelCase(), .snake_case(), .kebabCase(), .pascalCase(), .upper(), .lower(), .title()
  • Conditionals - #if, #else, #endif with &&, ||, !, ==, !=
  • create - generate files with inline content (backtick blocks)
  • inject - insert code between detector markers in existing files (-d, -a, -p, -c flags)
  • run - execute OS commands directly (npm, git, go, etc.) - no shell, no injection risk
  • Native Boiler commands - call add, use, store, alias from within scripts

🔒 Local Project Store (--local)

Project-specific templates that live inside your repo:

myproject/
├── bl/
│   ├── commands/        ← .bl scripts live here
│   │   └── component.bl
│   └── store/
│       └── snippets/    ← local snippets
└── boiler.local.json
  • bl new component MyButton --local - runs script relative to project root
  • boiler.local.json auto-discovery - finds nearest config walking up the tree
  • Clear separation: global ~/.boiler vs local bl/

⚡ Silent Scaffolding Pipeline (BOILER_VAR_*)

Pre-fill variables via environment - skip all prompts, fully automate:

BOILER_VAR_bl__name=AuthService \
BOILER_VAR_bl__type=service \
bl new scaffold
  • Works with create, inject, run, and all native Boiler commands
  • Variables propagate to child bl processes automatically
  • Enables Hygen-style CI/CD scaffolding pipelines

🐛 Bug Fixes

  • bl use now fully processes templates (variables, prompts, metadata stripping)
  • Remote registry path resolution fixed - no more snippet does not have a valid remote location
  • Config JSON parse errors now surface immediately instead of silently falling back to global scope
  • Command injection prevention - run commands execute directly without any shell interpreter
  • Per-token interpolation - variable values with spaces are treated as atomic arguments

🔐 Security

  • Removed all sh -c / cmd /c shell wrappers from run command execution
  • run and native commands now tokenize the template before variable substitution
  • --local scope now hard-errors if working directory cannot be resolved (prevents silent global store access)

📚 Documentation

  • Website overhaul - homepage, introduction, quickstart, use cases
  • New bl Scripts guide with full syntax reference
  • New Best Practices guide
  • New Project Structure guide (global vs local)
  • Fixed markdown tables (HTML fallback for Astro/GFM)

Full Changelog: v0.4.0...v0.5.0

Installation

Windows

iwr -useb https://boiler.iamabhinav.dev/install | iex

Linux/macOS

curl -fsSL https://boiler.iamabhinav.dev/install | bash

Manual Download

Download the appropriate binary for your platform below.

Changelog

  • 6fcb060 ci: fix goreleaser changelog filters to correctly exclude scoped commits and PR merges
  • 70e4ba8 feat(add): auto-skip variable prompts if pre-filled via config or env
  • 7a5b70b feat(add): enable template processing for no-store remote fetches
  • 5f6ad83 feat(cli): add 'bl new' command for script execution
  • 35f324c feat(cli): add --name flag for rename on add/use
  • f6e8185 feat(cli): implement positional arguments (bl__N) for powerful and safe command aliases
  • 013dceb feat(cli): introduce inline variable interpolation using unified bl__ prefix
  • 1f6bd47 feat(config): redesign local project configuration
  • 3bdbb49 feat(engine): add bl script parser and executor stub
  • 59c1c34 feat(engine): add code injector with CLI flag syntax
  • d406b16 feat(engine): add variable modifiers and AST-less logic evaluator
  • 1e3b5a8 feat(engine): add variable modifiers evaluator
  • c32ac3d feat(engine): propagate script variables to child commands via env
  • 33ff9b9 feat(engine): wire up OS and Boiler commands dynamically
  • b76e31b feat(store): add snippets for node, go, docker, and gitignore to registry
  • 42c9049 feat(utils): add generic string formatting functions
  • 5c20db6 feat: add engine create command and unify boiler dir to bl
  • 8f4e48e feat: centralize all magic strings, URLs, and API endpoints to constants package
  • 6156615 feat: implement local vs global config architecture with Manager pattern
  • 4df75b6 feat: native project-local store and dynamic path resolution
  • 5acf096 fix(cli): correct command variable syntax and alias examples in docs strings
  • ba3cd0d fix(cli): point new command to bl/commands/ dir and update docs
  • 3488eca fix(cli): resolve snippet auto-detect edge case for stacks and add -k/-n flags to use cmd
  • d5601fa fix(config): bubble up json parsing errors instead of silent ignore
  • df2d344 fix(engine): eliminate Windows shell injection by removing cmd /c wrapper
  • 2083c60 fix(engine): per-token interpolation for native commands; seed BOILER_VAR_* into script vars
  • fe6c9e2 fix(engine): prevent command injection and support single-quote parsing in run command
  • ee89663 fix(engine): prevent flag injection via per-token interpolation in run commands
  • ef3c7ac fix(new): handle os.Chdir errors to prevent script running from wrong directory
  • 922e2cf fix(root): local scope now falls back to cwd/bl/ instead of global store
  • d757c76 fix(root): return error when Getwd fails in local scope to prevent global store access
  • b0391e8 fix(store): bypass local file existence checks for remote paths
  • c48f2c6 fix(utils): replace deprecated strings.Title with unicode-safe manual implementation
  • 11d6a03 fix: load registry from config when flag is omitted
  • b187906 fix: separate global and local boiler directory names
  • 96f463b fix: skip --local and --global these are root persisted flag
  • d8c3c28 refactor(cli): unify local and remote resource resolution logic to adhere to DRY principles