oh-my-devpod 0.15.8 → 0.16.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -3,10 +3,10 @@
3
3
  This package contains the complete `oh-my-devpod` runtime bundle and exposes
4
4
  the `omd` command.
5
5
 
6
- Supported host:
6
+ Supported hosts:
7
7
 
8
- - Ubuntu 24.04
9
- - Linux x64
8
+ - Ubuntu 22.04, 24.04, and 26.04
9
+ - Linux x64 (x86_64)
10
10
  - glibc
11
11
  - Node.js 18 or newer
12
12
 
package/lib/platform.js CHANGED
@@ -1,6 +1,8 @@
1
1
  "use strict";
2
2
 
3
3
  const fs = require("node:fs");
4
+ const ubuntuVersions = ["22.04", "24.04", "26.04"];
5
+ const supportedUbuntu = "Ubuntu 22.04, 24.04, and 26.04";
4
6
 
5
7
  function parseOsRelease(contents) {
6
8
  const values = {};
@@ -50,7 +52,7 @@ function currentPlatform() {
50
52
  function validatePlatform(info) {
51
53
  if (info.platform !== "linux") {
52
54
  throw new Error(
53
- `unsupported platform ${info.platform}; oh-my-devpod requires Ubuntu 24.04 on Linux x64/glibc`,
55
+ `unsupported platform ${info.platform}; oh-my-devpod requires ${supportedUbuntu} on Linux x64/glibc`,
54
56
  );
55
57
  }
56
58
  if (info.arch !== "x64") {
@@ -66,9 +68,9 @@ function validatePlatform(info) {
66
68
 
67
69
  const id = info.osRelease.ID || "unknown";
68
70
  const version = info.osRelease.VERSION_ID || "unknown";
69
- if (id !== "ubuntu" || version !== "24.04") {
71
+ if (id !== "ubuntu" || !ubuntuVersions.includes(version)) {
70
72
  throw new Error(
71
- `unsupported Linux distribution ${id} ${version}; oh-my-devpod requires Ubuntu 24.04`,
73
+ `unsupported Linux distribution ${id} ${version}; oh-my-devpod requires ${supportedUbuntu}`,
72
74
  );
73
75
  }
74
76
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "oh-my-devpod",
3
- "version": "0.15.8",
3
+ "version": "0.16.0",
4
4
  "description": "Ubuntu productivity tool manager with the omd terminal interface",
5
5
  "license": "MIT",
6
6
  "author": "zhangdw156",
package/runtime/VERSION CHANGED
@@ -1 +1 @@
1
- 0.15.8
1
+ 0.16.0
package/runtime/bin/omd CHANGED
Binary file
@@ -23,12 +23,14 @@ omd_detect_os_release() {
23
23
  # shellcheck disable=SC1090
24
24
  source "${os_release}"
25
25
 
26
- if [[ "${ID}" == "ubuntu" && "${VERSION_ID}" == "24.04" ]]; then
27
- printf 'ubuntu-24.04\n'
28
- return 0
29
- fi
26
+ case "${ID}:${VERSION_ID}" in
27
+ ubuntu:22.04|ubuntu:24.04|ubuntu:26.04)
28
+ printf 'ubuntu-%s\n' "${VERSION_ID}"
29
+ return 0
30
+ ;;
31
+ esac
30
32
 
31
- printf 'Unsupported Linux distribution: ID=%s VERSION_ID=%s. oh-my-devpod supports Ubuntu 24.04 only.\n' \
33
+ printf 'Unsupported Linux distribution: ID=%s VERSION_ID=%s. oh-my-devpod supports Ubuntu 22.04, 24.04, and 26.04.\n' \
32
34
  "${ID:-unknown}" "${VERSION_ID:-unknown}" >&2
33
35
  return 1
34
36
  }