diff options
author | Serene-Arc | 2024-06-23 14:27:52 +1000 |
---|---|---|
committer | Serene-Arc | 2024-06-23 14:27:52 +1000 |
commit | f0aed6b42a101578e16f039a50eb14cf04feb819 (patch) | |
tree | a79ccdf699cf4268a7c107b7f8a5a80e6c6948aa | |
download | aur-f0aed6b42a101578e16f039a50eb14cf04feb819.tar.gz |
Initial commit
-rw-r--r-- | .SRCINFO | 14 | ||||
-rwxr-xr-x | .gitignore | 4 | ||||
-rw-r--r-- | PKGBUILD | 42 |
3 files changed, 60 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO new file mode 100644 index 000000000000..25a83c378077 --- /dev/null +++ b/.SRCINFO @@ -0,0 +1,14 @@ +pkgbase = listenbrainz-playlist-uploader-git + pkgdesc = A tool for uploading playlists to ListenBrainz with feedback + pkgver = 0.1.0 + pkgrel = 1 + url = https://github.com/Serene-Arc/listenbrainz-playlist-uploader + arch = x86_64 + license = MIT + makedepends = cargo + options = debug + options = !strip + source = listenbrainz-playlist-uploader-git::git+https://github.com/Serene-Arc/listenbrainz-playlist-uploader.git + sha256sums = SKIP + +pkgname = listenbrainz-playlist-uploader-git diff --git a/.gitignore b/.gitignore new file mode 100755 index 000000000000..f71c635dafda --- /dev/null +++ b/.gitignore @@ -0,0 +1,4 @@ +* +!.gitignore +!PKGBUILD +!.SRCINFO diff --git a/PKGBUILD b/PKGBUILD new file mode 100644 index 000000000000..0b454b63b6ce --- /dev/null +++ b/PKGBUILD @@ -0,0 +1,42 @@ +# Maintainer: Serene-Arc + +pkgname=listenbrainz-playlist-uploader-git +pkgver=0.1.0.r1.g32408ff +pkgrel=1 +pkgdesc="A tool for uploading playlists to ListenBrainz with feedback" +url="https://github.com/Serene-Arc/listenbrainz-playlist-uploader" +license=("MIT") +arch=("x86_64") +makedepends=(cargo) +source=("$pkgname::git+https://github.com/Serene-Arc/listenbrainz-playlist-uploader.git") +options=("debug" "!strip") +sha256sums=("SKIP") + +pkgver() { + cd "$pkgname" + git describe --long --tags --abbrev=7 | sed 's/^v//;s/\([^-]*-g\)/r\1/;s/-/./g' +} + +prepare() { + export RUSTUP_TOOLCHAIN=stable + cd "$srcdir/$pkgname" + cargo fetch --locked --target "$(rustc -vV | sed -n 's/host: //p')" +} + +build() { + export RUSTUP_TOOLCHAIN=stable + export CARGO_TARGET_DIR=target + cd "$srcdir/$pkgname" + cargo build --frozen --release --all-features +} + +check() { + export RUSTUP_TOOLCHAIN=stable + cd "$srcdir/$pkgname" + cargo test --frozen --all-features +} + +package() { + cd "$srcdir/$pkgname" + install -Dm0755 -t "$pkgdir/usr/bin/" "target/release/listenbrainz-playlist-uploader" +} |