install: let $DOTOOL_VERSION set --version
This commit is contained in:
parent
589d8d63a0
commit
41be5e5e4f
1 changed files with 2 additions and 2 deletions
|
@ -1,7 +1,7 @@
|
||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
# ./install.sh [DESTDIR] [BINDIR]
|
# ./install.sh [DESTDIR] [BINDIR]
|
||||||
version="$(git describe --long --abbrev=12 --tags --dirty 2>/dev/null || echo 1.0)"
|
: "${DOTOOL_VERSION=$(git describe --long --abbrev=12 --tags --dirty 2>/dev/null || echo 1.0)}"
|
||||||
go build -ldflags "-X main.Version=$version" || exit
|
go build -ldflags "-X main.Version=$DOTOOL_VERSION" || exit
|
||||||
mkdir -p "$1/${2:-usr/local/bin}" || exit
|
mkdir -p "$1/${2:-usr/local/bin}" || exit
|
||||||
cp -v dotool dotoolc dotoold "$1/${2:-usr/local/bin}" || exit
|
cp -v dotool dotoolc dotoold "$1/${2:-usr/local/bin}" || exit
|
||||||
mkdir -p "$1/etc/udev/rules.d" || exit
|
mkdir -p "$1/etc/udev/rules.d" || exit
|
||||||
|
|
Loading…
Reference in a new issue