aboutsummaryrefslogblamecommitdiffstats
path: root/community/shfmt/APKBUILD
blob: 72ccab38d6faf1cb94c06ecc18446fa7a77e69f0 (plain) (tree)
1
2
3
4
5
6
7
8
9

                                                    
             
            
        

                                                                   
                        
                      
                
                                                                                     
                             
 
         
                  


                                                               

 



                     
           
                                                    

 
                                                                                                                                                                 
# Contributor: Olliver Schinagl <oliver@schinagl.nl>
# Maintainer: Olliver Schinagl <oliver@schinagl.nl>
pkgname=shfmt
pkgver=3.2.0
pkgrel=0
pkgdesc="A shell parser, formatter, and interpreter (sh/bash/mksh)"
url="https://mvdan.cc/sh"
arch="all !mips !mips64"
license="BSD-3-Clause"
makedepends="go"
source="$pkgname-$pkgver.tar.gz::https://github.com/mvdan/sh/archive/v$pkgver.tar.gz"
builddir="$srcdir/sh-$pkgver"

build() {
	go build \
		-ldflags "-w -X main.version=$pkgver-$pkgrel" \
		-v \
		./cmd/shfmt
}

check() {
	go test ./...
}

package() {
	install -Dm755 shfmt "$pkgdir"/usr/bin/shfmt
}

sha512sums="2f019fea811a1a8e995b8fb2ae77ea4f52c0ff82f3b049f22730b5aba8f7a580cf046cb93bc779999805edbc6b9b7c1ab81cdc800bc3068be5631dd947849770  shfmt-3.2.0.tar.gz"