mirror of
https://github.com/Noratrieb/vps.git
synced 2026-01-18 02:25:09 +01:00
Compare commits
No commits in common. "06b0de2840fde8d2960990c73eaf224ef3ef5390" and "cc7832141758cb432e3126d1c2135299ae247eea" have entirely different histories.
06b0de2840
...
cc78321417
4 changed files with 9 additions and 50 deletions
|
|
@ -1,9 +1,6 @@
|
||||||
{
|
{
|
||||||
meta =
|
meta =
|
||||||
let
|
let nixpkgs-path = (fetchTarball "https://github.com/NixOS/nixpkgs/archive/7105ae3957700a9646cc4b766f5815b23ed0c682.tar.gz"); in
|
||||||
my-projects-versions = builtins.fromJSON (builtins.readFile ./my-projects.json);
|
|
||||||
nixpkgs-path = (fetchTarball "https://github.com/NixOS/nixpkgs/archive/7105ae3957700a9646cc4b766f5815b23ed0c682.tar.gz");
|
|
||||||
in
|
|
||||||
{
|
{
|
||||||
# Override to pin the Nixpkgs version (recommended). This option
|
# Override to pin the Nixpkgs version (recommended). This option
|
||||||
# accepts one of the following:
|
# accepts one of the following:
|
||||||
|
|
@ -13,12 +10,14 @@
|
||||||
nixpkgs = import nixpkgs-path; # nixos-24.11 2025-03-21
|
nixpkgs = import nixpkgs-path; # nixos-24.11 2025-03-21
|
||||||
|
|
||||||
specialArgs = {
|
specialArgs = {
|
||||||
website = import (fetchTarball "https://github.com/Noratrieb/website/archive/${my-projects-versions.website}.tar.gz");
|
website = import (fetchTarball "https://github.com/Noratrieb/website/archive/57c4a239da5d17eafde4ade165f3c6706639a9b4.tar.gz");
|
||||||
blog = fetchTarball "https://github.com/Noratrieb/blog/archive/${my-projects-versions.blog}.tar.gz";
|
blog = fetchTarball "https://github.com/Noratrieb/blog/archive/04f7cf7d27db359cbf9fac2e9e3e677a7e76abd9.tar.gz";
|
||||||
slides = fetchTarball "https://github.com/Noratrieb/slides/archive/${my-projects-versions.slides}.tar.gz";
|
slides = fetchTarball "https://github.com/Noratrieb/slides/archive/0401f35c22b124b69447655f0c537badae9e223c.tar.gz";
|
||||||
pretense = import (fetchTarball "https://github.com/Noratrieb/pretense/archive/${my-projects-versions.pretense}.tar.gz");
|
|
||||||
quotdd = import (fetchTarball "https://github.com/Noratrieb/quotdd/archive/${my-projects-versions.quotdd}.tar.gz");
|
pretense = import (fetchTarball "https://github.com/Noratrieb/pretense/archive/270b01fc1118dfd713c1c41530d1a7d98f04527d.tar.gz");
|
||||||
does-it-build = import (fetchTarball "https://github.com/Noratrieb/does-it-build/archive/${my-projects-versions.does-it-build}.tar.gz");
|
quotdd = import (fetchTarball "https://github.com/Noratrieb/quotdd/archive/9c37b3e2093020771ee7c9da6200f95d4269b4e4.tar.gz");
|
||||||
|
|
||||||
|
does-it-build = import (fetchTarball "https://github.com/Noratrieb/does-it-build/archive/79bb6d1eb06d47db7d59829cd6cce247d223a960.tar.gz");
|
||||||
|
|
||||||
inherit nixpkgs-path;
|
inherit nixpkgs-path;
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,8 +0,0 @@
|
||||||
{
|
|
||||||
"website": "57c4a239da5d17eafde4ade165f3c6706639a9b4",
|
|
||||||
"blog": "ea2758dd10f29e8d66ca3f54d7303f2ac20005d2",
|
|
||||||
"slides": "0401f35c22b124b69447655f0c537badae9e223c",
|
|
||||||
"pretense": "270b01fc1118dfd713c1c41530d1a7d98f04527d",
|
|
||||||
"quotdd": "e922229e1d9e055be35dabd112bafc87a0686548",
|
|
||||||
"does-it-build": "5ec24bbfaf39edd60865b2879107835b99e133d0"
|
|
||||||
}
|
|
||||||
|
|
@ -1,31 +0,0 @@
|
||||||
import fs from "node:fs/promises";
|
|
||||||
|
|
||||||
const path = `${import.meta.dirname}/nix/my-projects.json`;
|
|
||||||
const projects = JSON.parse(await fs.readFile(path));
|
|
||||||
|
|
||||||
let hasChanges = false;
|
|
||||||
|
|
||||||
for (const [name, commit] of Object.entries(projects)) {
|
|
||||||
const res = await fetch(
|
|
||||||
`https://api.github.com/repos/Noratrieb/${name}/commits/HEAD`
|
|
||||||
);
|
|
||||||
if (!res.ok) {
|
|
||||||
throw new Error(
|
|
||||||
`get commit for ${name}: ${res.status} - ${await res.text()}`
|
|
||||||
);
|
|
||||||
}
|
|
||||||
const body = await res.json();
|
|
||||||
const latestCommit = body.sha;
|
|
||||||
|
|
||||||
if (commit !== latestCommit) {
|
|
||||||
console.log(
|
|
||||||
`${name} changed from ${commit} -> ${latestCommit} (${body.commit.message})`
|
|
||||||
);
|
|
||||||
projects[name] = latestCommit;
|
|
||||||
hasChanges = true;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
if (hasChanges) {
|
|
||||||
await fs.writeFile(path, JSON.stringify(projects, null, 2) + "\n");
|
|
||||||
}
|
|
||||||
|
|
@ -14,7 +14,6 @@
|
||||||
wireguard-tools
|
wireguard-tools
|
||||||
python311Packages.zstandard
|
python311Packages.zstandard
|
||||||
python311Packages.brotli
|
python311Packages.brotli
|
||||||
nodejs
|
|
||||||
(import (builtins.fetchTarball "https://github.com/ryantm/agenix/archive/531beac616433bac6f9e2a19feb8e99a22a66baf.tar.gz") { }).agenix
|
(import (builtins.fetchTarball "https://github.com/ryantm/agenix/archive/531beac616433bac6f9e2a19feb8e99a22a66baf.tar.gz") { }).agenix
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue