🚧
This commit is contained in:
parent
876ef2035e
commit
e2084a9dfe
2 changed files with 14 additions and 2 deletions
|
@ -62,6 +62,6 @@ tasks:
|
||||||
example:
|
example:
|
||||||
desc: Setup for example
|
desc: Setup for example
|
||||||
cmds:
|
cmds:
|
||||||
- rm example/vss
|
- rm -rf example/vss
|
||||||
- task: build
|
- task: build
|
||||||
- cp vss example
|
- cp vss example
|
||||||
|
|
12
vss.v
12
vss.v
|
@ -14,6 +14,8 @@ const config_params = ['title', 'description']
|
||||||
|
|
||||||
const default_template = 'layouts/_index.html'
|
const default_template = 'layouts/_index.html'
|
||||||
|
|
||||||
|
const defautl_static = "static"
|
||||||
|
|
||||||
const default_index = 'index.md'
|
const default_index = 'index.md'
|
||||||
|
|
||||||
const default_dist = 'dist'
|
const default_dist = 'dist'
|
||||||
|
@ -23,9 +25,19 @@ fn main() {
|
||||||
name: 'vss'
|
name: 'vss'
|
||||||
version: '0.0.5'
|
version: '0.0.5'
|
||||||
description: 'static site generator'
|
description: 'static site generator'
|
||||||
|
execute: fn (cmd cli.Command) ? {
|
||||||
|
println(cmd.help_message())
|
||||||
|
}
|
||||||
|
commands: [
|
||||||
|
cli.Command{
|
||||||
|
name: 'build'
|
||||||
|
description: 'build your site'
|
||||||
|
usage: 'vss build'
|
||||||
execute: fn (cmd cli.Command) ? {
|
execute: fn (cmd cli.Command) ? {
|
||||||
generate_pages()?
|
generate_pages()?
|
||||||
}
|
}
|
||||||
|
},
|
||||||
|
]
|
||||||
}
|
}
|
||||||
|
|
||||||
app.setup()
|
app.setup()
|
||||||
|
|
Loading…
Add table
Reference in a new issue