Compare commits
2 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
cfb91d825a | ||
|
|
a3b21f23fc |
@@ -1,3 +1,8 @@
|
|||||||
|
## [0.10.1] - 2025-12-11
|
||||||
|
|
||||||
|
* Fixed Debian\Ubuntu to pass container e2e tests
|
||||||
|
|
||||||
|
|
||||||
## [0.10.0] - 2025-12-11
|
## [0.10.0] - 2025-12-11
|
||||||
|
|
||||||
* **Changes since v0.9.1**
|
* **Changes since v0.9.1**
|
||||||
|
|||||||
@@ -36,7 +36,7 @@
|
|||||||
rec {
|
rec {
|
||||||
pkgmgr = pyPkgs.buildPythonApplication {
|
pkgmgr = pyPkgs.buildPythonApplication {
|
||||||
pname = "package-manager";
|
pname = "package-manager";
|
||||||
version = "0.10.0";
|
version = "0.10.1";
|
||||||
|
|
||||||
# Use the git repo as source
|
# Use the git repo as source
|
||||||
src = ./.;
|
src = ./.;
|
||||||
|
|||||||
@@ -7,7 +7,7 @@ build-backend = "setuptools.build_meta"
|
|||||||
|
|
||||||
[project]
|
[project]
|
||||||
name = "package-manager"
|
name = "package-manager"
|
||||||
version = "0.10.0"
|
version = "0.10.1"
|
||||||
description = "Kevin's package-manager tool (pkgmgr)"
|
description = "Kevin's package-manager tool (pkgmgr)"
|
||||||
readme = "README.md"
|
readme = "README.md"
|
||||||
requires-python = ">=3.11"
|
requires-python = ">=3.11"
|
||||||
|
|||||||
@@ -8,19 +8,18 @@ fi
|
|||||||
|
|
||||||
FLAKE_DIR="/usr/lib/package-manager"
|
FLAKE_DIR="/usr/lib/package-manager"
|
||||||
|
|
||||||
# ------------------------------------------------------------
|
# ---------------------------------------------------------------------------
|
||||||
# Try to ensure that "nix" is on PATH
|
# Try to ensure that "nix" is on PATH (common locations + container user)
|
||||||
# ------------------------------------------------------------
|
# ---------------------------------------------------------------------------
|
||||||
if ! command -v nix >/dev/null 2>&1; then
|
if ! command -v nix >/dev/null 2>&1; then
|
||||||
# Common locations for Nix installations
|
|
||||||
CANDIDATES=(
|
CANDIDATES=(
|
||||||
"/nix/var/nix/profiles/default/bin/nix"
|
"/nix/var/nix/profiles/default/bin/nix"
|
||||||
"${HOME:-/root}/.nix-profile/bin/nix"
|
"${HOME:-/root}/.nix-profile/bin/nix"
|
||||||
|
"/home/nix/.nix-profile/bin/nix"
|
||||||
)
|
)
|
||||||
|
|
||||||
for candidate in "${CANDIDATES[@]}"; do
|
for candidate in "${CANDIDATES[@]}"; do
|
||||||
if [[ -x "$candidate" ]]; then
|
if [[ -x "$candidate" ]]; then
|
||||||
# Prepend the directory of the candidate to PATH
|
|
||||||
PATH="$(dirname "$candidate"):${PATH}"
|
PATH="$(dirname "$candidate"):${PATH}"
|
||||||
export PATH
|
export PATH
|
||||||
break
|
break
|
||||||
@@ -28,13 +27,22 @@ if ! command -v nix >/dev/null 2>&1; then
|
|||||||
done
|
done
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# ------------------------------------------------------------
|
# ---------------------------------------------------------------------------
|
||||||
# Primary (and only) path: use Nix flake if available
|
# If nix is still missing, try to run init-nix.sh once
|
||||||
# ------------------------------------------------------------
|
# ---------------------------------------------------------------------------
|
||||||
|
if ! command -v nix >/dev/null 2>&1; then
|
||||||
|
if [[ -x "${FLAKE_DIR}/init-nix.sh" ]]; then
|
||||||
|
"${FLAKE_DIR}/init-nix.sh" || true
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
|
||||||
|
# ---------------------------------------------------------------------------
|
||||||
|
# Primary path: use Nix flake if available
|
||||||
|
# ---------------------------------------------------------------------------
|
||||||
if command -v nix >/dev/null 2>&1; then
|
if command -v nix >/dev/null 2>&1; then
|
||||||
exec nix run "${FLAKE_DIR}#pkgmgr" -- "$@"
|
exec nix run "${FLAKE_DIR}#pkgmgr" -- "$@"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
echo "[pkgmgr-wrapper] ERROR: 'nix' binary not found on PATH."
|
echo "[pkgmgr-wrapper] ERROR: 'nix' binary not found on PATH after init."
|
||||||
echo "[pkgmgr-wrapper] Nix is required to run pkgmgr (no Python fallback)."
|
echo "[pkgmgr-wrapper] Nix is required to run pkgmgr (no Python fallback)."
|
||||||
exit 1
|
exit 1
|
||||||
|
|||||||
Reference in New Issue
Block a user