summarylogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--.SRCINFO17
-rw-r--r--PKGBUILD37
2 files changed, 54 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 00000000000..af04b8e5ae5
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,17 @@
+pkgbase = fblog-git
+ pkgdesc = Small command-line JSON log viewer (git)
+ pkgver = 2.3.0.r2.g3217c44
+ pkgrel = 1
+ url = https://github.com/brocode/fblog
+ arch = x86_64
+ license = custom:WTFPL
+ makedepends = cargo
+ makedepends = git
+ provides = fblog
+ conflicts = fblog
+ conflicts = fblog-bin
+ source = git+https://github.com/brocode/fblog
+ sha512sums = SKIP
+
+pkgname = fblog-git
+
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 00000000000..977cbd19346
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,37 @@
+# Maintainer: orhun <orhunparmaksiz@gmail.com>
+# https://github.com/orhun/pkgbuilds
+
+pkgname=fblog-git
+pkgver=2.3.0.r2.g3217c44
+pkgrel=1
+pkgdesc="Small command-line JSON log viewer (git)"
+arch=('x86_64')
+url="https://github.com/brocode/fblog"
+license=('custom:WTFPL')
+makedepends=('cargo' 'git')
+conflicts=("${pkgname%-git}" "${pkgname%-git}-bin")
+provides=("${pkgname%-git}")
+source=("git+${url}")
+sha512sums=('SKIP')
+
+pkgver() {
+ cd "${pkgname%-git}"
+ git describe --long | sed 's/^v//;s/\([^-]*-g\)/r\1/;s/-/./g'
+}
+
+build() {
+ cd "${pkgname%-git}"
+ cargo build --release --locked --all-features
+}
+
+check() {
+ cd "${pkgname%-git}"
+ cargo test --release --locked
+}
+
+package() {
+ cd "${pkgname%-git}"
+ install -Dm 755 "target/release/${pkgname%-git}" -t "${pkgdir}/usr/bin"
+ install -Dm 644 README.org -t "$pkgdir/usr/share/doc/${pkgname%-git}"
+ install -Dm 644 LICENSE -t "$pkgdir/usr/share/licenses/${pkgname%-git}"
+}