diff options
author | LevitatingBusinessMan (Rein Fernhout) | 2023-05-24 11:47:56 +0200 |
---|---|---|
committer | LevitatingBusinessMan (Rein Fernhout) | 2023-05-24 11:53:51 +0200 |
commit | d473ee85675e359b0a098579f7c27f378a54c25b (patch) | |
tree | 563707851d81458c7d3d03aa63b178e61b26c851 | |
download | aur-d473ee85675e359b0a098579f7c27f378a54c25b.tar.gz |
New git package
-rw-r--r-- | .SRCINFO | 13 | ||||
-rw-r--r-- | PKGBUILD | 35 |
2 files changed, 48 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO new file mode 100644 index 000000000000..c910bb4978b2 --- /dev/null +++ b/.SRCINFO @@ -0,0 +1,13 @@ +pkgbase = openai-cli-git + pkgdesc = CLI for the GPT model + pkgver = r27.e66bf5d + pkgrel = 1 + url = https://github.com/LevitatingBusinessMan/openai-cli + arch = x86_64 + license = MIT + makedepends = rust + makedepends = git + source = git+https://github.com/LevitatingBusinessMan/openai-cli + sha256sums = SKIP + +pkgname = openai-cli-git diff --git a/PKGBUILD b/PKGBUILD new file mode 100644 index 000000000000..34c7bf5d7620 --- /dev/null +++ b/PKGBUILD @@ -0,0 +1,35 @@ +#Maintainer: Rein Fernhout (LevitatingBusinessMan) <me@levitati.ng> + +pkgname=openai-cli-git +pkgver=r27.e66bf5d +arch=("x86_64") +pkgrel=1 +pkgdesc="CLI for the GPT model" +license=("MIT") +makedepends=("rust" "git") +url="https://github.com/LevitatingBusinessMan/openai-cli" +source=("git+https://github.com/LevitatingBusinessMan/openai-cli") +sha256sums=("SKIP") + +pkgver() { + cd "${srcdir}/openai-cli" + printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)" +} + +prepare() { + cd "${srcdir}/openai-cli" + export RUSTUP_TOOLCHAIN=stable + cargo fetch --locked --target "$CARCH-unknown-linux-gnu" +} + +build() { + cd "${srcdir}/openai-cli" + export RUSTUP_TOOLCHAIN=stable + export CARGO_TARGET_DIR=target1 + cargo build --frozen --release --all-features +} + +package() { + cd "${srcdir}/openai-cli" + install -Dm755 target/release/openai-cli $pkgdir/usr/bin/openai-cli +} |