OSDN Git Service

[update] : Use one PKGBUILD
authorhayao <shun819.mail@gmail.com>
Sat, 26 Dec 2020 13:52:48 +0000 (22:52 +0900)
committerhayao <shun819.mail@gmail.com>
Sat, 26 Dec 2020 13:52:48 +0000 (22:52 +0900)
alter-stable/any/alterlinux-desktop-file/.SRCINFO [deleted file]
alter-stable/any/alterlinux-desktop-file/PKGBUILD [deleted file]
alter-stable/any/alterlinux-gtk-bookmarks/.SRCINFO [deleted file]
alter-stable/any/alterlinux-gtk-bookmarks/PKGBUILD [deleted file]
alter-stable/any/alterlinux-live-tools/.SRCINFO
alter-stable/any/alterlinux-live-tools/PKGBUILD
alter-stable/any/alterlinux-welcome-page/.SRCINFO [deleted file]
alter-stable/any/alterlinux-welcome-page/PKGBUILD [deleted file]
alter-testing/x86_64/alterlinux-live-tools-git/.SRCINFO [new file with mode: 0644]
alter-testing/x86_64/alterlinux-live-tools-git/PKGBUILD [new file with mode: 0644]

diff --git a/alter-stable/any/alterlinux-desktop-file/.SRCINFO b/alter-stable/any/alterlinux-desktop-file/.SRCINFO
deleted file mode 100644 (file)
index bf73a3f..0000000
+++ /dev/null
@@ -1,13 +0,0 @@
-pkgbase = alterlinux-gtk-bookmarks
-       pkgdesc = Simple script to automatically generate GTK bookmarks
-       pkgver = 1.1
-       pkgrel = 1
-       url = https://github.com/FascodeNet/alterlinux-live-tools/tree/master/alterlinux-gtk-bookmarks
-       arch = any
-       license = SUSHI-WARE
-       depends = xdg-user-dirs
-       source = https://github.com/FascodeNet/alterlinux-live-tools/archive/v1.1.zip
-       md5sums = SKIP
-
-pkgname = alterlinux-gtk-bookmarks
-
diff --git a/alter-stable/any/alterlinux-desktop-file/PKGBUILD b/alter-stable/any/alterlinux-desktop-file/PKGBUILD
deleted file mode 100644 (file)
index e44e444..0000000
+++ /dev/null
@@ -1,24 +0,0 @@
-# Maintaoner: Yamada Hayao <hayao@fascode.net>
-
-pkgname="alterlinux-desktop-file"
-_reponame="alterlinux-live-tools"
-pkgver=1.1
-pkgrel=1
-pkgdesc="Simple script to automatically generate GTK bookmarks"
-arch=('any')
-_url="https://github.com/FascodeNet/${_reponame}"
-url="${_url}/tree/master/${pkgname}"
-license=('SUSHI-WARE')
-depends=('xdg-user-dirs')
-source=("${_url}/archive/v${pkgver}.zip")
-md5sums=('SKIP')
-
-
-package() {
-        cd "${srcdir}/${_reponame}-${pkgver}/${pkgname}"
-        install -m 755 -D "${pkgname}" "${pkgdir}/usr/bin/${pkgname}"
-        install -m 755 -D "calamares.desktop" "${pkgdir}/usr/share/alterlinux/desktop-file/calamares.desktop"
-
-        cd ..
-        install -m 755 -D "LICENSE.md" "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE.md"
-}
diff --git a/alter-stable/any/alterlinux-gtk-bookmarks/.SRCINFO b/alter-stable/any/alterlinux-gtk-bookmarks/.SRCINFO
deleted file mode 100644 (file)
index bf73a3f..0000000
+++ /dev/null
@@ -1,13 +0,0 @@
-pkgbase = alterlinux-gtk-bookmarks
-       pkgdesc = Simple script to automatically generate GTK bookmarks
-       pkgver = 1.1
-       pkgrel = 1
-       url = https://github.com/FascodeNet/alterlinux-live-tools/tree/master/alterlinux-gtk-bookmarks
-       arch = any
-       license = SUSHI-WARE
-       depends = xdg-user-dirs
-       source = https://github.com/FascodeNet/alterlinux-live-tools/archive/v1.1.zip
-       md5sums = SKIP
-
-pkgname = alterlinux-gtk-bookmarks
-
diff --git a/alter-stable/any/alterlinux-gtk-bookmarks/PKGBUILD b/alter-stable/any/alterlinux-gtk-bookmarks/PKGBUILD
deleted file mode 100644 (file)
index b8e4ce5..0000000
+++ /dev/null
@@ -1,23 +0,0 @@
-# Maintaoner: Yamada Hayao <hayao@fascode.net>
-
-pkgname="alterlinux-gtk-bookmarks"
-_reponame="alterlinux-live-tools"
-pkgver=1.1
-pkgrel=1
-pkgdesc="Simple script to automatically generate GTK bookmarks"
-arch=('any')
-_url="https://github.com/FascodeNet/${_reponame}"
-url="${_url}/tree/master/${pkgname}"
-license=('SUSHI-WARE')
-depends=('xdg-user-dirs')
-source=("${_url}/archive/v${pkgver}.zip")
-md5sums=('SKIP')
-
-
-package() {
-        cd "${srcdir}/${_reponame}-${pkgver}/${pkgname}"
-        install -m 755 -D "${pkgname}" "${pkgdir}/usr/bin/${pkgname}"
-
-        cd ..
-        install -m 755 -D "LICENSE.md" "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE.md"
-}
index 3a3cc66..e583732 100644 (file)
@@ -1,12 +1,39 @@
 pkgbase = alterlinux-live-tools
