chore: import upstream snapshot with attribution
Build and Push Docker Images / create_manifest (web, surfsense-web, , cpu) (push) Has been cancelled
Build and Push Docker Images / finalize_release (push) Has been cancelled
Obsidian Plugin Lint / lint (push) Has been cancelled
Build and Push Docker Images / build (./surfsense_web, cpu, ./surfsense_web/Dockerfile, web, surfsense-web, ubuntu-24.04-arm, linux/arm64, arm64, , runner, false, cpu) (push) Has been cancelled
Build and Push Docker Images / build (./surfsense_web, cpu, ./surfsense_web/Dockerfile, web, surfsense-web, ubuntu-latest, linux/amd64, amd64, , runner, false, cpu) (push) Has been cancelled
Build and Push Docker Images / compute_version (push) Has been cancelled
Build and Push Docker Images / build (./surfsense_backend, cpu, ./surfsense_backend/Dockerfile, backend, surfsense-backend, ubuntu-24.04-arm, linux/arm64, arm64, , production, false, cpu) (push) Has been cancelled
Build and Push Docker Images / build (./surfsense_backend, cpu, ./surfsense_backend/Dockerfile, backend, surfsense-backend, ubuntu-latest, linux/amd64, amd64, , production, false, cpu) (push) Has been cancelled
Build and Push Docker Images / build (./surfsense_backend, cu126, ./surfsense_backend/Dockerfile, backend, surfsense-backend, ubuntu-24.04-arm, linux/arm64, arm64, -cuda126, production, true, cuda126) (push) Has been cancelled
Build and Push Docker Images / build (./surfsense_backend, cu126, ./surfsense_backend/Dockerfile, backend, surfsense-backend, ubuntu-latest, linux/amd64, amd64, -cuda126, production, true, cuda126) (push) Has been cancelled
Build and Push Docker Images / build (./surfsense_backend, cu128, ./surfsense_backend/Dockerfile, backend, surfsense-backend, ubuntu-24.04-arm, linux/arm64, arm64, -cuda, production, true, cuda) (push) Has been cancelled
Build and Push Docker Images / build (./surfsense_backend, cu128, ./surfsense_backend/Dockerfile, backend, surfsense-backend, ubuntu-latest, linux/amd64, amd64, -cuda, production, true, cuda) (push) Has been cancelled
Build and Push Docker Images / verify_digests (push) Has been cancelled
Build and Push Docker Images / create_manifest (backend, surfsense-backend, , cpu) (push) Has been cancelled
Build and Push Docker Images / create_manifest (backend, surfsense-backend, -cuda, cuda) (push) Has been cancelled
Build and Push Docker Images / create_manifest (backend, surfsense-backend, -cuda126, cuda126) (push) Has been cancelled

This commit is contained in:
wehub-resource-sync
2026-07-13 13:33:44 +08:00
commit 6ede33ccdb
3841 changed files with 594049 additions and 0 deletions
+82
View File
@@ -0,0 +1,82 @@
$ErrorActionPreference = "Stop"
$RepoRoot = (Resolve-Path "$PSScriptRoot\..").Path
$VersionFile = Join-Path $RepoRoot "VERSION"
if (-not (Test-Path $VersionFile)) {
Write-Error "VERSION file not found at $VersionFile"
exit 1
}
$Version = (Get-Content $VersionFile -Raw).Trim()
if ($Version -notmatch '^\d+\.\d+\.\d+(-[a-zA-Z0-9.]+)?$') {
Write-Error "'$Version' is not valid semver (expected X.Y.Z)"
exit 1
}
Write-Host "Bumping all packages to $Version"
Write-Host "---------------------------------"
function Bump-Json {
param([string]$File)
if (-not (Test-Path $File)) {
Write-Host " SKIP $File (not found)"
return
}
$content = Get-Content $File -Raw
$match = [regex]::Match($content, '"version"\s*:\s*"([^"]*)"')
if (-not $match.Success) {
Write-Host " SKIP $File (no version field found)"
return
}
$old = $match.Groups[1].Value
if ($old -eq $Version) {
Write-Host " OK $File ($old -- already up to date)"
} else {
$content = $content -replace [regex]::Escape("`"version`": `"$old`""), "`"version`": `"$Version`""
Set-Content $File -Value $content -NoNewline
Write-Host " SET $File ($old -> $Version)"
}
}
function Bump-Toml {
param([string]$File)
if (-not (Test-Path $File)) {
Write-Host " SKIP $File (not found)"
return
}
$content = Get-Content $File -Raw
$match = [regex]::Match($content, '(?m)^version\s*=\s*"([^"]*)"')
if (-not $match.Success) {
Write-Host " SKIP $File (no version field found)"
return
}
$old = $match.Groups[1].Value
if ($old -eq $Version) {
Write-Host " OK $File ($old -- already up to date)"
} else {
$content = $content -replace ('(?m)^version\s*=\s*"' + [regex]::Escape($old) + '"'), "version = `"$Version`""
Set-Content $File -Value $content -NoNewline
Write-Host " SET $File ($old -> $Version)"
}
}
Bump-Json (Join-Path $RepoRoot "surfsense_web\package.json")
Bump-Json (Join-Path $RepoRoot "surfsense_browser_extension\package.json")
Bump-Json (Join-Path $RepoRoot "surfsense_desktop\package.json")
Bump-Toml (Join-Path $RepoRoot "surfsense_backend\pyproject.toml")
Write-Host ""
Write-Host "Syncing lock files..."
if (Get-Command uv -ErrorAction SilentlyContinue) {
Push-Location (Join-Path $RepoRoot "surfsense_backend")
uv lock
Pop-Location
Write-Host " OK surfsense_backend/uv.lock"
} else {
Write-Host " SKIP uv not found -- run 'uv lock' in surfsense_backend/ manually"
}
Write-Host "---------------------------------"
Write-Host "Done. All packages set to $Version"
+69
View File
@@ -0,0 +1,69 @@
#!/usr/bin/env bash
set -euo pipefail
REPO_ROOT="$(cd "$(dirname "$0")/.." && pwd)"
VERSION_FILE="$REPO_ROOT/VERSION"
if [ ! -f "$VERSION_FILE" ]; then
echo "ERROR: VERSION file not found at $VERSION_FILE" >&2
exit 1
fi
VERSION="$(tr -d '[:space:]' < "$VERSION_FILE")"
if ! echo "$VERSION" | grep -qE '^[0-9]+\.[0-9]+\.[0-9]+(-[a-zA-Z0-9.]+)?$'; then
echo "ERROR: '$VERSION' is not valid semver (expected X.Y.Z)" >&2
exit 1
fi
echo "Bumping all packages to $VERSION"
echo "---------------------------------"
bump_json() {
local file="$1"
if [ ! -f "$file" ]; then
echo " SKIP $file (not found)"
return
fi
local old
old="$(sed -n 's/.*"version"[[:space:]]*:[[:space:]]*"\([^"]*\)".*/\1/p' "$file" | head -1)"
if [ "$old" = "$VERSION" ]; then
echo " OK $file ($old -- already up to date)"
else
sed -i "s/\"version\": \"$old\"/\"version\": \"$VERSION\"/" "$file"
echo " SET $file ($old -> $VERSION)"
fi
}
bump_toml() {
local file="$1"
if [ ! -f "$file" ]; then
echo " SKIP $file (not found)"
return
fi
local old
old="$(sed -n 's/^version[[:space:]]*=[[:space:]]*"\([^"]*\)".*/\1/p' "$file" | head -1)"
if [ "$old" = "$VERSION" ]; then
echo " OK $file ($old -- already up to date)"
else
sed -i "s/^version = \"$old\"/version = \"$VERSION\"/" "$file"
echo " SET $file ($old -> $VERSION)"
fi
}
bump_json "$REPO_ROOT/surfsense_web/package.json"
bump_json "$REPO_ROOT/surfsense_browser_extension/package.json"
bump_json "$REPO_ROOT/surfsense_desktop/package.json"
bump_toml "$REPO_ROOT/surfsense_backend/pyproject.toml"
echo ""
echo "Syncing lock files..."
if command -v uv &>/dev/null; then
(cd "$REPO_ROOT/surfsense_backend" && uv lock)
echo " OK surfsense_backend/uv.lock"
else
echo " SKIP uv not found -- run 'uv lock' in surfsense_backend/ manually"
fi
echo "---------------------------------"
echo "Done. All packages set to $VERSION"