makedeb


makedeb-beta 16.1.0-beta1


A simplicity-focused packaging tool for Debian archives

Click here to go back to the commit logs for makedeb-beta.

Commit:


Hash: 65ee39b047ceb43dc8dfb36dfb413d93e3ad7cb6

Message: Updated version to 5.9.4-1

Diff


diff --git a/.SRCINFO b/.SRCINFO
index 9c3eb18..6b1613b 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,6 +1,18 @@
 pkgbase = makedeb-beta
-	pkgver = 0
-	pkgrel = 0
+	pkgdesc = Create Debian archives from PKGBUILDs (beta release)
+	pkgver = {pkgver}
+	pkgrel = 1
+	url = https://github.com/makedeb/makedeb
 	arch = any
+	license = GPL3
+	depends = bash
+	depends = binutils
+	depends = file
+	depends = dpkg-dev
+	depends = makepkg
+	optdepends = apt
+	optdepends = git
+	source = https://github.com/makedeb/makedeb/archive/refs/tags/v{pkgver}-beta.tar.gz
+	sha256sums = SKIP
 
 pkgname = makedeb-beta
diff --git a/PKGBUILD b/PKGBUILD
index 56be638..9caab8f 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -1,8 +1,41 @@
-# NOTICE: This is a placeholder PKGBUILD. It will be updated shortly to work properly.
+# Maintainer: Hunter Wittenborn: <hunter@hunterwittenborn.com>
+_release_type=beta
 
 pkgname=makedeb-beta
-pkgver=0
-pkgrel=0
+pkgver={pkgver}
+pkgrel=1
+pkgdesc="Create Debian archives from PKGBUILDs (${_release_type} release)"
 arch=('any')
+license=('GPL3')
+depends=('bash' 'binutils' 'file' 'dpkg-dev' 'makepkg')
+optdepends=('apt' 'git')
+url="https://github.com/makedeb/makedeb"
 
-package(){ true; }
+source=("${url}/archive/refs/tags/v${pkgver}-${_release_type}.tar.gz")
+sha256sums=('SKIP')
+
+package() {
+    # Create single file for makedeb
+    mkdir -p "${pkgdir}/usr/bin"
+	cd "makedeb-${pkgver}-${_release_type}"
+
+    # Add bash shebang
+    echo '#!/usr/bin/env bash' > "${pkgdir}/usr/bin/makedeb"
+
+    # Copy functions
+    for i in $(find "src/functions/"); do
+        if ! [[ -d "${i}" ]]; then
+            cat "${i}" >> "${pkgdir}/usr/bin/makedeb"
+        fi
+    done
+    cat "src/makedeb.sh" >> "${pkgdir}/usr/bin/makedeb"
+
+    chmod 555 "${pkgdir}/usr/bin/makedeb"
+
+	# Set package version, release type, and target OS
+	sed -i "s|makedeb_package_version=.*|makedeb_package_version=${pkgver}|" "${pkgdir}/usr/bin/makedeb"
+	sed -i "s|makedeb_release_type=.*|makedeb_release_type=${_release_type}|" "${pkgdir}/usr/bin/makedeb"
+
+    # Remove testing commands
+    sed -i 's|.*# REMOVE AT PACKAGING||g' "${pkgdir}/usr/bin/makedeb"
+}