summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorAlex2023-06-20 11:32:56 +0200
committerAlex2023-06-20 11:32:56 +0200
commit9e7ebab3f81f3643c0eabf9f227c7a0ce0198966 (patch)
tree0271905c534df0a9d54aa19e3a32d8898748364a
downloadaur-lichess.tar.gz
Add Lichess
-rw-r--r--.SRCINFO20
-rw-r--r--PKGBUILD50
-rw-r--r--lichess.desktop8
-rw-r--r--lichess.pngbin0 -> 1511 bytes
-rw-r--r--no-scrollbar.css3
5 files changed, 81 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 000000000000..09e471b2997d
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,20 @@
+pkgbase = lichess
+ pkgdesc = Electron wrapper for Lichess.org chess platform
+ pkgver = 1.0.0
+ pkgrel = 1
+ url = https://lichess.org
+ arch = x86_64
+ license = GNU AGPL
+ makedepends = nodejs
+ makedepends = nodejs-nativefier
+ makedepends = npm
+ provides = lichess
+ conflicts = lichess
+ source = lichess.png
+ source = lichess.desktop
+ source = no-scrollbar.css
+ sha256sums = 4569f979e5247143fbcc961ce6017cbf6662b683152d245c004121488ae1ad87
+ sha256sums = 1b9991641ecbd3145673d567c4fc22c26d5e65fbf23a77301dc94d7aaf00b507
+ sha256sums = 65f4043f2206e43cbbc510246f6a35a673e829bd8ab5b90b790b1ba7c14ea26b
+
+pkgname = lichess
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 000000000000..dba771b29719
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,50 @@
+# Maintainer: Alexis Potelle <alexispotelle at gmail dot com>
+
+_instname=lichess
+pkgname=lichess
+pkgver=1.0.0
+pkgrel=1
+pkgdesc="Electron wrapper for Lichess.org chess platform"
+arch=('x86_64')
+url=https://lichess.org
+license=('GNU AGPL')
+groups=()
+depends=()
+makedepends=(nodejs nodejs-nativefier npm)
+provides=($pkgname)
+conflicts=($pkgname)
+replaces=()
+backup=()
+options=()
+install=
+source=("$pkgname.png"
+ "$pkgname.desktop"
+ "no-scrollbar.css")
+sha256sums=('4569f979e5247143fbcc961ce6017cbf6662b683152d245c004121488ae1ad87'
+ '1b9991641ecbd3145673d567c4fc22c26d5e65fbf23a77301dc94d7aaf00b507'
+ '65f4043f2206e43cbbc510246f6a35a673e829bd8ab5b90b790b1ba7c14ea26b')
+
+
+build() {
+ nativefier $url \
+ --icon $pkgname.png \
+ --name $_instname \
+ --user-agent "Mozilla/5.0 (X11; Linux ${CARCH};) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/114.0.5735.133 Safari/537.36"\
+ --inject no-scrollbar.css\
+ --internal-urls "(.*?lichess\.org.*?)" \
+ --single-instance \
+ --tray
+
+}
+
+package() {
+ install -d "$pkgdir"/opt "$pkgdir"/usr/{bin,share/pixmaps}
+ install -Dm644 $pkgname.desktop "$pkgdir"/usr/share/applications/$_instname.desktop
+
+ cp -rL $_instname-linux-* "$pkgdir"/opt/$pkgname
+ ln -sf /opt/$pkgname/$_instname "$pkgdir"/usr/bin/$_instname
+ cp $srcdir/$pkgname.png "$pkgdir"/usr/share/pixmaps/$_instname.png
+
+ chmod 666 "$pkgdir"/opt/$pkgname/resources/app/nativefier.json
+}
+
diff --git a/lichess.desktop b/lichess.desktop
new file mode 100644
index 000000000000..511a81823b89
--- /dev/null
+++ b/lichess.desktop
@@ -0,0 +1,8 @@
+[Desktop Entry]
+Type=Application
+Name=Lichess
+Comment=Play chess on lichess.org
+Exec=lichess
+Icon=lichess
+Terminal=false
+Categories=Game;Chess;Nativefier;
diff --git a/lichess.png b/lichess.png
new file mode 100644
index 000000000000..4f62db44cc98
--- /dev/null
+++ b/lichess.png
Binary files differ
diff --git a/no-scrollbar.css b/no-scrollbar.css
new file mode 100644
index 000000000000..85df2e70e284
--- /dev/null
+++ b/no-scrollbar.css
@@ -0,0 +1,3 @@
+::-webkit-scrollbar {
+ display: none;
+}