-       pkgdesc = Scripts required for live environment (meta package)
-       pkgver = 1.0
+       pkgdesc = Scripts required for live environment
+       pkgver = 1.2
        pkgrel = 1
        url = https://github.com/FascodeNet/alterlinux-live-tools
        arch = any
        license = SUSHI-WARE
+       depends = xdg-user-dirs
+       depends = bash
+       source = https://github.com/FascodeNet/alterlinux-live-tools/archive/v1.2.zip
+       md5sums = SKIP
+
+pkgname = alterlinux-live-tools
+       pkgdesc = Scripts required for live environment (meta package)
+       depends = xdg-user-dirs
+       depends = bash
+       depends = alterlinux-live-tools
        depends = alterlinux-gtk-bookmarks
        depends = alterlinux-welcome-page
+       depends = alterlinux-plasma-bookmarks
+       depends = alterlinux-desktop-file
+       provides = alterlinux-live-tools
+       conflicts = alterlinux-live-tools
 
-pkgname = alterlinux-live-tools
+pkgname = alterlinux-gtk-bookmarks
+       pkgdesc = Simple script to automatically generate GTK bookmarks
+
+pkgname = alterlinux-welcome-page
+       pkgdesc = A simple script to open the official AlterLinux website
+       optdepends = chromium: To open the page
+       optdepends = google-chrome: To open the page
+       optdepends = firefox: To open the page
+
+pkgname = alterlinux-plasma-bookmarks
+       pkgdesc = Simple script to automatically generate Plasma bookmarks
+
+pkgname = alterlinux-desktop-file
+       pkgdesc = Place the Calamares icon on your desktop
 
index d02d199..ce5a5cc 100644 (file)
 # Maintaoner: Yamada Hayao <hayao@fascode.net>
 
-pkgname="alterlinux-live-tools"
-_reponame="${pkgname}"
-pkgver=1.0
+remove () {
+    local _list
+    local _file
+    _list=($(echo "$@"))
+    for _file in "${_list[@]}"; do
+        if [[ -f ${_file} ]]; then
+            rm -f "${_file}"
+        elif [[ -d ${_file} ]]; then
+            rm -rf "${_file}"
+        fi
+    done
+}
+_pkgname=(
+    "alterlinux-live-tools"
+    "alterlinux-gtk-bookmarks"
+    "alterlinux-welcome-page"
+    "alterlinux-plasma-bookmarks"
+    "alterlinux-desktop-file"
+)
+
+pkgname=(${_pkgname[@]})
+_reponame="alterlinux-live-tools"
+pkgver=1.2
 pkgrel=1
