update to 25.05

This commit is contained in:
nora 2025-08-03 14:03:46 +02:00
parent d8a05d949a
commit 9dc90dacf7
5 changed files with 32 additions and 4 deletions

View file

@ -2,8 +2,8 @@
meta = meta =
let let
my-projects-versions = builtins.fromJSON (builtins.readFile ./my-projects.json); my-projects-versions = builtins.fromJSON (builtins.readFile ./my-projects.json);
nixpkgs-hash = "50ab793786d9de88ee30ec4e4c24fb4236fc2674"; # nixos-24.11 2025-07-27 nixpkgs-version = builtins.fromJSON (builtins.readFile ./nixpkgs.json);
nixpkgs-path = (fetchTarball "https://github.com/NixOS/nixpkgs/archive/${nixpkgs-hash}.tar.gz"); nixpkgs-path = (fetchTarball "https://github.com/NixOS/nixpkgs/archive/${nixpkgs-version.commit}.tar.gz");
in in
{ {
# Override to pin the Nixpkgs version (recommended). This option # Override to pin the Nixpkgs version (recommended). This option

View file

@ -12,7 +12,7 @@
services.garage = { services.garage = {
enable = true; enable = true;
package = pkgs.garage_1_1_0; package = pkgs.garage_1_2_0;
settings = { settings = {
metadata_dir = "/var/lib/garage/meta"; metadata_dir = "/var/lib/garage/meta";
data_dir = "/var/lib/garage/data"; data_dir = "/var/lib/garage/data";

5
nix/nixpkgs.json Normal file
View file

@ -0,0 +1,5 @@
{
"channel": "nixos-25.05",
"lastUpdated": "2025-08-03T11:42:11.747Z",
"commit": "59e69648d345d6e8fef86158c555730fa12af9de"
}

View file

@ -1,6 +1,6 @@
import fs from "node:fs/promises"; import fs from "node:fs/promises";
const path = `${import.meta.dirname}/nix/my-projects.json`; const path = `${import.meta.dirname}/my-projects.json`;
const projects = JSON.parse(await fs.readFile(path)); const projects = JSON.parse(await fs.readFile(path));
let hasChanges = false; let hasChanges = false;

23
nix/update-nixpkgs.mjs Normal file
View file

@ -0,0 +1,23 @@
import fs from "node:fs/promises";
const path = `${import.meta.dirname}/nixpkgs.json`;
const nixpkgs = JSON.parse(await fs.readFile(path));
const res = await fetch(
`https://api.github.com/repos/NixOS/nixpkgs/commits/${nixpkgs.channel}`
);
if (!res.ok) {
throw new Error(
`get commit for ${name}: ${res.status} - ${await res.text()}`
);
}
const body = await res.json();
if (body.sha !== nixpkgs.commit) {
nixpkgs.commit = body.sha;
nixpkgs.lastUpdated = new Date().toISOString();
await fs.writeFile(path, JSON.stringify(nixpkgs, null, 2) + "\n");
}