Fix --version output

pull/15/head
Mickaël Menu 3 years ago
parent b82f1f547c
commit be8b2d6289
No known key found for this signature in database
GPG Key ID: 53D73664CD359895

2
.gitignore vendored

@ -14,3 +14,5 @@
# Dependency directories (remove the comment below to include it)
# vendor/
# Documentation notebook marker
docs/.zk

@ -18,6 +18,10 @@
* [Made with automation in mind](docs/automation.md)
* [Notebook housekeeping](docs/notebook-housekeeping.md)
* [Future-proof, thanks to Markdown](docs/future-proof.md)
* Supports most Markdown syntax flavors
* Links: regular Markdown links, `[[Wikilinks]]` and Neuron's `[[Folgezettel links]]#`.
* Tags: `#hashtags`, `:colon:separated:tags:`, Bear's `#multi-word tags#`.
* [YAML frontmatter](docs/note-frontmatter.md)
[See the changelog](CHANGELOG.md) for the list of upcoming features waiting to be released.

@ -1,11 +0,0 @@
[note]
filename = "{{slug title}}"
template = "default.md"
[tool]
editor = "vim"
[alias]
neuron = 'neuron gen $@'
wc = "zk list --format '{{word-count}}\t{{title}}' --sort word-count -x log $@"

@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:41e8b104003fba2e5076276d9b4929912391bbd163edd97d6598f654039c82e8
size 331776

@ -1,3 +0,0 @@
# {{title}}
{{content}}

2
go

@ -1,6 +1,6 @@
#!/bin/bash
VERSION=`git describe --tags 2> /dev/null`
VERSION=`git describe --tags --match v[0-9]* 2> /dev/null`
BUILD=`git rev-parse --short HEAD`
CGO_ENABLED=1 go $1 -tags "fts5 icu" -ldflags "-X=main.Version=$VERSION -X=main.Build=$BUILD" ${@:2}

@ -78,7 +78,7 @@ func options(container *cmd.Container) []kong.Option {
FlagsLast: true,
},
kong.Vars{
"version": Version,
"version": "zk " + strings.TrimPrefix(Version, "v"),
},
kong.Groups(map[string]string{
"filter": "Filtering",

Loading…
Cancel
Save