summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorNikos Toutountzoglou2024-04-24 21:23:51 +0200
committerNikos Toutountzoglou2024-04-24 21:23:51 +0200
commitb8f76e81e04d0545cd70cbc44ab46f3bac2ed54f (patch)
tree23aaf9066bb2ed221243f6bcfc2f08a760e7e77c
parent0b6afa051256dc7cf540d3013bfad49ad044b76b (diff)
downloadaur-b8f76e81e04d0545cd70cbc44ab46f3bac2ed54f.tar.gz
Fixes in PKGBUILD. Added update option for SiteIni channels list.
-rw-r--r--.SRCINFO7
-rw-r--r--PKGBUILD18
-rw-r--r--wgpp.sh32
3 files changed, 49 insertions, 8 deletions
diff --git a/.SRCINFO b/.SRCINFO
index ca3b9e2dd4c2..022eb728d9e4 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,17 +1,20 @@
pkgbase = wg++
pkgdesc = WebGrab+Plus is a multi-site incremental xmltv epg grabber
pkgver = 5.1.5
- pkgrel = 2
+ pkgrel = 3
url = http://webgrabplus.com/
arch = any
license = custom
depends = dotnet-runtime-8.0
depends = libxml2
+ depends = unzip
source = wg++-5.1.0.tar.gz::http://webgrabplus.com/sites/default/files/download/SW/V5.1.0/WebGrabPlus_V5.1_install.tar_0.gz
source = wg++-5.1.5.tar.gz::http://webgrabplus.com/sites/default/files/download/SW/V5.1.5/WebGrabPlus_V5.1.5_beta_install.tar.gz
+ source = http://webgrabplus.com/sites/default/files/download/ini/SiteIniPack_current.zip
source = wgpp.sh
sha256sums = 368b14be4b0ec724ac394b59b26c05ecff3cef2864572a8cca844d56e1ce6f0f
sha256sums = 8d9b7cdff826ae4bd8aa8f033bafcf5bea6525b3b6fbdebf724918b1ba788ad0
- sha256sums = 3e5873dcf4007156274b72d6094d79e1c73e735baf4be9a0c66757554f40419c
+ sha256sums = 8d93b5c52f0926a4cd6c3ef7533b288f62de7e6966114be0b95135682d52c5ea
+ sha256sums = 940392becb59c70f97c5ed1a1d49aab7d69386b5a4bb724bd48b8da39e40e1cc
pkgname = wg++
diff --git a/PKGBUILD b/PKGBUILD
index 108bdc593614..48859b515d0f 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -2,7 +2,7 @@
pkgname=wg++
pkgver=5.1.5
-pkgrel=2
+pkgrel=3
pkgdesc="WebGrab+Plus is a multi-site incremental xmltv epg grabber"
arch=(any)
url="http://webgrabplus.com/"
@@ -10,25 +10,35 @@ license=(custom)
depends=(
dotnet-runtime-8.0
libxml2
+ unzip
)
source=("${pkgname}-5.1.0.tar.gz::http://webgrabplus.com/sites/default/files/download/SW/V5.1.0/WebGrabPlus_V5.1_install.tar_0.gz"
"${pkgname}-${pkgver}.tar.gz::http://webgrabplus.com/sites/default/files/download/SW/V${pkgver}/WebGrabPlus_V${pkgver}_beta_install.tar.gz"
+ "http://webgrabplus.com/sites/default/files/download/ini/SiteIniPack_current.zip"
'wgpp.sh')
sha256sums=('368b14be4b0ec724ac394b59b26c05ecff3cef2864572a8cca844d56e1ce6f0f'
'8d9b7cdff826ae4bd8aa8f033bafcf5bea6525b3b6fbdebf724918b1ba788ad0'
- '3e5873dcf4007156274b72d6094d79e1c73e735baf4be9a0c66757554f40419c')
+ '8d93b5c52f0926a4cd6c3ef7533b288f62de7e6966114be0b95135682d52c5ea'
+ '940392becb59c70f97c5ed1a1d49aab7d69386b5a4bb724bd48b8da39e40e1cc')
prepare() {
# Rename folder
mv .$pkgname $pkgname
+ # Install latest SiteIniPack from 'http://webgrabplus.com/node/231'
+ cp -r siteini.pack/* $pkgname/siteini.pack.update
# Run install.sh script
cd $pkgname
./install.sh
+ # Fix for 'No Internet' issue
sed -i 's/guide\.xml/latest\.xml/g' WebGrab++.config.xml
}
package() {
- install -d "$pkgdir"/usr/share/$pkgname
- cp -r --preserve=mode $pkgname "$pkgdir"/usr/share
+ install -d "$pkgdir"/usr/share/$pkgname/{bin.net,doc,mdb,rex,siteini.pack,siteini.user}
+ cp -r --no-preserve=mode,ownership "$srcdir"/$pkgname/{bin.net,doc,mdb,rex,siteini.pack} "$pkgdir"/usr/share/$pkgname
+ install -Dm644 "$srcdir"/$pkgname/WebGrab++.config.example.xml "$pkgdir"/usr/share/$pkgname/WebGrab++.config.example.xml
+ install -Dm644 "$srcdir"/$pkgname/WebGrab++.config.xml "$pkgdir"/usr/share/$pkgname/WebGrab++.config.xml
+ install -Dm755 "$srcdir"/$pkgname/install.sh "$pkgdir"/usr/share/$pkgname/install.sh
+ install -Dm755 "$srcdir"/$pkgname/run.net.sh "$pkgdir"/usr/share/$pkgname/run.net.sh
install -Dm755 "$srcdir"/wgpp.sh "$pkgdir"/usr/bin/$pkgname
}
diff --git a/wgpp.sh b/wgpp.sh
index c5b3101f1245..79e33eddef80 100644
--- a/wgpp.sh
+++ b/wgpp.sh
@@ -1,7 +1,7 @@
#!/bin/bash
# script: wg++ (WebGrab+Plus)
# author: Nikos Toutountzoglou, nikos.toutou@protonmail.com
-# rev.date: 21/04/2024
+# rev.date: 24/04/2024
# vars
WGPP_USR=$(whoami)
@@ -13,13 +13,15 @@ WGPP_SYS=/usr/share/wg++
# functions
helpMsg() {
echo "WebGrab+Plus EPG/XMLTV grabber"
- echo "Usage: $WGPP_EXE [-d|--dir <CUSTOM_DIR>] [-g|--generate] [-d <CUSTOM_DIR> -g]"
+ echo "Usage: $WGPP_EXE [-d|--dir <CUSTOM_DIR>] [-g|--generate] [-d <CUSTOM_DIR> -g] [-u|--update] [-d <CUSTOM_DIR> -u]"
echo " $WGPP_EXE -h|-?|--help"
echo
echo "Options:"
echo " -d <CUSTOM_DIR> Run from custom configuration folder <CUSTOM_DIR>."
echo " -g Create new configuration folder 'wg++' in user's home directory."
echo " -d <CUSTOM_DIR> -g Create new custom configuration folder <CUSTOM_DIR>."
+ echo " -u Update to latest 'siteini.pack' and channel list files."
+ echo " -d <CUSTOM_DIR> -u Update custom configuration folder to latest 'siteini.pack' and channel list files."
}
missingSysFiles() {
@@ -29,6 +31,28 @@ missingSysFiles() {
fi
}
+updateSiteIni() {
+ SITEINI_URL="http://webgrabplus.com/sites/default/files/download/ini/SiteIniPack_current.zip"
+
+ if ! type unzip > /dev/null; then
+ echo ":: Unzip (unzip) is not installed. Please install it first before updating 'siteini.pack'."
+ exit 1
+ fi
+
+ if [ -d "$WGPP_CFGDIR/siteini.pack" ]; then
+ echo ":: Starting update of '$WGPP_CFGDIR/siteini.pack' to latest release."
+ cd "$WGPP_CFGDIR"
+ curl -LO $SITEINI_URL
+ unzip -o "SiteIniPack_current.zip" "siteini.pack/*"
+ rm -f "SiteIniPack_current.zip"
+ else
+ echo ":: Error, cannot find folder 'siteini.pack'. Recreating folder."
+ echo ":: Please re-run 'update' of 'siteini.pack' now."
+ mkdir -v -p "$WGPP_CFGDIR/siteini.pack"
+ exit 1
+ fi
+}
+
missingWGPPDir() {
if [ ! -d "$WGPP_CFGDIR" ]; then
echo ":: No '$WGPP_EXE' working directory found for user '$WGPP_USR', exiting."
@@ -86,6 +110,10 @@ do
-g|--generate|-[Gg]enerate)
genFolder
;;
+ -u|--update|-[Uu]pdate)
+ updateSiteIni
+ exit 0
+ ;;
-?|--?|-h|--help|-[Hh]elp)
helpMsg
exit 1