summarylogtreecommitdiffstats
path: root/PKGBUILD-v2
blob: faa65a9d8ec79394f4505ad08d1c21fead0eb1bd (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
51
52
53
# Maintainer: ChacaS0 <chk-chaca@gmail.com>

pkgname=tempest
pkgver=0.1.1
pkgrel=1
pkgdesc="TEMPest is a CLI tool to help manage temporary content without much
effort"
arch=('x86_64' 'i686')
url="https://chacas0.github.io/tempest/"
license=('MIT')
depends=('git' 'go')
makedepends=('dep')
options=('!strip' '!emptydirs')
#source=("https://github.com/ChacaS0/tempest/archive/v$pkgver.tar.gz")
sha256sums=('b08305a9b82f39e71d5f00884aeb4086ff8c8bf29c085fd320572092e55444f1')
__gourl=github.com/ChacaS0/tempest


prepare() {
    # GOROOT
    export GOROOT=/usr/lib/go

    # GOPATH                                                                       
    if [[ -z "${GOPATH}" ]]; then                                                  
        export GOPATH="$HOME/gocode"                                                 
    fi

    # GOBIN
    if [[ -z "${GOBIN}"  ]]; then
        export GOBIN="$GOPATH/bin"
    fi

}

build() {
  #cd "$pkgname-$pkgver"
  #
  #go build
  go get -u -v -t "$__gourl"
}

package() {
 # cd "$pkgname-$pkgver"

 # install -Dm755 "$pkgname-$pkgver" "$pkgdir/usr/bin/$pkgname"
 # install -Dm644 LICENSE "$pkgdir/usr/share/licenses/$pkgname/LICENSE"
  if ! tempest > /dev/null 2>&1; then
    ln -s $GOBIN/tempest /usr/bin/tempest
    chmod +x /usr/bin/tempest
  fi

  echo "TEMPest should be now accessible"
}