Compare commits
11 Commits
6fc6207da8
...
v0.2.2
| Author | SHA1 | Date | |
|---|---|---|---|
| d9c9eda823 | |||
|
4737dbb60d
|
|||
| f82249d10f | |||
|
d46ad2c2b4
|
|||
| 7911a7ed6f | |||
|
9853f854c9
|
|||
| a2c8ff0f84 | |||
|
0ca8ed94cc
|
|||
| 227a0426b5 | |||
|
20d143035e
|
|||
| 7b5b855774 |
19
CHANGELOG.md
19
CHANGELOG.md
@@ -2,7 +2,24 @@
|
|||||||
|
|
||||||
All notable changes to this project will be documented in this file.
|
All notable changes to this project will be documented in this file.
|
||||||
|
|
||||||
## [unreleased]
|
## [0.2.2](https://git.0xmax42.io/maxp/systemd-timer/compare/v0.2.0..v0.2.2) - 2025-05-22
|
||||||
|
|
||||||
|
### 🐛 Bug Fixes
|
||||||
|
|
||||||
|
- *(install)* Enhance checksum validation with detailed comparison - ([0ca8ed9](https://git.0xmax42.io/maxp/systemd-timer/commit/0ca8ed94ccc4b9fe4ccac331957f01f852999094))
|
||||||
|
- *(install)* Ensure compatibility with non-bash shells - ([20d1430](https://git.0xmax42.io/maxp/systemd-timer/commit/20d143035ec6893f680b68dc4a2f6319ca7a5b81))
|
||||||
|
|
||||||
|
### 📚 Documentation
|
||||||
|
|
||||||
|
- *(readme)* Update installation instructions with script - ([9853f85](https://git.0xmax42.io/maxp/systemd-timer/commit/9853f854c991d87b12cd4fb5e19fce55e7246024))
|
||||||
|
|
||||||
|
## [0.2.0](https://git.0xmax42.io/maxp/systemd-timer/compare/v0.1.0..v0.2.0) - 2025-05-22
|
||||||
|
|
||||||
|
### 🚀 Features
|
||||||
|
|
||||||
|
- *(scripts)* Add installation script for systemd-timer binary - ([264b43c](https://git.0xmax42.io/maxp/systemd-timer/commit/264b43c9a667d344e27cca4ac2f17d7a4a25bffc))
|
||||||
|
- *(workflows)* Add matrix build and SHA256 generation for releases - ([118e4e5](https://git.0xmax42.io/maxp/systemd-timer/commit/118e4e5a867a42c0d79efcc3b2a4db188affedec))
|
||||||
|
- *(tasks)* Add build tasks for amd64 and arm64 targets - ([01898a3](https://git.0xmax42.io/maxp/systemd-timer/commit/01898a3a8e094dfbbf981ab6f1cf38d52f60ef5d))
|
||||||
|
|
||||||
### 🐛 Bug Fixes
|
### 🐛 Bug Fixes
|
||||||
|
|
||||||
|
|||||||
24
README.md
24
README.md
@@ -24,15 +24,27 @@ Ein einfaches CLI-Tool zum schnellen Erzeugen von systemd `.service` und `.timer
|
|||||||
|
|
||||||
## 🛠️ Installation
|
## 🛠️ Installation
|
||||||
|
|
||||||
```bash
|
|
||||||
git clone https://git.0xmax42.io/maxp/systemd-timer.git
|
|
||||||
cd systemd-timer
|
|
||||||
deno task build
|
|
||||||
|
|
||||||
# Binary liegt nun unter ./systemd-timer
|
Du kannst `systemd-timer` direkt per Shell-Skript installieren:
|
||||||
./systemd-timer --help
|
|
||||||
|
```bash
|
||||||
|
curl -fsSL https://git.0xmax42.io/maxp/systemd-timer/raw/branch/main/scripts/install.sh | sh
|
||||||
```
|
```
|
||||||
|
|
||||||
|
Das Skript erkennt automatisch deine Plattform (Linux `amd64` oder `arm64`) und installiert die passende Binary nach `/usr/local/bin`, sofern dies erlaubt ist (ggf. mit `sudo`).
|
||||||
|
|
||||||
|
**Hinweis:**
|
||||||
|
- Für die Installation ist eine funktionierende Internetverbindung notwendig.
|
||||||
|
- Die Integrität der Binary wird mittels SHA256-Prüfsumme verifiziert.
|
||||||
|
- Du kannst das Skript vor der Ausführung auch manuell inspizieren:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
curl -fsSL https://git.0xmax42.io/maxp/systemd-timer/raw/branch/main/scripts/install.sh -o install.sh
|
||||||
|
less install.sh
|
||||||
|
```
|
||||||
|
|
||||||
|
Weitere Optionen und manuelle Installationswege findest du unter [`scripts/install.sh`](scripts/install.sh).
|
||||||
|
|
||||||
---
|
---
|
||||||
|
|
||||||
## 📦 Beispiel
|
## 📦 Beispiel
|
||||||
|
|||||||
@@ -1,5 +1,11 @@
|
|||||||
#!/usr/bin/env bash
|
#!/usr/bin/env bash
|
||||||
set -euo pipefail
|
|
||||||
|
# Fail-safe bash mode (only if bash is used)
|
||||||
|
if [ -n "$BASH_VERSION" ]; then
|
||||||
|
set -euo pipefail
|
||||||
|
else
|
||||||
|
set -eu
|
||||||
|
fi
|
||||||
|
|
||||||
# === Konfiguration ===
|
# === Konfiguration ===
|
||||||
REPO_URL="https://git.0xmax42.io/maxp/systemd-timer/releases/download/latest"
|
REPO_URL="https://git.0xmax42.io/maxp/systemd-timer/releases/download/latest"
|
||||||
@@ -32,9 +38,18 @@ TMP_FILE=$(mktemp)
|
|||||||
curl -fsSL "${DOWNLOAD_URL}" -o "${TMP_FILE}"
|
curl -fsSL "${DOWNLOAD_URL}" -o "${TMP_FILE}"
|
||||||
chmod +x "${TMP_FILE}"
|
chmod +x "${TMP_FILE}"
|
||||||
|
|
||||||
# === Optional: SHA256-Check ===
|
# === SHA256-Check ===
|
||||||
curl -fsSL "${DOWNLOAD_URL}.sha256" -o "${TMP_FILE}.sha256"
|
TMP_HASH=$(mktemp)
|
||||||
echo "$(cat ${TMP_FILE}.sha256) ${TMP_FILE}" | sha256sum -c -
|
curl -fsSL "${DOWNLOAD_URL}.sha256" -o "$TMP_HASH"
|
||||||
|
EXPECTED_HASH=$(cut -d ' ' -f1 "$TMP_HASH")
|
||||||
|
ACTUAL_HASH=$(openssl dgst -sha256 "$TMP_FILE" | awk '{print $2}')
|
||||||
|
|
||||||
|
if [ "$EXPECTED_HASH" != "$ACTUAL_HASH" ]; then
|
||||||
|
echo "⚠️ Checksum mismatch!"
|
||||||
|
echo "Expected: $EXPECTED_HASH"
|
||||||
|
echo "Actual: $ACTUAL_HASH"
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
# === Installation ===
|
# === Installation ===
|
||||||
echo "🚀 Installing to ${INSTALL_PATH}/${BINARY_NAME}"
|
echo "🚀 Installing to ${INSTALL_PATH}/${BINARY_NAME}"
|
||||||
@@ -45,4 +60,4 @@ else
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
echo "✅ Installation complete: $(command -v ${BINARY_NAME})"
|
echo "✅ Installation complete: $(command -v ${BINARY_NAME})"
|
||||||
"${BINARY_NAME}" --version || true
|
"${BINARY_NAME}" --version || true
|
||||||
Reference in New Issue
Block a user