summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: dfba4cc4aba1504dc6c8c644ceae23ae8cf423ff (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
# Maintainer:
# Contributor: j.r <j.r@jugendhacker.de>

## options
: ${_commit=2b0c0cf199b11e0bb5d283bd1df997f1241656e5} # 0.19.0.r3

## basic info
_pkgname="telegram-tg"
pkgname="$_pkgname"
pkgver=0.19.0
pkgrel=5
pkgdesc="Telegram client for terminal"
url="https://github.com/paul-nameless/tg"
license=('Unlicense')
arch=('any')

depends=(
  'python'
  'python-telegram'
)
makedepends=(
  'python-build'
  'python-installer'
  'python-poetry'
  'python-setuptools'
  'python-wheel'
)
optdepends=(
  'libnotify: for notifications, you could also use other programs: see config'
  'ffmpeg: to record voice msgs and upload videos correctly'
  'urlview: to choose urls when there is multiple in message, use URL_VIEW in config file to use another app, it should accept urls in stdin'
  'ranger: can be used to choose file when sending, customizable with FILE_PICKER_CMD'
  'nnn: can be used to choose file when sending, customizable with FILE_PICKER_CMD'
  'fzf: to create groups and secret chats, used for single and multiple user selection'
)

_pkgsrc="tg-$_commit"
_pkgext="tar.gz"
source=("$_pkgname-$pkgver-${_commit::7}.$_pkgext"::"$url/archive/$_commit.$_pkgext")
sha256sums=('SKIP')

build() {
  cd "$_pkgsrc"
  python -m build --wheel --no-isolation --skip-dependency-check
}

package() {
  cd "$_pkgsrc"
  python -m installer --destdir="$pkgdir" dist/*.whl
}