1234567891011121314151617181920212223242526272829303132333435363738394041424344 |
- # Maintainer: Sven-Hendrik Haase <svenstaro@archlinux.org>
- # Contributor: Gennadiy Mykhailiuta <gmykhailiuta@gmail.com>
- # Contributor: Xuanwo <xuanwo@archlinuxcn.org>
- pkgname=obsidian
- pkgver=1.4.16
- pkgrel=1
- pkgdesc="A powerful knowledge base that works on top of a local folder of plain text Markdown files"
- arch=('x86_64')
- url="https://obsidian.md/"
- license=('custom:Commercial')
- depends=('zlib' 'hicolor-icon-theme' 'fuse' 'electron', 'xdg-utils')
- makedepends=('asar')
- options=(!strip)
- source=("obsidian.sh"
- "obsidian.desktop"
- "https://github.com/obsidianmd/obsidian-releases/releases/download/v${pkgver}/obsidian-${pkgver}.tar.gz"
- )
- sha256sums=('b5dcbbded25b7f65fd274eb9c98c4a4143e9c405074f97c5123c56df5482bd91'
- 'be67713e873a5935d910efc6f6005c104b35c7b3a002dfcb5643fd185d1b0056'
- '3c128b1acdcc6726ab48c8969e3a98eddf5b42b2aedae2c0bcb52e7e91cbc5cc')
- prepare() {
- cd "$srcdir"
- asar ef "${pkgname}-${pkgver}"/resources/obsidian.asar icon.png
- }
- package() {
- cd "$srcdir"
- # Install executable file
- install -Dm755 "$pkgname".sh "$pkgdir"/usr/bin/obsidian
- # Install desktop file
- install -Dm644 "$pkgname".desktop -t "$pkgdir"/usr/share/applications/
- install -Dm644 icon.png "$pkgdir"/usr/share/pixmaps/obsidian.png
- # Most of the release package is electron, but we use system's default one
- # So strip away asar packages and put them to /usr/lib/
- cd "${pkgname}-${pkgver}"/resources/
- install -dm0755 "$pkgdir"/usr/lib/obsidian
- find . -type d -exec install -d {,"$pkgdir"/usr/lib/obsidian/}{} \;
- find . -type f -exec install -D {,"$pkgdir"/usr/lib/obsidian/}{} \;
- }
|