mirror of
https://gitdl.cn/https://github.com/chakralinux/desktop.git
synced 2025-01-25 02:52:13 +08:00
46 lines
1.5 KiB
Bash
46 lines
1.5 KiB
Bash
pkgname=anki
|
|
pkgver=2.0.33
|
|
pkgrel=1
|
|
pkgdesc='Helps you remember facts (like words/phrases in a foreign language) efficiently.'
|
|
url='http://ankisrs.net/'
|
|
license=('GPL3')
|
|
arch=('x86_64')
|
|
categories=('utils')
|
|
screenshot=("http://ankisrs.net/shots/sync.png")
|
|
install='anki.install'
|
|
depends=('python2-beautifulsoup3' 'python2-pyqt4' 'python-pysqlite' 'python2-simplejson' 'python2-sqlalchemy')
|
|
optdepends=('python2-matplotlib: show graphs.'
|
|
'sox: audio recording.'
|
|
'python2-pyaudio: audio recording.')
|
|
source=("http://ankisrs.net/download/mirror/$pkgname-$pkgver.tgz")
|
|
sha512sums=('ac2df1ac94e5aa4cc04c17d41b8f96788b5f321860bc20b4a167d5ee0161ca4f7f586fda08ac9910a706ec3e7d1bd692d2e74f3de56997c9ce480122396e0d6d')
|
|
|
|
prepare() {
|
|
cd $srcdir/anki-$pkgver
|
|
sed -i 's|#!/usr/bin/env python|#!/usr/bin/env python2|' runanki
|
|
rm -f anki.bat
|
|
|
|
# Desktop integration. KDE needs Qt in Categories
|
|
desktop-file-install --dir "${pkgdir}/usr/share/applications" \
|
|
--add-category='Qt' \
|
|
${pkgname}.desktop
|
|
|
|
sed s/TryExec=anki/TryExec=runanki/ -i anki.desktop
|
|
sed s/Exec=anki/Exec=runanki/ -i anki.desktop
|
|
}
|
|
|
|
package() {
|
|
cd "${srcdir}/${pkgname}-${pkgver}"
|
|
|
|
install -d $pkgdir/usr/{bin,share/{anki,pixmaps,applications,man/man1}}
|
|
|
|
mv runanki $pkgdir/usr/bin/runanki
|
|
mv anki.xpm $pkgdir/usr/share/pixmaps/anki.xpm
|
|
mv anki.png $pkgdir/usr/share/pixmaps/anki.png
|
|
mv anki.desktop $pkgdir/usr/share/applications/anki.desktop
|
|
mv anki.1 $pkgdir/usr/share/man/man1/anki.1
|
|
|
|
cp -av * $pkgdir/usr/share/anki/
|
|
|
|
}
|