blob: ffffabf98f5de4acd686241742677ac8c332462f (
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: Edvin Alvarado <ealvarado301 g-mail>
# Contributor: Edvin Alvarado <ealvarado301 g-mail>
pkgname=nanominer
pkgver=3.9.3
pkgrel=1
pkgdesc="nanopool mining software"
arch=('any')
depends=('pciutils' 'bash')
license=('custom:nanopool')
install=$pkgname.install
url='https://github.com/nanopool/nanominer/releases'
sha256sums=("7f851becd53c093e435e6ea42dc194c27eaddf01ef9508e776c761fcfcf29c9f"
"SKIP")
prepare() {
# copies config files in config_examples
mkdir -p config_examples
for FILE in config*.ini
do
cp -R $FILE ./config_examples/$FILE
done
# Avoids erasing existing config files to avoid erasing any user settings
for FILE in $pkgdir/opt/$pkgname/config*.ini
do
FILENAME=${FILE##*/}
for SRCFILE in config*.ini
do
if [ $FILENAME==$SRCFILE ]
then
rm $SRCFILE
fi
done
done
}
source=("https://github.com/nanopool/$pkgname/releases/download/v$pkgver/$pkgname-linux-$pkgver.tar.gz"
"https://github.com/nanopool/$pkgname/raw/master/Terms%20of%20Use%20Nanominer.pdf")
package() {
# Launcher
echo -e "#\!/bin/bash\ncd /opt/nanominer\nexec /opt/$pkgname/nanominer \$*" > nanominer.sh
install -Dm755 nanominer.sh "$pkgdir"/usr/bin/nanominer
# License
install -Dm644 Terms%20of%20Use%20Nanominer.pdf "$pkgdir"/usr/share/licenses/"$pkgname"/TOU_Nanominer.pdf
# Install
mkdir -p $pkgdir/opt/"$pkgname"
cp -R * $pkgdir/opt/"$pkgname"
}
|