Compare commits
4 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 0fb9678976 | |||
| 635de0d932 | |||
| 0916effb53 | |||
| 05242a1c7d |
@@ -1,84 +0,0 @@
|
|||||||
name: CI
|
|
||||||
|
|
||||||
on:
|
|
||||||
push:
|
|
||||||
branches:
|
|
||||||
- main
|
|
||||||
- 'migration/**'
|
|
||||||
pull_request:
|
|
||||||
branches:
|
|
||||||
- main
|
|
||||||
|
|
||||||
jobs:
|
|
||||||
check:
|
|
||||||
name: Type Check & Lint
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
|
|
||||||
steps:
|
|
||||||
- name: Checkout code
|
|
||||||
uses: actions/checkout@v4
|
|
||||||
|
|
||||||
- name: Set up Deno
|
|
||||||
uses: denoland/setup-deno@v1
|
|
||||||
with:
|
|
||||||
deno-version: v2.x
|
|
||||||
|
|
||||||
- name: Check TypeScript types
|
|
||||||
run: deno check mod.ts
|
|
||||||
|
|
||||||
- name: Lint code
|
|
||||||
run: deno lint
|
|
||||||
continue-on-error: true
|
|
||||||
|
|
||||||
- name: Format check
|
|
||||||
run: deno fmt --check
|
|
||||||
continue-on-error: true
|
|
||||||
|
|
||||||
build:
|
|
||||||
name: Build Test (Current Platform)
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
|
|
||||||
steps:
|
|
||||||
- name: Checkout code
|
|
||||||
uses: actions/checkout@v4
|
|
||||||
|
|
||||||
- name: Set up Deno
|
|
||||||
uses: denoland/setup-deno@v1
|
|
||||||
with:
|
|
||||||
deno-version: v2.x
|
|
||||||
|
|
||||||
- name: Compile for current platform
|
|
||||||
run: |
|
|
||||||
echo "Testing compilation for Linux x86_64..."
|
|
||||||
deno compile --allow-all --no-check \
|
|
||||||
--output nupst-test \
|
|
||||||
--target x86_64-unknown-linux-gnu mod.ts
|
|
||||||
|
|
||||||
- name: Test binary execution
|
|
||||||
run: |
|
|
||||||
chmod +x nupst-test
|
|
||||||
./nupst-test --version
|
|
||||||
./nupst-test help
|
|
||||||
|
|
||||||
build-all:
|
|
||||||
name: Build All Platforms
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
|
|
||||||
steps:
|
|
||||||
- name: Checkout code
|
|
||||||
uses: actions/checkout@v4
|
|
||||||
|
|
||||||
- name: Set up Deno
|
|
||||||
uses: denoland/setup-deno@v1
|
|
||||||
with:
|
|
||||||
deno-version: v2.x
|
|
||||||
|
|
||||||
- name: Compile all platform binaries
|
|
||||||
run: bash scripts/compile-all.sh
|
|
||||||
|
|
||||||
- name: Upload all binaries as artifact
|
|
||||||
uses: actions/upload-artifact@v3
|
|
||||||
with:
|
|
||||||
name: nupst-binaries.zip
|
|
||||||
path: dist/binaries/*
|
|
||||||
retention-days: 30
|
|
||||||
@@ -1,129 +0,0 @@
|
|||||||
name: Publish to npm
|
|
||||||
|
|
||||||
on:
|
|
||||||
push:
|
|
||||||
tags:
|
|
||||||
- 'v*'
|
|
||||||
|
|
||||||
jobs:
|
|
||||||
npm-publish:
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
|
|
||||||
steps:
|
|
||||||
- name: Checkout code
|
|
||||||
uses: actions/checkout@v4
|
|
||||||
|
|
||||||
- name: Set up Deno
|
|
||||||
uses: denoland/setup-deno@v1
|
|
||||||
with:
|
|
||||||
deno-version: v2.x
|
|
||||||
|
|
||||||
- name: Setup Node.js for npm publishing
|
|
||||||
uses: actions/setup-node@v4
|
|
||||||
with:
|
|
||||||
node-version: '18.x'
|
|
||||||
registry-url: 'https://registry.npmjs.org/'
|
|
||||||
|
|
||||||
- name: Get version from tag
|
|
||||||
id: version
|
|
||||||
run: |
|
|
||||||
VERSION=${GITHUB_REF#refs/tags/}
|
|
||||||
echo "version=$VERSION" >> $GITHUB_OUTPUT
|
|
||||||
echo "version_number=${VERSION#v}" >> $GITHUB_OUTPUT
|
|
||||||
echo "Publishing version: $VERSION"
|
|
||||||
|
|
||||||
- name: Verify deno.json version matches tag
|
|
||||||
run: |
|
|
||||||
DENO_VERSION=$(grep -o '"version": "[^"]*"' deno.json | cut -d'"' -f4)
|
|
||||||
TAG_VERSION="${{ steps.version.outputs.version_number }}"
|
|
||||||
echo "deno.json version: $DENO_VERSION"
|
|
||||||
echo "Tag version: $TAG_VERSION"
|
|
||||||
if [ "$DENO_VERSION" != "$TAG_VERSION" ]; then
|
|
||||||
echo "ERROR: Version mismatch!"
|
|
||||||
echo "deno.json has version $DENO_VERSION but tag is $TAG_VERSION"
|
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
|
|
||||||
- name: Compile binaries for npm package
|
|
||||||
run: |
|
|
||||||
echo "Compiling binaries for npm package..."
|
|
||||||
deno task compile
|
|
||||||
echo ""
|
|
||||||
echo "Binary sizes:"
|
|
||||||
ls -lh dist/binaries/
|
|
||||||
|
|
||||||
- name: Generate SHA256 checksums
|
|
||||||
run: |
|
|
||||||
cd dist/binaries
|
|
||||||
sha256sum * > SHA256SUMS
|
|
||||||
cat SHA256SUMS
|
|
||||||
cd ../..
|
|
||||||
|
|
||||||
- name: Sync package.json version
|
|
||||||
run: |
|
|
||||||
VERSION="${{ steps.version.outputs.version_number }}"
|
|
||||||
echo "Syncing package.json to version ${VERSION}..."
|
|
||||||
npm version ${VERSION} --no-git-tag-version --allow-same-version
|
|
||||||
echo "package.json version: $(grep '"version"' package.json | head -1)"
|
|
||||||
|
|
||||||
- name: Create npm package
|
|
||||||
run: |
|
|
||||||
echo "Creating npm package..."
|
|
||||||
npm pack
|
|
||||||
echo ""
|
|
||||||
echo "Package created:"
|
|
||||||
ls -lh *.tgz
|
|
||||||
|
|
||||||
- name: Test local installation
|
|
||||||
run: |
|
|
||||||
echo "Testing local package installation..."
|
|
||||||
PACKAGE_FILE=$(ls *.tgz)
|
|
||||||
npm install -g ${PACKAGE_FILE}
|
|
||||||
echo ""
|
|
||||||
echo "Testing nupst command:"
|
|
||||||
nupst --version || echo "Note: Binary execution may fail in CI environment"
|
|
||||||
echo ""
|
|
||||||
echo "Checking installed files:"
|
|
||||||
npm ls -g @serve.zone/nupst || true
|
|
||||||
|
|
||||||
- name: Publish to npm
|
|
||||||
env:
|
|
||||||
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
|
|
||||||
run: |
|
|
||||||
echo "Publishing to npm registry..."
|
|
||||||
npm publish --access public
|
|
||||||
echo ""
|
|
||||||
echo "✅ Successfully published @serve.zone/nupst to npm!"
|
|
||||||
echo ""
|
|
||||||
echo "Package info:"
|
|
||||||
npm view @serve.zone/nupst
|
|
||||||
|
|
||||||
- name: Verify npm package
|
|
||||||
run: |
|
|
||||||
echo "Waiting for npm propagation..."
|
|
||||||
sleep 30
|
|
||||||
echo ""
|
|
||||||
echo "Verifying published package..."
|
|
||||||
npm view @serve.zone/nupst
|
|
||||||
echo ""
|
|
||||||
echo "Testing installation from npm:"
|
|
||||||
npm install -g @serve.zone/nupst
|
|
||||||
echo ""
|
|
||||||
echo "Package installed successfully!"
|
|
||||||
which nupst || echo "Binary location check skipped"
|
|
||||||
|
|
||||||
- name: Publish Summary
|
|
||||||
run: |
|
|
||||||
echo "================================================"
|
|
||||||
echo " npm Publish Complete!"
|
|
||||||
echo "================================================"
|
|
||||||
echo ""
|
|
||||||
echo "✅ Package: @serve.zone/nupst"
|
|
||||||
echo "✅ Version: ${{ steps.version.outputs.version }}"
|
|
||||||
echo ""
|
|
||||||
echo "Installation:"
|
|
||||||
echo " npm install -g @serve.zone/nupst"
|
|
||||||
echo ""
|
|
||||||
echo "Registry:"
|
|
||||||
echo " https://www.npmjs.com/package/@serve.zone/nupst"
|
|
||||||
echo ""
|
|
||||||
@@ -8,6 +8,8 @@ on:
|
|||||||
jobs:
|
jobs:
|
||||||
build-and-release:
|
build-and-release:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
container:
|
||||||
|
image: code.foss.global/host.today/ht-docker-node:latest
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout code
|
- name: Checkout code
|
||||||
@@ -20,6 +22,17 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
deno-version: v2.x
|
deno-version: v2.x
|
||||||
|
|
||||||
|
- name: Set up Node.js
|
||||||
|
uses: actions/setup-node@v4
|
||||||
|
with:
|
||||||
|
node-version: '22'
|
||||||
|
|
||||||
|
- name: Enable corepack
|
||||||
|
run: corepack enable
|
||||||
|
|
||||||
|
- name: Install dependencies
|
||||||
|
run: pnpm install --ignore-scripts
|
||||||
|
|
||||||
- name: Get version from tag
|
- name: Get version from tag
|
||||||
id: version
|
id: version
|
||||||
run: |
|
run: |
|
||||||
@@ -41,57 +54,7 @@ jobs:
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
- name: Compile binaries for all platforms
|
- name: Compile binaries for all platforms
|
||||||
run: |
|
run: mkdir -p dist/binaries && npx tsdeno compile
|
||||||
echo "================================================"
|
|
||||||
echo " NUPST Release Compilation"
|
|
||||||
echo " Version: ${{ steps.version.outputs.version }}"
|
|
||||||
echo "================================================"
|
|
||||||
echo ""
|
|
||||||
|
|
||||||
# Clean up old binaries and create fresh directory
|
|
||||||
rm -rf dist/binaries
|
|
||||||
mkdir -p dist/binaries
|
|
||||||
echo "→ Cleaned old binaries from dist/binaries"
|
|
||||||
echo ""
|
|
||||||
|
|
||||||
# Linux x86_64
|
|
||||||
echo "→ Compiling for Linux x86_64..."
|
|
||||||
deno compile --allow-all --no-check \
|
|
||||||
--output dist/binaries/nupst-linux-x64 \
|
|
||||||
--target x86_64-unknown-linux-gnu mod.ts
|
|
||||||
echo " ✓ Linux x86_64 complete"
|
|
||||||
|
|
||||||
# Linux ARM64
|
|
||||||
echo "→ Compiling for Linux ARM64..."
|
|
||||||
deno compile --allow-all --no-check \
|
|
||||||
--output dist/binaries/nupst-linux-arm64 \
|
|
||||||
--target aarch64-unknown-linux-gnu mod.ts
|
|
||||||
echo " ✓ Linux ARM64 complete"
|
|
||||||
|
|
||||||
# macOS x86_64
|
|
||||||
echo "→ Compiling for macOS x86_64..."
|
|
||||||
deno compile --allow-all --no-check \
|
|
||||||
--output dist/binaries/nupst-macos-x64 \
|
|
||||||
--target x86_64-apple-darwin mod.ts
|
|
||||||
echo " ✓ macOS x86_64 complete"
|
|
||||||
|
|
||||||
# macOS ARM64
|
|
||||||
echo "→ Compiling for macOS ARM64..."
|
|
||||||
deno compile --allow-all --no-check \
|
|
||||||
--output dist/binaries/nupst-macos-arm64 \
|
|
||||||
--target aarch64-apple-darwin mod.ts
|
|
||||||
echo " ✓ macOS ARM64 complete"
|
|
||||||
|
|
||||||
# Windows x86_64
|
|
||||||
echo "→ Compiling for Windows x86_64..."
|
|
||||||
deno compile --allow-all --no-check \
|
|
||||||
--output dist/binaries/nupst-windows-x64.exe \
|
|
||||||
--target x86_64-pc-windows-msvc mod.ts
|
|
||||||
echo " ✓ Windows x86_64 complete"
|
|
||||||
|
|
||||||
echo ""
|
|
||||||
echo "All binaries compiled successfully!"
|
|
||||||
ls -lh dist/binaries/
|
|
||||||
|
|
||||||
- name: Generate SHA256 checksums
|
- name: Generate SHA256 checksums
|
||||||
run: |
|
run: |
|
||||||
@@ -105,7 +68,6 @@ jobs:
|
|||||||
run: |
|
run: |
|
||||||
VERSION="${{ steps.version.outputs.version }}"
|
VERSION="${{ steps.version.outputs.version }}"
|
||||||
|
|
||||||
# Check if CHANGELOG.md exists
|
|
||||||
if [ ! -f CHANGELOG.md ]; then
|
if [ ! -f CHANGELOG.md ]; then
|
||||||
echo "No CHANGELOG.md found, using default release notes"
|
echo "No CHANGELOG.md found, using default release notes"
|
||||||
cat > /tmp/release_notes.md << EOF
|
cat > /tmp/release_notes.md << EOF
|
||||||
@@ -133,8 +95,6 @@ jobs:
|
|||||||
SHA256 checksums are provided in SHA256SUMS.txt
|
SHA256 checksums are provided in SHA256SUMS.txt
|
||||||
EOF
|
EOF
|
||||||
else
|
else
|
||||||
# Try to extract section for this version from CHANGELOG.md
|
|
||||||
# This is a simple extraction - adjust based on your CHANGELOG format
|
|
||||||
awk "/## \[$VERSION\]/,/## \[/" CHANGELOG.md | sed '$d' > /tmp/release_notes.md || cat > /tmp/release_notes.md << EOF
|
awk "/## \[$VERSION\]/,/## \[/" CHANGELOG.md | sed '$d' > /tmp/release_notes.md || cat > /tmp/release_notes.md << EOF
|
||||||
## NUPST $VERSION
|
## NUPST $VERSION
|
||||||
|
|
||||||
@@ -158,7 +118,6 @@ jobs:
|
|||||||
|
|
||||||
echo "Checking for existing release $VERSION..."
|
echo "Checking for existing release $VERSION..."
|
||||||
|
|
||||||
# Try to get existing release by tag
|
|
||||||
EXISTING_RELEASE_ID=$(curl -s \
|
EXISTING_RELEASE_ID=$(curl -s \
|
||||||
-H "Authorization: token ${{ secrets.GITHUB_TOKEN }}" \
|
-H "Authorization: token ${{ secrets.GITHUB_TOKEN }}" \
|
||||||
"https://code.foss.global/api/v1/repos/serve.zone/nupst/releases/tags/$VERSION" \
|
"https://code.foss.global/api/v1/repos/serve.zone/nupst/releases/tags/$VERSION" \
|
||||||
@@ -178,9 +137,7 @@ jobs:
|
|||||||
- name: Create Gitea Release
|
- name: Create Gitea Release
|
||||||
run: |
|
run: |
|
||||||
VERSION="${{ steps.version.outputs.version }}"
|
VERSION="${{ steps.version.outputs.version }}"
|
||||||
RELEASE_NOTES=$(cat /tmp/release_notes.md)
|
|
||||||
|
|
||||||
# Create the release
|
|
||||||
echo "Creating release for $VERSION..."
|
echo "Creating release for $VERSION..."
|
||||||
RELEASE_ID=$(curl -X POST -s \
|
RELEASE_ID=$(curl -X POST -s \
|
||||||
-H "Authorization: token ${{ secrets.GITHUB_TOKEN }}" \
|
-H "Authorization: token ${{ secrets.GITHUB_TOKEN }}" \
|
||||||
@@ -196,7 +153,6 @@ jobs:
|
|||||||
|
|
||||||
echo "Release created with ID: $RELEASE_ID"
|
echo "Release created with ID: $RELEASE_ID"
|
||||||
|
|
||||||
# Upload binaries as release assets
|
|
||||||
for binary in dist/binaries/*; do
|
for binary in dist/binaries/*; do
|
||||||
filename=$(basename "$binary")
|
filename=$(basename "$binary")
|
||||||
echo "Uploading $filename..."
|
echo "Uploading $filename..."
|
||||||
@@ -213,12 +169,10 @@ jobs:
|
|||||||
run: |
|
run: |
|
||||||
echo "Cleaning up old releases (keeping only last 3)..."
|
echo "Cleaning up old releases (keeping only last 3)..."
|
||||||
|
|
||||||
# Fetch all releases sorted by creation date
|
|
||||||
RELEASES=$(curl -s -H "Authorization: token ${{ secrets.GITHUB_TOKEN }}" \
|
RELEASES=$(curl -s -H "Authorization: token ${{ secrets.GITHUB_TOKEN }}" \
|
||||||
"https://code.foss.global/api/v1/repos/serve.zone/nupst/releases" | \
|
"https://code.foss.global/api/v1/repos/serve.zone/nupst/releases" | \
|
||||||
jq -r 'sort_by(.created_at) | reverse | .[3:] | .[].id')
|
jq -r 'sort_by(.created_at) | reverse | .[3:] | .[].id')
|
||||||
|
|
||||||
# Delete old releases
|
|
||||||
if [ -n "$RELEASES" ]; then
|
if [ -n "$RELEASES" ]; then
|
||||||
echo "Found releases to delete:"
|
echo "Found releases to delete:"
|
||||||
for release_id in $RELEASES; do
|
for release_id in $RELEASES; do
|
||||||
|
|||||||
14
changelog.md
14
changelog.md
@@ -1,5 +1,19 @@
|
|||||||
# Changelog
|
# Changelog
|
||||||
|
|
||||||
|
## 2026-03-18 - 5.3.3 - fix(deps)
|
||||||
|
add @git.zone/tsdeno as a development dependency
|
||||||
|
|
||||||
|
- Adds @git.zone/tsdeno@^1.2.0 to devDependencies in package.json.
|
||||||
|
|
||||||
|
## 2026-03-18 - 5.3.2 - fix(build)
|
||||||
|
replace manual release compilation workflows with tsdeno-based build configuration
|
||||||
|
|
||||||
|
- removes obsolete CI and npm publish workflows
|
||||||
|
- switches the Deno compile task to use tsdeno
|
||||||
|
- adds reusable multi-platform compile targets in npmextra.json
|
||||||
|
- updates the release workflow to install Node.js and pnpm before building binaries
|
||||||
|
- deletes the custom compile-all.sh script in favor of centralized build tooling
|
||||||
|
|
||||||
## 2026-03-15 - 5.3.1 - fix(cli)
|
## 2026-03-15 - 5.3.1 - fix(cli)
|
||||||
rename the update command references to upgrade across the CLI and documentation
|
rename the update command references to upgrade across the CLI and documentation
|
||||||
|
|
||||||
|
|||||||
@@ -1,12 +1,11 @@
|
|||||||
{
|
{
|
||||||
"name": "@serve.zone/nupst",
|
"name": "@serve.zone/nupst",
|
||||||
"version": "5.3.1",
|
"version": "5.3.3",
|
||||||
"exports": "./mod.ts",
|
"exports": "./mod.ts",
|
||||||
"nodeModulesDir": "auto",
|
"nodeModulesDir": "auto",
|
||||||
"tasks": {
|
"tasks": {
|
||||||
"dev": "deno run --allow-all mod.ts",
|
"dev": "deno run --allow-all mod.ts",
|
||||||
"compile": "deno task compile:all",
|
"compile": "tsdeno compile",
|
||||||
"compile:all": "bash scripts/compile-all.sh",
|
|
||||||
"test": "deno test --allow-all test/",
|
"test": "deno test --allow-all test/",
|
||||||
"test:watch": "deno test --allow-all --watch test/",
|
"test:watch": "deno test --allow-all --watch test/",
|
||||||
"check": "deno check mod.ts",
|
"check": "deno check mod.ts",
|
||||||
|
|||||||
@@ -16,5 +16,49 @@
|
|||||||
"license": "MIT"
|
"license": "MIT"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
"@git.zone/tsdeno": {
|
||||||
|
"compileTargets": [
|
||||||
|
{
|
||||||
|
"name": "nupst-linux-x64",
|
||||||
|
"entryPoint": "mod.ts",
|
||||||
|
"outDir": "dist/binaries",
|
||||||
|
"target": "x86_64-unknown-linux-gnu",
|
||||||
|
"permissions": ["--allow-all"],
|
||||||
|
"noCheck": true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "nupst-linux-arm64",
|
||||||
|
"entryPoint": "mod.ts",
|
||||||
|
"outDir": "dist/binaries",
|
||||||
|
"target": "aarch64-unknown-linux-gnu",
|
||||||
|
"permissions": ["--allow-all"],
|
||||||
|
"noCheck": true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "nupst-macos-x64",
|
||||||
|
"entryPoint": "mod.ts",
|
||||||
|
"outDir": "dist/binaries",
|
||||||
|
"target": "x86_64-apple-darwin",
|
||||||
|
"permissions": ["--allow-all"],
|
||||||
|
"noCheck": true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "nupst-macos-arm64",
|
||||||
|
"entryPoint": "mod.ts",
|
||||||
|
"outDir": "dist/binaries",
|
||||||
|
"target": "aarch64-apple-darwin",
|
||||||
|
"permissions": ["--allow-all"],
|
||||||
|
"noCheck": true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "nupst-windows-x64",
|
||||||
|
"entryPoint": "mod.ts",
|
||||||
|
"outDir": "dist/binaries",
|
||||||
|
"target": "x86_64-pc-windows-msvc",
|
||||||
|
"permissions": ["--allow-all"],
|
||||||
|
"noCheck": true
|
||||||
|
}
|
||||||
|
]
|
||||||
|
},
|
||||||
"@ship.zone/szci": {}
|
"@ship.zone/szci": {}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "@serve.zone/nupst",
|
"name": "@serve.zone/nupst",
|
||||||
"version": "5.3.1",
|
"version": "5.3.3",
|
||||||
"description": "Network UPS Shutdown Tool - Monitor SNMP-enabled UPS devices and orchestrate graceful system shutdowns during power emergencies",
|
"description": "Network UPS Shutdown Tool - Monitor SNMP-enabled UPS devices and orchestrate graceful system shutdowns during power emergencies",
|
||||||
"keywords": [
|
"keywords": [
|
||||||
"ups",
|
"ups",
|
||||||
@@ -62,5 +62,8 @@
|
|||||||
"access": "public",
|
"access": "public",
|
||||||
"registry": "https://registry.npmjs.org/"
|
"registry": "https://registry.npmjs.org/"
|
||||||
},
|
},
|
||||||
"packageManager": "pnpm@10.18.1+sha512.77a884a165cbba2d8d1c19e3b4880eee6d2fcabd0d879121e282196b80042351d5eb3ca0935fa599da1dc51265cc68816ad2bddd2a2de5ea9fdf92adbec7cd34"
|
"packageManager": "pnpm@10.18.1+sha512.77a884a165cbba2d8d1c19e3b4880eee6d2fcabd0d879121e282196b80042351d5eb3ca0935fa599da1dc51265cc68816ad2bddd2a2de5ea9fdf92adbec7cd34",
|
||||||
|
"devDependencies": {
|
||||||
|
"@git.zone/tsdeno": "^1.2.0"
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
2324
pnpm-lock.yaml
generated
Normal file
2324
pnpm-lock.yaml
generated
Normal file
File diff suppressed because it is too large
Load Diff
@@ -1,66 +0,0 @@
|
|||||||
#!/bin/bash
|
|
||||||
set -e
|
|
||||||
|
|
||||||
# Get version from deno.json
|
|
||||||
VERSION=$(cat deno.json | grep -o '"version": *"[^"]*"' | cut -d'"' -f4)
|
|
||||||
BINARY_DIR="dist/binaries"
|
|
||||||
|
|
||||||
echo "================================================"
|
|
||||||
echo " NUPST Compilation Script"
|
|
||||||
echo " Version: ${VERSION}"
|
|
||||||
echo "================================================"
|
|
||||||
echo ""
|
|
||||||
echo "Compiling for all supported platforms..."
|
|
||||||
echo ""
|
|
||||||
|
|
||||||
# Clean up old binaries and create fresh directory
|
|
||||||
rm -rf "$BINARY_DIR"
|
|
||||||
mkdir -p "$BINARY_DIR"
|
|
||||||
echo "→ Cleaned old binaries from $BINARY_DIR"
|
|
||||||
echo ""
|
|
||||||
|
|
||||||
# Linux x86_64
|
|
||||||
echo "→ Compiling for Linux x86_64..."
|
|
||||||
deno compile --allow-all --no-check --output "$BINARY_DIR/nupst-linux-x64" \
|
|
||||||
--target x86_64-unknown-linux-gnu mod.ts
|
|
||||||
echo " ✓ Linux x86_64 complete"
|
|
||||||
echo ""
|
|
||||||
|
|
||||||
# Linux ARM64
|
|
||||||
echo "→ Compiling for Linux ARM64..."
|
|
||||||
deno compile --allow-all --no-check --output "$BINARY_DIR/nupst-linux-arm64" \
|
|
||||||
--target aarch64-unknown-linux-gnu mod.ts
|
|
||||||
echo " ✓ Linux ARM64 complete"
|
|
||||||
echo ""
|
|
||||||
|
|
||||||
# macOS x86_64
|
|
||||||
echo "→ Compiling for macOS x86_64..."
|
|
||||||
deno compile --allow-all --no-check --output "$BINARY_DIR/nupst-macos-x64" \
|
|
||||||
--target x86_64-apple-darwin mod.ts
|
|
||||||
echo " ✓ macOS x86_64 complete"
|
|
||||||
echo ""
|
|
||||||
|
|
||||||
# macOS ARM64
|
|
||||||
echo "→ Compiling for macOS ARM64..."
|
|
||||||
deno compile --allow-all --no-check --output "$BINARY_DIR/nupst-macos-arm64" \
|
|
||||||
--target aarch64-apple-darwin mod.ts
|
|
||||||
echo " ✓ macOS ARM64 complete"
|
|
||||||
echo ""
|
|
||||||
|
|
||||||
# Windows x86_64
|
|
||||||
echo "→ Compiling for Windows x86_64..."
|
|
||||||
deno compile --allow-all --no-check --output "$BINARY_DIR/nupst-windows-x64.exe" \
|
|
||||||
--target x86_64-pc-windows-msvc mod.ts
|
|
||||||
echo " ✓ Windows x86_64 complete"
|
|
||||||
echo ""
|
|
||||||
|
|
||||||
echo "================================================"
|
|
||||||
echo " Compilation Summary"
|
|
||||||
echo "================================================"
|
|
||||||
echo ""
|
|
||||||
ls -lh "$BINARY_DIR/" | tail -n +2
|
|
||||||
echo ""
|
|
||||||
echo "✓ All binaries compiled successfully!"
|
|
||||||
echo ""
|
|
||||||
echo "Binary location: $BINARY_DIR/"
|
|
||||||
echo ""
|
|
||||||
@@ -3,6 +3,6 @@
|
|||||||
*/
|
*/
|
||||||
export const commitinfo = {
|
export const commitinfo = {
|
||||||
name: '@serve.zone/nupst',
|
name: '@serve.zone/nupst',
|
||||||
version: '5.3.1',
|
version: '5.3.3',
|
||||||
description: 'Network UPS Shutdown Tool - Monitor SNMP-enabled UPS devices and orchestrate graceful system shutdowns during power emergencies'
|
description: 'Network UPS Shutdown Tool - Monitor SNMP-enabled UPS devices and orchestrate graceful system shutdowns during power emergencies'
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user