-pkgdesc="Scripts required for live environment (meta package)"
+pkgdesc="Scripts required for live environment"
 arch=('any')
 url="https://github.com/FascodeNet/${_reponame}"
 license=('SUSHI-WARE')
 depends=(
-        'alterlinux-gtk-bookmarks'
-        'alterlinux-welcome-page'
-)
\ No newline at end of file
+    "xdg-user-dirs"
+    "bash"
+)
+md5sums=("SKIP")
+source=("${url}/archive/v${pkgver}.zip")
+
+extracted="${_reponame}-${pkgver}"
+#extracted="${_reponame}"
+
+install_files() {
+    _pkgname="${pkgname}"
+    cd "${srcdir}/${extracted}/${_pkgname}"
+    install -m 755 -D "${_pkgname}" "${pkgdir}/usr/bin/${_pkgname}"
+}
+
+install_license() {
+    _pkgname="${pkgname}"
+    cd "${srcdir}/${extracted}/"
+    install -m 755 -D "LICENSE.md" "${pkgdir}/usr/share/licenses/${_pkgname}/LICENSE.md"
+}
+
+
+# alterlinux-live-tools
+package_alterlinux-live-tools() {
+    pkgdesc="Scripts required for live environment (meta package)"
+    conflicts=('alterlinux-live-tools')
+    provides=("alterlinux-live-tools")
+
+    depends+=(${_pkgname[@]})
+
+
+    install_license
+}
+
+# alterlinux-gtk-bookmarks
+package_alterlinux-gtk-bookmarks() {
+    pkgdesc="Simple script to automatically generate GTK bookmarks"
+    install_files
+    install_license
+}
+
+# alterlinux-welcome-page
+package_alterlinux-welcome-page() {
+    pkgdesc="A simple script to open the official AlterLinux website"
+    optdepends=(
+            'chromium: To open the page'
+            'google-chrome: To open the page'
+            'firefox: To open the page'
+    )
+
+    install_files
+    install_license
+}
+
+# alterlinux-plasma-bookmarks
+package_alterlinux-plasma-bookmarks() {
+    pkgdesc="Simple script to automatically generate Plasma bookmarks"
+    install_files
+    install_license
+}
+
+# alterlinux-desktop-file
+package_alterlinux-desktop-file() {
+    pkgdesc="Place the Calamares icon on your desktop"
+    install_files
+
+    cd "${srcdir}/${extracted}/"
+    install -m 755 -D "${srcdir}/${extracted}/${pkgname}/calamares.desktop" "${pkgdir}/usr/share/alterlinux/desktop-file/calamares.desktop"
+
+    install_license
+}
diff --git a/alter-stable/any/alterlinux-welcome-page/.SRCINFO b/alter-stable/any/alterlinux-welcome-page/.SRCINFO
deleted file mode 100644 (file)
index 22678b2..0000000
+++ /dev/null
@@ -1,16 +0,0 @@
-pkgbase = alterlinux-welcome-page
-       pkgdesc = A simple script to open the official AlterLinux website
-       pkgver = 1.1
-       pkgrel = 1
-       url = https://github.com/FascodeNet/alterlinux-live-tools/tree/master/alterlinux-welcome-page
-       arch = any
-       license = SUSHI-WARE
-       depends = xdg-user-dirs
-       optdepends = chromium: To open the page
-       optdepends = google-chrome: To open the page
-       optdepends = firefox: To open the page
-       source = https://github.com/FascodeNet/alterlinux-live-tools/archive/v1.1.zip
-       md5sums = SKIP
-
-pkgname = alterlinux-welcome-page
-
diff --git a/alter-stable/any/alterlinux-welcome-page/PKGBUILD b/alter-stable/any/alterlinux-welcome-page/PKGBUILD
deleted file mode 100644 (file)
index 6943b1d..0000000
+++ /dev/null
@@ -1,28 +0,0 @@
-# Maintaoner: Yamada Hayao <hayao@fascode.net>
-
-pkgname="alterlinux-welcome-page"
-_reponame="alterlinux-live-tools"
-pkgver=1.1
-pkgrel=1
-pkgdesc="A simple script to open the official AlterLinux website"
-arch=('any')
-_url="https://github.com/FascodeNet/${_reponame}"
-url="${_url}/tree/master/${pkgname}"
-license=('SUSHI-WARE')
-depends=('xdg-user-dirs')
-optdepends=(
-        'chromium: To open the page'
-        'google-chrome: To open the page'
-        'firefox: To open the page'
-)
-source=("${_url}/archive/v${pkgver}.zip")
-md5sums=('SKIP')
-
-
-package() {
-        cd "${srcdir}/${_reponame}-${pkgver}/${pkgname}"
-        install -m 755 -D "${pkgname}" "${pkgdir}/usr/bin/${pkgname}"
-
-        cd ..
-        install -m 755 -D "LICENSE.md" "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE.md"
-}
diff --git a/alter-testing/x86_64/alterlinux-live-tools-git/.SRCINFO b/alter-testing/x86_64/alterlinux-live-tools-git/.SRCINFO
new file mode 100644 (file)
index 0000000..2a83938
--- /dev/null
@@ -0,0 +1,36 @@
+pkgbase = alterlinux-live-tools-git
+       pkgdesc = Scripts required for live environment
+       pkgver = v1.1.r6.g98d307d
+       pkgrel = 1
+       url = https://github.com/FascodeNet/alterlinux-live-tools
+       arch = any
+       license = SUSHI-WARE
+       makedepends = git
+       depends = xdg-user-dirs
+       depends = bash
+       source = git+https://github.com/FascodeNet/alterlinux-live-tools.git
+       md5sums = SKIP
+
+pkgname = alterlinux-live-tools-git
+       pkgdesc = Scripts required for live environment (meta package)
+       depends = xdg-user-dirs
+       depends = bash
+       depends = alterlinux-desktop-file
+       provides = alterlinux-live-tools
+       conflicts = alterlinux-live-tools
+
+pkgname = alterlinux-gtk-bookmarks-git
+       pkgdesc = Simple script to automatically generate GTK bookmarks
+
+pkgname = alterlinux-welcome-page-git
+       pkgdesc = A simple script to open the official AlterLinux website
+       optdepends = chromium: To open the page
+       optdepends = google-chrome: To open the page
+       optdepends = firefox: To open the page
+
+pkgname = alterlinux-plasma-bookmarks-git
+       pkgdesc = Simple script to automatically generate Plasma bookmarks
+
+pkgname = alterlinux-desktop-file-git
+       pkgdesc = Place the Calamares icon on your desktop
+
diff --git a/alter-testing/x86_64/alterlinux-live-tools-git/PKGBUILD b/alter-testing/x86_64/alterlinux-live-tools-git/PKGBUILD
new file mode 100644 (file)
index 0000000..4ea69c9
--- /dev/null
@@ -0,0 +1,111 @@
+# Maintaoner: Yamada Hayao <hayao@fascode.net>
+
+remove () {
+    local _list
+    local _file
+    _list=($(echo "$@"))
+    for _file in "${_list[@]}"; do
+        if [[ -f ${_file} ]]; then
+            rm -f "${_file}"
+        elif [[ -d ${_file} ]]; then
+            rm -rf "${_file}"
+        fi
+    done
+}
+
+_pkgname=(
+    "alterlinux-live-tools"
+    "alterlinux-gtk-bookmarks"
+    "alterlinux-welcome-page"
+    "alterlinux-plasma-bookmarks"
+    "alterlinux-desktop-file"
+)
+_reponame="alterlinux-live-tools"
+pkgver=v1.1.r6.g98d307d
+pkgrel=1
+pkgdesc="Scripts required for live environment"
+arch=('any')
+url="https://github.com/FascodeNet/${_reponame}"
+license=('SUSHI-WARE')
+depends=(
+    "xdg-user-dirs"
+    "bash"
+)
+md5sums=("SKIP")
+makedepends+=("git")
+source=("git+${url}.git")
+
+#extracted="${_reponame}-${pkgver}"
+extracted="${_reponame}"
+
+install_files() {
+    _pkgname="${pkgname%-git}"
+    cd "${srcdir}/${extracted}/${_pkgname}"
+    install -m 755 -D "${_pkgname}" "${pkgdir}/usr/bin/${_pkgname}"
+}
+
+install_license() {
+    _pkgname="${pkgname%-git}"
+    cd "${srcdir}/${extracted}/"
+    install -m 755 -D "LICENSE.md" "${pkgdir}/usr/share/licenses/${_pkgname}/LICENSE.md"
+}
+
+pkgver() {
+  cd "${_reponame}"
+  git describe --long --tags | sed 's/\([^-]*-g\)/r\1/;s/-/./g'
+}
+
+for _pkg in ${_pkgname[@]}; do
+    pkgname+=("${_pkg}-git")
+done
+
+# alterlinux-live-tools-git
+package_alterlinux-live-tools-git() {
+    pkgdesc="Scripts required for live environment (meta package)"
+    conflicts=('alterlinux-live-tools')
+    provides=("alterlinux-live-tools")
+
+    for _pkg in ${pkgname[@]}; do
+        depends+=("${_pkg}")
+    done
+
+    install_license
+}
+
+# alterlinux-gtk-bookmarks-git
+package_alterlinux-gtk-bookmarks-git() {
+    pkgdesc="Simple script to automatically generate GTK bookmarks"
+    install_files
+    install_license
+}
+
+# alterlinux-welcome-page-git
+package_alterlinux-welcome-page-git() {
+    pkgdesc="A simple script to open the official AlterLinux website"
+    optdepends=(
+            'chromium: To open the page'
+            'google-chrome: To open the page'
+            'firefox: To open the page'
+    )
+
+    install_files
+    install_license
+}
+
+# alterlinux-plasma-bookmarks-git
+package_alterlinux-plasma-bookmarks-git() {
+    pkgdesc="Simple script to automatically generate Plasma bookmarks"
+    install_files
+    install_license
+}
+
+# alterlinux-desktop-file-git
+package_alterlinux-desktop-file-git() {
+    pkgdesc="Place the Calamares icon on your desktop"
+    install_files
+
+    cd "${srcdir}/${extracted}/"
+    install -m 755 -D "${srcdir}/${extracted}/${pkgname%-git}/calamares.desktop" "${pkgdir}/usr/share/alterlinux/desktop-file/calamares.desktop"
+
+    install_license
+}