mklni: Add lno-tool installation

This commit is contained in:
timoxa0 2024-11-02 23:11:07 +05:00
parent 7cb92f54a4
commit 23bd454bd4

10
mklni
View file

@ -236,6 +236,16 @@ install_chroot()
exit 1
}
log "Installing lon-tool"
{
chroot "$CHROOTDIR" git clone --quiet https://git.timoxa0.su/timoxa0/lon-tool.git /lon-tool-src &&
chroot "$CHROOTDIR" /bin/bash -c 'cd /lon-tool-src && rev=$(git describe --abbrev=4 --dirty --always --tags) && go get git.timoxa0.su/timoxa0/lon-tool/cmd && go build -ldflags "-X git.timoxa0.su/timoxa0/lon-tool/cmd.version=$rev" -o /bin/lon-tool main.go'
} || {
log "Failed to install lon-tool" error
exit 1
}
detach_chroot || {
log "Failed to detach chroot" error
exit 1