Description | Features | Installation | Usage | Configuration | References
vin
is the CLI to install applications from GitHub Releases.
In recent years, many useful CLI tools have been made by Go, Rust, etc.
Many of them are available as pre-built binaries in GitHub Releases, but we have to manipulate the browser to download them, decompress the compressed files, and move the executables to the appropriate path.
vin
makes it easy to manage all at once by writing a list of applications in a TOML file.
No longer do we have to select suitable assets for our machines from GitHub Releases, no longer do we have to look up the options for the tar
command, and no longer do we have to be pained when we setup a new machine.
- Easy to use
- TOML-based configuration
Download the binary from GitHub Releases.
Unfortunately, the first time you install vin
, you need to open the browser.
Or, if you have Go, you can install vin
with the following command.
go get github.com/skmatz/vin/...
After installation, add ~/.vin/bin
to your $PATH
.
export PATH="$HOME/.vin/bin:$PATH"
First, put the following TOML file in ~/.config/vin/vin.toml
.
[[app]]
repo = "cli/cli"
You can set this with the following command.
# darwin
mkdir -p ~/Library/Application\ Support/vin
vin example > ~/Library/Application\ Support/vin/vin.toml
# linux
mkdir -p ~/.config/vin
vin example > ~/.config/vin/vin.toml
# windows (confirmed on Windows Terminal)
mkdir -p ~\AppData\Roaming\vin\vin.toml
vin example > ~\AppData\Roaming\vin\vin.toml
Yes, all you have to do is run the following command.
vin get
[[app]]
# repo is the GitHub repository name in "owner/repo" format.
repo = "cli/cli"
# tag is the tag on GitHub.
# If empty, it is treated as "latest".
tag = "v1.2.0"
# keywords is a list of keywords for selecting suitable assets from multiple assets.
# If empty, it is treated as [$GOOS, $GOARCH].
keywords = ["amd64", "linux"]
# name is the name of the executable file.
# If empty, it is treated as the original name.
name = "gh"
# hosts is a list of host names.
# If empty, it is treated as any hosts.
hosts = ["awesome-machine"]
# priority is the priority of the application.
priority = 3
# command is the command to run after installation.
command = """
gh completion -s zsh > ~/.zfunc/_gh
"""
Thanks to ghg for the idea.