mirror of
https://github.com/ivabus/pantry
synced 2024-11-22 08:25:07 +03:00
+pixlet
This commit is contained in:
parent
7454e43a88
commit
22c9b8e2a4
1 changed files with 49 additions and 0 deletions
49
projects/tidbyt.com/package.yml
Normal file
49
projects/tidbyt.com/package.yml
Normal file
|
@ -0,0 +1,49 @@
|
||||||
|
distributable:
|
||||||
|
url: https://github.com/tidbyt/pixlet/archive/refs/tags/v{{version}}.tar.gz
|
||||||
|
strip-components: 1
|
||||||
|
|
||||||
|
display-name: pixlet
|
||||||
|
|
||||||
|
versions:
|
||||||
|
github: tidbyt/pixlet
|
||||||
|
|
||||||
|
provides:
|
||||||
|
- bin/pixlet
|
||||||
|
|
||||||
|
dependencies:
|
||||||
|
google.com/webp: ^1
|
||||||
|
|
||||||
|
build:
|
||||||
|
dependencies:
|
||||||
|
go.dev: ^1.21
|
||||||
|
npmjs.com: '*'
|
||||||
|
nodejs.org: '*'
|
||||||
|
script:
|
||||||
|
- npm i
|
||||||
|
- npm run build
|
||||||
|
- go mod download
|
||||||
|
- go build -v -trimpath -ldflags="$LDFLAGS" -o $BUILDLOC .
|
||||||
|
- GOOS=js GOARCH=wasm go build -trimpath -ldflags="-s -w" -o ${BUILDLOC}.wasm tidbyt.dev/pixlet
|
||||||
|
env:
|
||||||
|
BUILDLOC: '{{prefix}}/bin/pixlet'
|
||||||
|
LDFLAGS:
|
||||||
|
- -s
|
||||||
|
- -w
|
||||||
|
- -X=tidbyt.dev/pixlet/cmd.Version={{version}}
|
||||||
|
linux:
|
||||||
|
LDFLAGS:
|
||||||
|
- -buildmode=pie
|
||||||
|
|
||||||
|
test:
|
||||||
|
fixture: |
|
||||||
|
load("render.star", "render")
|
||||||
|
def main():
|
||||||
|
return render.Root(
|
||||||
|
child = render.Text("Hello, World!")
|
||||||
|
)
|
||||||
|
script:
|
||||||
|
- pixlet help
|
||||||
|
- pixlet version
|
||||||
|
- pixlet version | grep {{version}}
|
||||||
|
- cp $FIXTURE hello-world.star
|
||||||
|
- pixlet render hello-world.star
|
Loading…
Reference in a new issue