Skip to content

Instantly share code, notes, and snippets.

@M0nteCarl0
Created July 14, 2024 14:24
debian_package build
#!/bin/bash
# Define package metadata
PACKAGE_NAME="myapp"
VERSION="1.0"
ARCHITECTURE="amd64"
MAINTAINER="Your Name <youremail@example.com>"
DESCRIPTION="Description of your application"
# Create package directories
mkdir -p myapp/DEBIAN
mkdir -p myapp/usr/bin
# Generate the control file
cat <<EOF > myapp/DEBIAN/control
Package: $PACKAGE_NAME
Version: $VERSION
Architecture: $ARCHITECTURE
Maintainer: $MAINTAINER
Description: $DESCRIPTION
EOF
# Copy the Avalonia application binary to the package directory
cp path/to/avalonia_binary myapp/usr/bin
# Set permissions
chmod 755 myapp/usr/bin/avalonia_binary
# Build the Debian package
dpkg-deb --build myapp
echo "Debian package built successfully!"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment