Skip to content

petal-framework/petal-cli

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

petal cli

the command line tool for the petal framework.

building

you need haxe and hashlink installed.

haxe build.hxml

this produces petal.hl which runs with:

hl petal.hl

to produce a standalone native binary, compile to hlc instead:

haxe build-native.hxml

then compile the output c code with your platform's c compiler. the petal ci handles this for distribution builds.

usage

petal new my-app
petal run web
petal build web --release
petal add petal/camera
petal update
petal lint
petal lsp

target naming

target description
web html + css + js bundle
desktop-linux linux via webview
desktop-linux-native linux via skia renderer
desktop-windows windows via webview
desktop-windows-native windows via skia renderer
desktop-macos macos via webview
desktop-macos-native macos via skia renderer
android android via webview
android-native android via skia renderer
ios ios via webview
ios-native ios via skia renderer

project structure

my-app/
  src/
    pages/       <- .petal files here are treated as pages (like sveltekit routes)
    components/  <- .petal files here are components
  petal.json     <- project config, deps, targets

petal.json

{
  "name": "my-app",
  "version": "0.1.0",
  "petal": "0.1.0",
  "targets": ["web", "desktop-linux"],
  "dependencies": {
    "petal/camera": "^1.0.0"
  }
}

About

CLI for the Petal Framework

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages