diff --git a/cog/README.md b/cog/README.md new file mode 100644 index 0000000..222b990 --- /dev/null +++ b/cog/README.md @@ -0,0 +1,21 @@ +# cocogitto plugin + +[cocogitto](https://docs.cocogitto.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 cog "source:https://raw.githubusercontent.com/appthrust/proto-toml-plugins/main/cog/plugin.toml" --global +proto install cog +``` + +### Per-project install + +```shell +proto plugin add cog "source:https://raw.githubusercontent.com/appthrust/proto-toml-plugins/main/cog/plugin.toml" +proto pin cog latest --resolve +``` diff --git a/cog/plugin.test.ts b/cog/plugin.test.ts new file mode 100644 index 0000000..50ca466 --- /dev/null +++ b/cog/plugin.test.ts @@ -0,0 +1,8 @@ +import { run } from "../testkit.js"; + +run({ + name: "cog", + afterInstall: async ($) => { + await $`cog --version`; + }, +}); diff --git a/cog/plugin.toml b/cog/plugin.toml new file mode 100644 index 0000000..1920cfc --- /dev/null +++ b/cog/plugin.toml @@ -0,0 +1,33 @@ +# A TOML plugin for cocogitto: +# https://moonrepo.dev/docs/proto/plugins#toml-plugin + +name = "cog" +type = "cli" + +[platform.linux] +archive-prefix = "cocogitto-{version}-{arch}-unknown-linux-musl" +exe-path = "{arch}-unknown-linux-musl/cog" +download-file = "cocogitto-{version}-{arch}-unknown-linux-musl.tar.gz" +archs = ["x86_64"] + +[platform.macos] +archive-prefix = "cocogitto-{version}-{arch}-apple-darwin" +exe-path = "{arch}-apple-darwin/cog" +download-file = "cocogitto-{version}-{arch}-apple-darwin.tar.gz" +archs = ["x86_64"] + +[platform.windows] +archive-prefix = "cocogitto-{version}-{arch}-pc-windows-msvc" +exe-path = "{arch}-pc-windows-msvc/cog.exe" +download-file = "cocogitto-{version}-{arch}-pc-windows-msvc.tar.gz" +archs = ["x86_64"] + +[install] +download-url = "https://github.com/cocogitto/cocogitto/releases/download/{version}/{download_file}" + +[install.arch] +arm = "armv7" + +[resolve] +git-url = "https://github.com/cocogitto/cocogitto" +