Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

gdir.pl: add package #4362

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions lists/to-release
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
gdir.pl
47 changes: 47 additions & 0 deletions packages/gdir.pl/PKGBUILD
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
# This file is part of BlackArch Linux ( https://www.blackarch.org/ ).
# See COPYING for license details.

pkgname=gdir.pl
pkgver=8.23e60c6
pkgrel=1
pkgdesc='Perl wrapper on gcrypt for directory encryption/decryption.'
arch=('any')
groups=('blackarch' 'blackarch-crypto')
url='https://gitlab.com/GasparVardanyan/gdir.pl'
license=('custom:unknown')
depends=('gcrypt' 'perl')
makedepends=('git')
source=("git+https://gitlab.com/GasparVardanyan/$pkgname.git")
sha512sums=('SKIP')

pkgver() {
cd $pkgname

( set -o pipefail
git describe --long --tags --abbrev=7 2>/dev/null |
sed 's/\([^-]*-g\)/r\1/;s/-/./g' ||
printf "%s.%s" "$(git rev-list --count HEAD)" \
"$(git rev-parse --short=7 HEAD)"
)
}

package() {
cd $pkgname

install -dm 755 "$pkgdir/usr/"{bin,share/$pkgname}
install -Dm 644 -t "$pkgdir/usr/share/doc/$pkgname/" *.md

install -Dm 644 LICENSE "$pkgdir/usr/share/licenses/$pkgname/LICENSE"

rm -rf LICENSE *.md

cp -a * "$pkgdir/usr/share/$pkgname/"

cat > "$pkgdir/usr/bin/$pkgname" << EOF
#!/bin/sh
exec perl /usr/share/$pkgname/gdir.pl "\$@"
EOF

chmod a+x "$pkgdir/usr/bin/$pkgname"
}

Loading