mirror of
https://github.com/daylinmorgan/oizys.git
synced 2024-12-24 20:10:43 -06:00
Compare commits
1 commit
1c32119e0b
...
792d40b3ab
Author | SHA1 | Date | |
---|---|---|---|
792d40b3ab |
5 changed files with 58 additions and 64 deletions
21
.github/actions/clean-disk/action.yml
vendored
21
.github/actions/clean-disk/action.yml
vendored
|
@ -20,7 +20,7 @@ runs:
|
||||||
- name: Maximize build disk space
|
- name: Maximize build disk space
|
||||||
shell: bash
|
shell: bash
|
||||||
run: |
|
run: |
|
||||||
set -xeuo pipefail
|
set -euo pipefail
|
||||||
shopt -s globstar
|
shopt -s globstar
|
||||||
|
|
||||||
non_manifest_packages() {
|
non_manifest_packages() {
|
||||||
|
@ -41,23 +41,26 @@ runs:
|
||||||
sudo rm -rf \
|
sudo rm -rf \
|
||||||
/var/lib/docker/ \
|
/var/lib/docker/ \
|
||||||
"$AGENT_TOOLSDIRECTORY" \
|
"$AGENT_TOOLSDIRECTORY" \
|
||||||
/opt &
|
/opt \
|
||||||
|
/usr/local/** &
|
||||||
|
|
||||||
sudo find /usr/{share,local} \
|
find /usr/share -maxdepth -m -type d -not -name 'git-core' -delete
|
||||||
-mindepth 1 -maxdepth 1 \
|
|
||||||
-type d \
|
|
||||||
-not -wholename '/usr/share/git-core' \
|
|
||||||
-exec rm -rf {} + &
|
|
||||||
|
|
||||||
|
# for f in /usr/share/**/!(git-core); do
|
||||||
|
# sudo rm -rf $f &
|
||||||
|
# done
|
||||||
|
|
||||||
|
|
||||||
|
# nix flake update wants to find git-core templates
|
||||||
|
# /usr/share/git-core/templates
|
||||||
|
# /usr/share/**
|
||||||
{
|
{
|
||||||
sudo swapoff -a
|
sudo swapoff -a
|
||||||
sudo rm -f /mnt/swapfile
|
sudo rm -f /mnt/swapfile
|
||||||
} &
|
} &
|
||||||
|
|
||||||
wait
|
wait
|
||||||
echo "... done"
|
echo "... done"
|
||||||
|
|
||||||
|
|
||||||
- name: Disk space report after modification
|
- name: Disk space report after modification
|
||||||
shell: bash
|
shell: bash
|
||||||
run: |
|
run: |
|
||||||
|
|
2
.github/workflows/update.yml
vendored
2
.github/workflows/update.yml
vendored
|
@ -130,7 +130,7 @@ jobs:
|
||||||
- run: |
|
- run: |
|
||||||
echo "# System Diff" >> $GITHUB_STEP_SUMMARY
|
echo "# System Diff" >> $GITHUB_STEP_SUMMARY
|
||||||
nix run "nixpkgs#nvd" -- --color always diff ./current ./updated >> summary.md
|
nix run "nixpkgs#nvd" -- --color always diff ./current ./updated >> summary.md
|
||||||
printf '```\n%s\n```\n' "$(nix run "nixpkgs#nvd" -- diff ./current ./updated)" >> $GITHUB_STEP_SUMMARY
|
printf '```\n%s```\n' "$(nix run "nixpkgs#nvd" -- diff ./current ./updated)" >> $GITHUB_STEP_SUMMARY
|
||||||
|
|
||||||
- run: df -h
|
- run: df -h
|
||||||
|
|
||||||
|
|
76
flake.lock
76
flake.lock
|
@ -179,11 +179,11 @@
|
||||||
"systems": "systems_4"
|
"systems": "systems_4"
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1726560853,
|
"lastModified": 1710146030,
|
||||||
"narHash": "sha256-X6rJYSESBVr3hBoH0WbKE5KvhPU5bloyZ2L4K60/fPQ=",
|
"narHash": "sha256-SZ5L6eA7HJ/nmkzGG7/ISclqe6oZdOZTNoesiInkXPQ=",
|
||||||
"owner": "numtide",
|
"owner": "numtide",
|
||||||
"repo": "flake-utils",
|
"repo": "flake-utils",
|
||||||
"rev": "c1dfcf08411b08f6b8615f7d8971a2bfa81d5e8a",
|
"rev": "b1d9ab70662946ef0850d488da1c9019f3a9752a",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -323,11 +323,11 @@
|
||||||
"xdph": "xdph"
|
"xdph": "xdph"
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1726580240,
|
"lastModified": 1726430622,
|
||||||
"narHash": "sha256-VBXNeRJMaiqbIietRihPYnWA7bFJO2wqqlPg0f9Xfjc=",
|
"narHash": "sha256-50vt1snpVwS5lqvvH4p6DHiEWspJUZuJ1kYy1DKtrfM=",
|
||||||
"ref": "refs/heads/main",
|
"ref": "refs/heads/main",
|
||||||
"rev": "3c9716acfd00c6ea1b7bcd1dc63f97b51cc09998",
|
"rev": "9e356562446f44c471ae38a80506a9df039305d6",
|
||||||
"revCount": 5227,
|
"revCount": 5224,
|
||||||
"submodules": true,
|
"submodules": true,
|
||||||
"type": "git",
|
"type": "git",
|
||||||
"url": "https://github.com/hyprwm/Hyprland/"
|
"url": "https://github.com/hyprwm/Hyprland/"
|
||||||
|
@ -488,11 +488,11 @@
|
||||||
"nixpkgs-lib": "nixpkgs-lib"
|
"nixpkgs-lib": "nixpkgs-lib"
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1726600542,
|
"lastModified": 1726402305,
|
||||||
"narHash": "sha256-4ZP8rYtad1Z0LY3vZ1eYSRUzqPd3x7K0j7SpP3vReWc=",
|
"narHash": "sha256-Ps21x+17J0rclqg68crak2Vo/P3+1fZStqmV+OI7k6M=",
|
||||||
"owner": "nix-community",
|
"owner": "nix-community",
|
||||||
"repo": "lib-aggregate",
|
"repo": "lib-aggregate",
|
||||||
"rev": "e0cc0b05b0296fdc52fa683d47a3470dfe4f79ea",
|
"rev": "90b637e33ab9be23e0ba3c57905a1837561923ea",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -504,11 +504,11 @@
|
||||||
"lix": {
|
"lix": {
|
||||||
"flake": false,
|
"flake": false,
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1726590994,
|
"lastModified": 1726411950,
|
||||||
"narHash": "sha256-CrvIEzBzvvfE7jGIXBv6hSYDxv4eYeHWAwVho5WrF48=",
|
"narHash": "sha256-OnPGWKN3mJCsbdt4zOCVSTWg8N9QX+VTCXDcYviStTk=",
|
||||||
"rev": "8ab5743904a06c78153281bf61b3aa8aa451a489",
|
"rev": "80202e3ca314c21547c48f3a23d3f629cd9ddb87",
|
||||||
"type": "tarball",
|
"type": "tarball",
|
||||||
"url": "https://git.lix.systems/api/v1/repos/lix-project/lix/archive/8ab5743904a06c78153281bf61b3aa8aa451a489.tar.gz?rev=8ab5743904a06c78153281bf61b3aa8aa451a489"
|
"url": "https://git.lix.systems/api/v1/repos/lix-project/lix/archive/80202e3ca314c21547c48f3a23d3f629cd9ddb87.tar.gz?rev=80202e3ca314c21547c48f3a23d3f629cd9ddb87"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
"type": "tarball",
|
"type": "tarball",
|
||||||
|
@ -605,11 +605,11 @@
|
||||||
"treefmt-nix": "treefmt-nix"
|
"treefmt-nix": "treefmt-nix"
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1726529941,
|
"lastModified": 1723372011,
|
||||||
"narHash": "sha256-jj7gvddyUQ3xnZxApiGv5xQaa75f1hYKFdtOfvtkcZ0=",
|
"narHash": "sha256-zqenoufFiPfobw74idorZMG8AXG3DnFzbHplt/Nkvrg=",
|
||||||
"owner": "nix-community",
|
"owner": "nix-community",
|
||||||
"repo": "nix-eval-jobs",
|
"repo": "nix-eval-jobs",
|
||||||
"rev": "a7cdbbbd9a7755489267dfd1297c613c824a5920",
|
"rev": "8802412b8747633e9d80639897e4d58fa6290909",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -744,11 +744,11 @@
|
||||||
"nixpkgs": "nixpkgs_6"
|
"nixpkgs": "nixpkgs_6"
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1726604396,
|
"lastModified": 1726496380,
|
||||||
"narHash": "sha256-N96NVHAYUxK4L7uaeKi45a+v61VIpimzHyQsKctBpb4=",
|
"narHash": "sha256-0SPQYespqgqODDBDpdryqWDcwUOObk0NxIMUjRQ7ydY=",
|
||||||
"owner": "nix-community",
|
"owner": "nix-community",
|
||||||
"repo": "nixpkgs-wayland",
|
"repo": "nixpkgs-wayland",
|
||||||
"rev": "e2d0b0171ddf364b687d091ee603d0c3a7079166",
|
"rev": "cbe4866388730d63d98743cc884062b6374beb41",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -791,11 +791,11 @@
|
||||||
},
|
},
|
||||||
"nixpkgs_4": {
|
"nixpkgs_4": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1726463316,
|
"lastModified": 1726243404,
|
||||||
"narHash": "sha256-gI9kkaH0ZjakJOKrdjaI/VbaMEo9qBbSUl93DnU7f4c=",
|
"narHash": "sha256-sjiGsMh+1cWXb53Tecsm4skyFNag33GPbVgCdfj3n9I=",
|
||||||
"owner": "nixos",
|
"owner": "nixos",
|
||||||
"repo": "nixpkgs",
|
"repo": "nixpkgs",
|
||||||
"rev": "99dc8785f6a0adac95f5e2ab05cc2e1bf666d172",
|
"rev": "345c263f2f53a3710abe117f28a5cb86d0ba4059",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -823,11 +823,11 @@
|
||||||
},
|
},
|
||||||
"nixpkgs_6": {
|
"nixpkgs_6": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1726463316,
|
"lastModified": 1726243404,
|
||||||
"narHash": "sha256-gI9kkaH0ZjakJOKrdjaI/VbaMEo9qBbSUl93DnU7f4c=",
|
"narHash": "sha256-sjiGsMh+1cWXb53Tecsm4skyFNag33GPbVgCdfj3n9I=",
|
||||||
"owner": "nixos",
|
"owner": "nixos",
|
||||||
"repo": "nixpkgs",
|
"repo": "nixpkgs",
|
||||||
"rev": "99dc8785f6a0adac95f5e2ab05cc2e1bf666d172",
|
"rev": "345c263f2f53a3710abe117f28a5cb86d0ba4059",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -900,11 +900,11 @@
|
||||||
"rust-overlay": "rust-overlay"
|
"rust-overlay": "rust-overlay"
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1726567229,
|
"lastModified": 1726359326,
|
||||||
"narHash": "sha256-5BfrNDZBwiG0dN09V7Skd5Bpr2HwVMCdDWOvneQ2iZ4=",
|
"narHash": "sha256-Nt7Ywk1lO6S4jLv9CYg7HN9nOhmgV79uUiSLWXA4fPE=",
|
||||||
"owner": "roc-lang",
|
"owner": "roc-lang",
|
||||||
"repo": "roc",
|
"repo": "roc",
|
||||||
"rev": "3215a8f3d73daf881185e4f7474972f2059754b6",
|
"rev": "7df11424550bb7955a178190a3b341e34d184a19",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -1112,11 +1112,11 @@
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"dir": "nix",
|
"dir": "nix",
|
||||||
"lastModified": 1726527644,
|
"lastModified": 1726326914,
|
||||||
"narHash": "sha256-WAruDParTj7AY16SNjTDPgXf54vJCQRpRAiED3x9FIM=",
|
"narHash": "sha256-QMOS1KxI1tY3Rxtpc8UkG5vLBonybjJTiNT89ENOvo0=",
|
||||||
"owner": "daylinmorgan",
|
"owner": "daylinmorgan",
|
||||||
"repo": "tsm",
|
"repo": "tsm",
|
||||||
"rev": "5991d93bcb216c4cd5345296111fee7027be29cf",
|
"rev": "8c866db5f020cbdbe9ea9123ce4b92478b41ede5",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -1184,11 +1184,11 @@
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1726575046,
|
"lastModified": 1726488713,
|
||||||
"narHash": "sha256-XD2qJ30wTLUz7BOXVz1wY/q+RJBvI7f6ksGJrYMbFAg=",
|
"narHash": "sha256-af/hZxM6+AVuap2g0sshCbIr4jr2D734JwMI+RdoVrQ=",
|
||||||
"owner": "mitchellh",
|
"owner": "mitchellh",
|
||||||
"repo": "zig-overlay",
|
"repo": "zig-overlay",
|
||||||
"rev": "a2f15c93b689b31044d5604fb0cd5bac818daf01",
|
"rev": "ff9255e02181bad3562f5f24fa27a26036a5f112",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -1209,11 +1209,11 @@
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1726516447,
|
"lastModified": 1726435403,
|
||||||
"narHash": "sha256-CV6Mr2zm5ZmtW4RnC3taJqA0tZ0U0ERzLBoO6GfzGWA=",
|
"narHash": "sha256-KB95mT5hMppNqV4uX7det1D1m5Y0rTQotjmGXYnnps0=",
|
||||||
"owner": "zigtools",
|
"owner": "zigtools",
|
||||||
"repo": "zls",
|
"repo": "zls",
|
||||||
"rev": "cf9b49a67b15693d62926ea11d17f53efc60be50",
|
"rev": "956b436a3f302d5dbc7fecfa565da666c1b2df77",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
|
|
@ -22,4 +22,3 @@ code
|
||||||
direnv
|
direnv
|
||||||
comma-with-db
|
comma-with-db
|
||||||
nix-index-with-db
|
nix-index-with-db
|
||||||
python
|
|
||||||
|
|
|
@ -147,18 +147,8 @@ proc findSystemPaths(drvs: Table[string, NixDerivation]): seq[string] =
|
||||||
|
|
||||||
assert len(hosts) == len(result)
|
assert len(hosts) == len(result)
|
||||||
|
|
||||||
|
|
||||||
proc filterSeq(
|
|
||||||
drvs: seq[string],
|
|
||||||
filter: proc(s: string): bool,
|
|
||||||
): tuple[yes: seq[string], no: seq[string]] =
|
|
||||||
for drv in drvs:
|
|
||||||
if filter(drv): result.yes.add drv
|
|
||||||
else: result.no.add drv
|
|
||||||
|
|
||||||
|
|
||||||
func isIgnored(drv: string): bool =
|
func isIgnored(drv: string): bool =
|
||||||
const ignoredPackages = (slurp "ignored.txt").strip().splitLines()
|
const ignoredPackages = (slurp "ignored.txt").splitLines()
|
||||||
let name = drv.split("-", 1)[1].replace(".drv","")
|
let name = drv.split("-", 1)[1].replace(".drv","")
|
||||||
result = name in ignoredPackages
|
result = name in ignoredPackages
|
||||||
if not result:
|
if not result:
|
||||||
|
@ -167,15 +157,17 @@ func isIgnored(drv: string): bool =
|
||||||
return true
|
return true
|
||||||
|
|
||||||
proc systemPathDrvsToBuild(): seq[string] =
|
proc systemPathDrvsToBuild(): seq[string] =
|
||||||
var inputDrvs, dropped: seq[string]
|
|
||||||
let toBuild = toBuildNixosConfiguration()
|
let toBuild = toBuildNixosConfiguration()
|
||||||
let drvs = evaluateDerivations(nixosConfigAttrs())
|
let drvs = evaluateDerivations(nixosConfigAttrs())
|
||||||
let systemPaths = findSystemPaths(drvs)
|
let systemPaths = findSystemPaths(drvs)
|
||||||
|
var inputDrvs: seq[string]
|
||||||
for p in systemPaths:
|
for p in systemPaths:
|
||||||
inputDrvs &= drvs[p].inputDrvs.keys().toSeq()
|
inputDrvs &= drvs[p].inputDrvs.keys().toSeq()
|
||||||
(result, _) = filterSeq(inputDrvs, (s) => s in toBuild)
|
result = inputDrvs.filterIt(it in toBuild)
|
||||||
(dropped, result) = filterSeq(result, isIgnored)
|
let nToBuild = result.len
|
||||||
debug fmt"ignored {dropped.len} derivations"
|
result = result.filterIt(not it.isIgnored)
|
||||||
|
let nIgnored = nToBuild - result.len
|
||||||
|
debug fmt"ignored {nIgnored} derivations"
|
||||||
result = result.mapIt(it & "^*")
|
result = result.mapIt(it & "^*")
|
||||||
|
|
||||||
func splitDrv(drv: string): tuple[name, hash:string] =
|
func splitDrv(drv: string): tuple[name, hash:string] =
|
||||||
|
|
Loading…
Reference in a new issue