Skip to content
This repository has been archived by the owner on Jul 14, 2024. It is now read-only.

Commit

Permalink
Add deb packager script
Browse files Browse the repository at this point in the history
  • Loading branch information
fido-node committed Dec 29, 2023
1 parent 552372d commit b7818f2
Showing 1 changed file with 36 additions and 0 deletions.
36 changes: 36 additions & 0 deletions .github/deb_build.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
#!/bin/bash

# Define package information
PACKAGE_NAME="rusty-belt"
MAINTAINER="Aleksandr Mikhailov <[email protected]>"
DESCRIPTION="Rust replacement for tmux powerline"

AARCH="$1"
BINARY_PATH="$2"

# Create package directory
PACKAGE_DIR="${PACKAGE_NAME}_${AARCH}"
mkdir -p "$PACKAGE_DIR/DEBIAN"

# Create control file
cat > "$PACKAGE_DIR/DEBIAN/control" <<EOF
Package: $PACKAGE_NAME
Architecture: $AARCH
Maintainer: $MAINTAINER
Description: $DESCRIPTION
EOF

# Create install file
cat > "$PACKAGE_DIR/DEBIAN/install" <<EOF
tmux_client usr/bin
rusty_belt_server usr/bin
EOF

cp $BINARY_PATH/tmux_client $PACKAGE_DIR
cp $BINARY_PATH/rusty_belt_server $PACKAGE_DIR

# Create package
dpkg-deb --build "$PACKAGE_DIR"

# Clean up
rm -r "$PACKAGE_DIR"

0 comments on commit b7818f2

Please sign in to comment.