mirror of
https://github.com/ivabus/pantry
synced 2024-11-10 02:25:18 +03:00
new file: projects/pkl-lang.org/class.pkl
new file: projects/pkl-lang.org/package.yml new file: projects/pkl-lang.org/template.pkl
This commit is contained in:
parent
c3317b8754
commit
26fd46b2d1
7
projects/pkl-lang.org/class.pkl
Normal file
7
projects/pkl-lang.org/class.pkl
Normal file
|
@ -0,0 +1,7 @@
|
||||||
|
class Language {
|
||||||
|
name: String
|
||||||
|
}
|
||||||
|
|
||||||
|
bestForConfig: Language = new {
|
||||||
|
name = "Pkl"
|
||||||
|
}
|
31
projects/pkl-lang.org/package.yml
Normal file
31
projects/pkl-lang.org/package.yml
Normal file
|
@ -0,0 +1,31 @@
|
||||||
|
distributable: ~
|
||||||
|
|
||||||
|
warnings:
|
||||||
|
- vendored
|
||||||
|
|
||||||
|
versions:
|
||||||
|
github: apple/pkl
|
||||||
|
|
||||||
|
build:
|
||||||
|
dependencies:
|
||||||
|
curl.se: '*'
|
||||||
|
script:
|
||||||
|
- curl -L "https://github.com/apple/pkl/releases/download/{{version}}/pkl-${SYS_NAME}-${ARCH_NAME}" -o "pkl"
|
||||||
|
- install -D pkl {{prefix}}/bin/pkl
|
||||||
|
env:
|
||||||
|
darwin:
|
||||||
|
SYS_NAME: macos
|
||||||
|
linux:
|
||||||
|
SYS_NAME: linux
|
||||||
|
x86-64:
|
||||||
|
ARCH_NAME: amd64
|
||||||
|
aarch64:
|
||||||
|
ARCH_NAME: aarch64
|
||||||
|
|
||||||
|
provides:
|
||||||
|
- bin/pkl
|
||||||
|
|
||||||
|
test:
|
||||||
|
- pkl --version | grep {{version}}
|
||||||
|
- pkl eval template.pkl | grep 'Writing a Template'
|
||||||
|
- pkl eval class.pkl | grep 'bestForConfig'
|
11
projects/pkl-lang.org/template.pkl
Normal file
11
projects/pkl-lang.org/template.pkl
Normal file
|
@ -0,0 +1,11 @@
|
||||||
|
name: String = "Writing a Template"
|
||||||
|
|
||||||
|
part: Int = 3
|
||||||
|
|
||||||
|
hasExercises: Boolean = true
|
||||||
|
|
||||||
|
amountLearned: Float = 13.37
|
||||||
|
|
||||||
|
duration: Duration = 30.min
|
||||||
|
|
||||||
|
bandwidthRequirementPerSecond: DataSize = 50.mb
|
Loading…
Reference in a new issue