create initial looksyk aur package

This commit is contained in:
SebastianRzk 2025-03-06 22:14:40 +01:00
commit b746a0e8a3
3 changed files with 99 additions and 0 deletions

27
.SRCINFO Normal file
View file

@ -0,0 +1,27 @@
pkgbase = looksyk-desktop
pkgdesc = A markdown centric, fast and local personal knowledge platform
pkgver = 1.4.4
pkgrel = 1
url = https://sebastianrzk.github.io/Looksyk
arch = x86_64
license = AGPL-3.0-or-later
checkdepends = cargo
checkdepends = glibc
checkdepends = gcc-libs
makedepends = git
makedepends = nvm
makedepends = npm
makedepends = cargo
makedepends = glibc
makedepends = bash
makedepends = gcc-libs
depends = electron
depends = glibc
depends = bash
depends = gcc-libs
provides = looksyk
provides = looksyk-backend
source = git+https://github.com/sebastianrzk/looksyk#tag=v1.4.4
sha256sums = SKIP
pkgname = looksyk-desktop

1
.gitignore vendored Normal file
View file

@ -0,0 +1 @@
*

71
PKGBUILD Normal file
View file

@ -0,0 +1,71 @@
# This is an example PKGBUILD file. Use this as a start to creating your own,
# and remove these comments. For more information, see 'man PKGBUILD'.
# NOTE: Please fill out the license field for your package! If it is unknown,
# then please put 'unknown'.
# Maintainer: Your Name <youremail@domain.com>
pkgname=looksyk-desktop
_pkgnameshort=looksyk
pkgver=1.4.4
pkgrel=1
pkgdesc="A markdown centric, fast and local personal knowledge platform"
arch=("x86_64")
url="https://sebastianrzk.github.io/Looksyk"
license=('AGPL-3.0-or-later')
groups=()
depends=(electron glibc bash gcc-libs)
makedepends=(git nvm npm cargo glibc bash gcc-libs)
checkdepends=(cargo glibc gcc-libs)
provides=(looksyk looksyk-backend)
changelog=
source=("git+https://github.com/sebastianrzk/looksyk#tag=v$pkgver")
sha256sums=('SKIP')
prepare() {
cd "$_pkgnameshort"
#nvm install 23.5
cd frontend/looksyk
npm install
cd ../..
cd application-wrapper/Looksyk
npm install
cd ../..
}
build() {
cd "$_pkgnameshort"
cd backend
CFLAGS+=' -ffat-lto-objects' cargo build --release
cd ..
cd frontend/looksyk
npm run build --configuration=production
cd ../..
cd application-wrapper/Looksyk
npm run package
cd ..
}
check() {
cd "$_pkgnameshort"
cd backend
CFLAGS+=' -ffat-lto-objects' cargo test
}
package() {
cd "$_pkgnameshort"
mkdir -p "${pkgdir}/usr/share/${_pkgnameshort}"
install -d "${pkgdir}/usr/share/" "${pkgdir}/usr/bin/" "${pkgdir}/usr/lib/"
install -D -m644 "LICENSE" "${pkgdir}/usr/share/licenses/${_pkgnameshort}/LICENSE"
cp -r "frontend/looksyk/dist/looksyk/browser/" "${pkgdir}/usr/share/${_pkgnameshort}/static/"
install -D -m644 "application-wrapper/Looksyk/out/looksyk-linux-x64/resources/app.asar" "${pkgdir}/usr/share/${_pkgnameshort}/app.asar"
install -D -m644 "icon/Looksyk-scaled.png" "${pkgdir}/usr/share/${_pkgnameshort}/icon.png"
install -D -m644 "application-wrapper/Looksyk.desktop" "${pkgdir}/usr/share/applications/${pkgname}.desktop"
install -D -m755 "backend/target/release/looksyk" "${pkgdir}/usr/lib/${_pkgnameshort}/looksyk-backend"
install -D -m755 "application-wrapper/looksyk" "${pkgdir}/usr/lib/${_pkgnameshort}/looksyk"
ln -s "/usr/lib/${_pkgnameshort}/looksyk-backend" "${pkgdir}/usr/bin/looksyk-backend"
ln -s "/usr/lib/${_pkgnameshort}/looksyk" "${pkgdir}/usr/bin/looksyk"
}