Skip to content

Installing YAMLScript

Ingy döt Net edited this page Mar 25, 2024 · 3 revisions

Temporary Install

If you just want to try out the ys command but not install it permanently, you can run this (in Bash and Zsh only):

$ source <(curl -sSL yamlscript.org/try-ys)

This will install ys under /tmp/ and add the directory to you current shell's PATH. It will only be available for the duration of the shell session that you run it in.

Quick Install

You can install both ys and libyamlscript with a single CLI command. VERSION defaults to the latest YAMLScript version. PREFIX defaults to $HOME/.local.

$ curl -sSL yamlscript.org/install | bash
$ curl -sSL yamlscript.org/install | VERSION=0.1.46 bash
$ curl -sSL yamlscript.org/install | PREFIX=/tmp/yamlscript bash

You'll need to have PREFIX/bin in your PATH. Unless you use the default PREFIX you'll need to add PREFIX/lib to LD_LIBRARY_PATH.

Download and Install

  • Download the appropriate release file.
  • Expand the file with $ tar xf <release-file>.
  • Use cd to enter the release directory.
  • Run make install or make install PREFIX=....
    • Or just copy the binary file to the place where you want it.

Build a Release from Source

You can also easily build and install ys and libyamlscript from source:

  • Download the "Source code" release file.
  • Expand the file with $ tar xf <release-file>.
  • Use cd to enter the release directory.
  • Run make install or make install PREFIX=....

This will take a few minutes but it requires no dependencies besides bash, make and curl.

On linux it also requires the libz-dev package.

Clone this wiki locally