diff options
author | Abdulkadir Furkan Şanlı | 2023-12-05 14:06:44 +0100 |
---|---|---|
committer | Abdulkadir Furkan Şanlı | 2023-12-05 14:06:44 +0100 |
commit | 86e5d9e6f01cc1d435550ebf4068a1fe3c01f516 (patch) | |
tree | 95af9724e5d3d84d431ce14c6cd32045e721b311 | |
download | aur-86e5d9e6f01cc1d435550ebf4068a1fe3c01f516.tar.gz |
Initial commit of aoc-cli 0.12.0
-rw-r--r-- | .SRCINFO | 14 | ||||
-rw-r--r-- | .gitignore | 1 | ||||
-rw-r--r-- | PKGBUILD | 44 |
3 files changed, 59 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO new file mode 100644 index 000000000000..d9941bb988ec --- /dev/null +++ b/.SRCINFO @@ -0,0 +1,14 @@ +pkgbase = aoc-cli + pkgdesc = Advent of Code command-line tool + pkgver = 0.12.0 + pkgrel = 1 + url = https://github.com/scarvalhojr/aoc-cli + arch = x86_64 + license = MIT + makedepends = cargo + provides = aoc-cli + conflicts = aoc-cli + source = https://github.com/scarvalhojr/aoc-cli/archive/refs/tags/0.12.0.tar.gz + sha256sums = 5bd2eef8a310564c122be34ea9116967fe887ea549146adf38f4fbb0cddc0539 + +pkgname = aoc-cli diff --git a/.gitignore b/.gitignore new file mode 100644 index 000000000000..dd38fa22d95f --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +*.tar* diff --git a/PKGBUILD b/PKGBUILD new file mode 100644 index 000000000000..e13b4d1e360e --- /dev/null +++ b/PKGBUILD @@ -0,0 +1,44 @@ +#!/usr/bin/env bash +# shellcheck disable=SC2034,SC2154 +# Maintainer: Abdulkadir Furkan Şanlı <me@abdulocra.cy> + +pkgname='aoc-cli' +pkgver='0.12.0' +pkgrel='1' +pkgdesc='Advent of Code command-line tool' +arch=('x86_64') +url="https://github.com/scarvalhojr/${pkgname}" +license=('MIT') +makedepends=('cargo') +provides=("${pkgname}") +conflicts=("${pkgname}") +source=("https://github.com/scarvalhojr/aoc-cli/archive/refs/tags/${pkgver}.tar.gz") +sha256sums=('5bd2eef8a310564c122be34ea9116967fe887ea549146adf38f4fbb0cddc0539') + + +prepare () +{ + cd "${pkgname}-${pkgver}" + export RUSTUP_TOOLCHAIN=stable + cargo fetch --locked --target "$(rustc -vV | sed -n 's/host: //p')" +} + +build () +{ + cd "${pkgname}-${pkgver}" + export RUSTUP_TOOLCHAIN=stable + export CARGO_TARGET_DIR=target + cargo build --frozen --release --all-features +} + +check () +{ + cd "${pkgname}-${pkgver}" + export RUSTUP_TOOLCHAIN=stable + cargo test --frozen --all-features +} + +package () { + cd "${pkgname}-${pkgver}" + install -Dm0755 -t "${pkgdir}/usr/bin/" "target/release/${pkgname%-cli}" +} |