mirror of
https://github.com/dk98174003/Meshtastic-Client.git
synced 2026-03-28 17:32:36 +01:00
Add files via upload
This commit is contained in:
17
LinuxMint/MeshtasticClient.code-workspace
Normal file
17
LinuxMint/MeshtasticClient.code-workspace
Normal file
@@ -0,0 +1,17 @@
|
||||
{
|
||||
"folders": [
|
||||
{
|
||||
"path": "."
|
||||
}
|
||||
],
|
||||
"settings": {
|
||||
"python.defaultInterpreterPath": "/home/knud/GIT/Meshtastic/Meshtastic_client/.venv/bin/python",
|
||||
"python.interpreterPath": "/home/knud/GIT/Meshtastic/Meshtastic_client/.venv/bin/python",
|
||||
"python.pythonPath": "/home/knud/GIT/Meshtastic/Meshtastic_client/.venv/bin/python",
|
||||
"python.terminal.activateEnvironment": true,
|
||||
"terminal.integrated.env.linux": {
|
||||
"VIRTUAL_ENV": "${workspaceFolder}/.venv",
|
||||
"PATH": "${workspaceFolder}/.venv/bin:${env:PATH}"
|
||||
}
|
||||
}
|
||||
}
|
||||
10
LinuxMint/meshtastic-client.desktop
Normal file
10
LinuxMint/meshtastic-client.desktop
Normal file
@@ -0,0 +1,10 @@
|
||||
[Desktop Entry]
|
||||
Name=Meshtastic Client
|
||||
Comment=Meshtastic Desktop Client
|
||||
Exec=meshtastic-client
|
||||
Terminal=false
|
||||
Type=Application
|
||||
Icon=meshtastic
|
||||
Categories=Network;Utility;
|
||||
NoDisplay=false
|
||||
|
||||
BIN
LinuxMint/meshtastic-client_LinuxMint_amd64.deb
Normal file
BIN
LinuxMint/meshtastic-client_LinuxMint_amd64.deb
Normal file
Binary file not shown.
BIN
LinuxMint/meshtastic.png
Normal file
BIN
LinuxMint/meshtastic.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 475 KiB |
1086
LinuxMint/meshtastic_client.py
Normal file
1086
LinuxMint/meshtastic_client.py
Normal file
File diff suppressed because it is too large
Load Diff
79
LinuxMint/rebuilddeb.sh
Normal file
79
LinuxMint/rebuilddeb.sh
Normal file
@@ -0,0 +1,79 @@
|
||||
#!/bin/bash
|
||||
|
||||
### CONFIG ############################################################
|
||||
|
||||
APP_NAME="meshtastic-client"
|
||||
APP_VERSION=$(date +"1.0.%Y%m%d%H%M")
|
||||
PROJECT_DIR="/home/knud/Desktop/Meshtastic/Meshtastic_client"
|
||||
BUILD_DIR="$PROJECT_DIR/build"
|
||||
ICON_NAME="meshtastic.png"
|
||||
|
||||
######################################################################
|
||||
|
||||
echo "=== Building $APP_NAME version $APP_VERSION ==="
|
||||
cd "$PROJECT_DIR" || exit
|
||||
|
||||
### CLEAN OLD DEB FILES ##############################################
|
||||
|
||||
echo "[1/9] Removing old .deb packages..."
|
||||
rm -f ${APP_NAME}_*.deb
|
||||
|
||||
### CLEAN BUILD FOLDER ###############################################
|
||||
|
||||
echo "[2/9] Cleaning build directory..."
|
||||
rm -rf build
|
||||
mkdir -p "$BUILD_DIR/usr/local/bin"
|
||||
mkdir -p "$BUILD_DIR/usr/share/$APP_NAME"
|
||||
mkdir -p "$BUILD_DIR/usr/share/applications"
|
||||
mkdir -p "$BUILD_DIR/usr/share/icons/hicolor/48x48/apps"
|
||||
|
||||
### CREATE VENV ######################################################
|
||||
|
||||
echo "[3/9] Creating Python virtual environment..."
|
||||
python3 -m venv venv
|
||||
|
||||
echo "[4/9] Installing Python dependencies..."
|
||||
./venv/bin/python -m pip install --upgrade pip
|
||||
./venv/bin/python -m pip install meshtastic pyserial bleak protobuf
|
||||
|
||||
### COPY PROGRAM FILES ##############################################
|
||||
|
||||
echo "[5/9] Copying program files to build folder..."
|
||||
cp meshtastic_client.py "$BUILD_DIR/usr/share/$APP_NAME/"
|
||||
cp meshtastic-client.desktop "$BUILD_DIR/usr/share/applications/"
|
||||
|
||||
if [ -f "$ICON_NAME" ]; then
|
||||
echo "[6/9] Copying icon..."
|
||||
cp "$ICON_NAME" "$BUILD_DIR/usr/share/icons/hicolor/48x48/apps/$ICON_NAME"
|
||||
else
|
||||
echo "[6/9] WARNING: Icon file '$ICON_NAME' not found!"
|
||||
fi
|
||||
|
||||
### COPY VENV ########################################################
|
||||
|
||||
echo "[7/9] Copying virtual environment..."
|
||||
cp -r venv "$BUILD_DIR/usr/share/$APP_NAME/"
|
||||
|
||||
### CREATE LAUNCHER ##################################################
|
||||
|
||||
echo "[8/9] Creating launcher..."
|
||||
cat <<EOF > "$BUILD_DIR/usr/local/bin/$APP_NAME"
|
||||
#!/bin/bash
|
||||
/usr/share/$APP_NAME/venv/bin/python /usr/share/$APP_NAME/meshtastic_client.py
|
||||
EOF
|
||||
|
||||
chmod +x "$BUILD_DIR/usr/local/bin/$APP_NAME"
|
||||
|
||||
### BUILD .DEB PACKAGE ###############################################
|
||||
|
||||
echo "[9/9] Building .deb using fpm..."
|
||||
fpm -s dir -t deb -n "$APP_NAME" -v "$APP_VERSION" \
|
||||
--description "Meshtastic Desktop Client" \
|
||||
-C "$BUILD_DIR" \
|
||||
.
|
||||
|
||||
echo "======================================================"
|
||||
echo " Build finished!"
|
||||
echo " Created package: ${APP_NAME}_${APP_VERSION}_amd64.deb"
|
||||
echo "======================================================"
|
||||
|
||||
4
LinuxMint/requirements.txt
Normal file
4
LinuxMint/requirements.txt
Normal file
@@ -0,0 +1,4 @@
|
||||
meshtastic
|
||||
pyserial
|
||||
bleak
|
||||
protobuf
|
||||
7
LinuxMint/run-client
Normal file
7
LinuxMint/run-client
Normal file
@@ -0,0 +1,7 @@
|
||||
#!/bin/bash
|
||||
cd /home/knud/Desktop/Meshtastic/Meshtastic_client || exit
|
||||
set -a
|
||||
source .envrc
|
||||
set +a
|
||||
python3 meshtastic_client.py
|
||||
|
||||
Reference in New Issue
Block a user