diff --git a/yq/README.md b/yq/README.md new file mode 100644 index 0000000..255fb4b --- /dev/null +++ b/yq/README.md @@ -0,0 +1,21 @@ +# yq plugin + +[yq](https://yqcli.io) plugin for [proto](https://github.com/moonrepo/proto). + +## Installation + +This is a community plugin and is thus not built-in to proto. In order to use it, first either add it to your global or project-based `.prototools` by running: + +### Global install + +```shell +proto plugin add yq "source:https://raw.githubusercontent.com/appthrust/proto-toml-plugins/main/yq/plugin.toml" --global +proto install yq +``` + +### Per-project install + +```shell +proto plugin add yq "source:https://raw.githubusercontent.com/appthrust/proto-toml-plugins/main/yq/plugin.toml" +proto pin yq latest --resolve +``` diff --git a/yq/plugin.toml b/yq/plugin.toml new file mode 100644 index 0000000..95fb69b --- /dev/null +++ b/yq/plugin.toml @@ -0,0 +1,27 @@ +# A TOML plugin for yq: +# https://moonrepo.dev/docs/proto/plugins#toml-plugin + +name = "yq" +type = "cli" + +[platform.linux] +download-file = "yq_linux_{arch}" +checksum-file = "checksums" + +[platform.macos] +download-file = "yq_darwin_{arch}" +checksum-file = "checksums" + +[platform.windows] +download-file = "yq_windows_{arch}.exe" +checksum-file = "checksums" + +[install] +download-url = "https://github.com/mikefarah/yq/releases/download/v{version}/{download_file}" + +[install.arch] +aarch64 = "arm64" +x86_64 = "amd64" + +[resolve] +git-url = "https://github.com/mikefarah/yq"