Compare commits

...

9 commits

Author SHA1 Message Date
761152da52 flake.lock: Update
Flake lock file updates:

• Updated input 'ghostty':
    'git+ssh://git@github.com/ghostty-org/ghostty?ref=refs/heads/main&rev=d47df211b03894427592851b0be3b528ff8221ff' (2024-11-02)
  → 'git+ssh://git@github.com/ghostty-org/ghostty?ref=refs/heads/main&rev=960e52573b383b5d757d61e6e97b6263a5bfddd1' (2024-11-04)
• Updated input 'hyprland':
    'git+https://github.com/hyprwm/Hyprland/?ref=refs/heads/main&rev=7c7a84ff60f8c1e00c6a0de3f7656f0bbd933d56' (2024-10-30)
  → 'git+https://github.com/hyprwm/Hyprland/?ref=refs/heads/main&rev=0fb9a04526b06adfb3fd16b64e13b7d110ae7855' (2024-11-04)
• Updated input 'hyprland/nixpkgs':
    'github:NixOS/nixpkgs/1997e4aa514312c1af7e2bda7fad1644e778ff26' (2024-10-20)
  → 'github:NixOS/nixpkgs/7ffd9ae656aec493492b44d0ddfb28e79a1ea25d' (2024-11-02)
• Updated input 'hyprland/xdph':
    'github:hyprwm/xdg-desktop-portal-hyprland/fb9c8d665af0588bb087f97d0f673ddf0d501787' (2024-10-05)
  → 'github:hyprwm/xdg-desktop-portal-hyprland/09b23cef06fe248e61cec8862c04b9bcb62f4b6d' (2024-11-04)
• Updated input 'hyprland-contrib':
    'github:hyprwm/contrib/d72bc8b1cd30d448bd438e8328f8eeb4c0f2ddb6' (2024-10-18)
  → 'github:hyprwm/contrib/792f6b83dc719214e0e2a0b380c34f147b28ece2' (2024-11-04)
• Updated input 'nix-index-database':
    'github:nix-community/nix-index-database/0e3a8778c2ee218eff8de6aacf3d2fa6c33b2d4f' (2024-10-27)
  → 'github:nix-community/nix-index-database/cc2ddbf2df8ef7cc933543b1b42b845ee4772318' (2024-11-03)
• Updated input 'nixos-wsl':
    'github:nix-community/NixOS-WSL/b124084667fb4c912fda68fdd9d05f59e18b6ef7' (2024-10-28)
  → 'github:nix-community/NixOS-WSL/adb6bc4b661a43328752b4575be4968a4990c033' (2024-11-01)
• Updated input 'nixpkgs-wayland':
    'github:nix-community/nixpkgs-wayland/1bb7ec644d299edf5b88fd2dc67042d14c6638ae' (2024-10-31)
  → 'github:nix-community/nixpkgs-wayland/2920f4cc370aedb9043644343ac7fc0251f2cde8' (2024-11-03)
• Updated input 'nixpkgs-wayland/lib-aggregate':
    'github:nix-community/lib-aggregate/7d235f23a84b54c39b1579b68b13e1ff83f5b1ad' (2024-10-27)
  → 'github:nix-community/lib-aggregate/d0ecc1890f77e9e170f2de279d6902d84a0cbc51' (2024-11-03)
• Updated input 'nixpkgs-wayland/lib-aggregate/nixpkgs-lib':
    'github:nix-community/nixpkgs.lib/7d68864343650322045894951602d6e82b5296d7' (2024-10-27)
  → 'github:nix-community/nixpkgs.lib/2376a861a1a15f05339245fbaa4422f2d1bdf485' (2024-11-03)
• Updated input 'nixpkgs-wayland/nix-eval-jobs':
    'github:nix-community/nix-eval-jobs/a3307ac4b38b6dae769f771c877a6f2c236ee238' (2024-10-10)
  → 'github:nix-community/nix-eval-jobs/7f9159a16584ee86eed077c8a73e845690b7d513' (2024-10-31)
• Updated input 'nixpkgs-wayland/nixpkgs':
    'github:nixos/nixpkgs/18536bf04cd71abd345f9579158841376fdd0c5a' (2024-10-25)
  → 'github:nixos/nixpkgs/7ffd9ae656aec493492b44d0ddfb28e79a1ea25d' (2024-11-02)
• Updated input 'roc':
    'github:roc-lang/roc/69dd8d77f3127cb21eaa34f8c7533930e30b923a' (2024-10-30)
  → 'github:roc-lang/roc/faaf69599eccd043ac62cf349581c1989aba4265' (2024-11-04)
• Updated input 'utils':
    'git+https://git.dayl.in/daylin/utils.git?ref=refs/heads/main&rev=aa0dbe4d05b3109b947f8bd0444228a800f55dc6' (2024-10-30)
  → 'git+https://git.dayl.in/daylin/utils.git?ref=refs/heads/main&rev=d86dff8360781e4ccd82a0e5a8efdf1ad07e97db' (2024-10-31)
• Updated input 'zig-overlay':
    'github:mitchellh/zig-overlay/0802240ae001576ebf9cf0bbc003a8b1291c910b' (2024-10-31)
  → 'github:mitchellh/zig-overlay/efff314a4daabec1de625a1780e774fdaea50605' (2024-11-04)
• Updated input 'zls':
    'github:zigtools/zls/b2e89dfe92850cf02cbd4b73004aaaecd5cf1739' (2024-10-27)
  → 'github:zigtools/zls/04e7f5f78ac37395ee020b30460c01dfdc0803ed' (2024-11-04)
2024-11-04 18:45:04 +00:00
51c30f86ac
don't evaluate ignore drv 2024-11-04 12:42:19 -06:00
36458fe994
update ssh-setup-action 2024-11-04 12:27:17 -06:00
5fd09508f4
reduce evaluation time 2024-11-04 12:24:47 -06:00
2a492684c2
add back working version of llm + llm-plugins 2024-11-04 12:24:08 -06:00
149c74b3d9
just nixpkgs update 2024-11-04 11:08:05 -06:00
9624d9a4f3
switch to releasd lix 2024-11-04 10:37:09 -06:00
3499471751
llm broken? 2024-11-03 18:46:38 -06:00
536d84d875
add ssh access to rest of build 2024-11-03 15:11:19 -06:00
12 changed files with 238 additions and 118 deletions

View file

@ -30,6 +30,13 @@ jobs:
- name: Checkout
uses: actions/checkout@v4
# needed to access ghostty repo for now
- name: Setup SSH
uses: MrSquaare/ssh-setup-action@v3
with:
host: github.com
private-key: ${{ secrets.SSH_PRIVATE_KEY }}
- uses: ./.github/actions/clean-disk
with:
purge-packages: 'true'
@ -43,10 +50,15 @@ jobs:
- uses: DeterminateSystems/magic-nix-cache-action@v8
- uses: cachix/cachix-action@v15
with:
name: daylin
authToken: "${{ secrets.CACHIX_AUTH_TOKEN }}"
# - name: Install and login to attic cache
# run: |
# nix profile install "nixpkgs#attic-client"
# attic login oizys https://attic.dayl.in "${{ secrets.ATTIC_TOKEN }}"
# - uses: cachix/cachix-action@v15
# with:
# name: daylin
# authToken: "${{ secrets.CACHIX_AUTH_TOKEN }}"
- name: write lock file
if: "${{ inputs.lockFile != '' }}"

View file

@ -20,8 +20,9 @@ jobs:
- name: Checkout
uses: actions/checkout@v4
# needed to access ghostty repo for now
- name: Setup SSH
uses: MrSquaare/ssh-setup-action@v1
uses: MrSquaare/ssh-setup-action@v3
with:
host: github.com
private-key: ${{ secrets.SSH_PRIVATE_KEY }}
@ -38,7 +39,6 @@ jobs:
experimental-features = pipe-operator
accept-flake-config = true
- name: Install and login to attic cache
run: |
nix profile install "nixpkgs#attic-client"
@ -69,6 +69,8 @@ jobs:
--host "othalan"
--flake .
--debug
--
--print-build-logs
- name: Commit Updates
uses: daylin-bot/actions/commit-and-push@main
@ -92,6 +94,12 @@ jobs:
with:
fetch-depth: 0
- name: Setup SSH
uses: MrSquaare/ssh-setup-action@v1
with:
host: github.com
private-key: ${{ secrets.SSH_PRIVATE_KEY }}
- uses: DeterminateSystems/nix-installer-action@v14
with:
source-url: https://install.lix.systems/lix/lix-installer-x86_64-linux

View file

@ -306,11 +306,11 @@
"zig": "zig"
},
"locked": {
"lastModified": 1730568249,
"narHash": "sha256-+yyQ2ORHK61Q69mu9/fILlHmrPd3Es8zUTnqlwiMy3o=",
"lastModified": 1730743100,
"narHash": "sha256-CE5XFfbNfuZnKzmcdWpAYU3ExinL7K41dIoPBut/xtg=",
"ref": "refs/heads/main",
"rev": "d47df211b03894427592851b0be3b528ff8221ff",
"revCount": 7864,
"rev": "960e52573b383b5d757d61e6e97b6263a5bfddd1",
"revCount": 7877,
"type": "git",
"url": "ssh://git@github.com/ghostty-org/ghostty"
},
@ -405,11 +405,11 @@
"xdph": "xdph"
},
"locked": {
"lastModified": 1730330432,
"narHash": "sha256-IfwPXZNjQlToqV37RjUhm9dofHaqZD3BTB4J111OmGQ=",
"lastModified": 1730743300,
"narHash": "sha256-dsqITa3ZwfGtw9E7s4ET+uSR74w8VfZZYNwuixQwg0Y=",
"ref": "refs/heads/main",
"rev": "7c7a84ff60f8c1e00c6a0de3f7656f0bbd933d56",
"revCount": 5395,
"rev": "0fb9a04526b06adfb3fd16b64e13b7d110ae7855",
"revCount": 5409,
"submodules": true,
"type": "git",
"url": "https://github.com/hyprwm/Hyprland/"
@ -425,11 +425,11 @@
"nixpkgs": "nixpkgs_2"
},
"locked": {
"lastModified": 1729224425,
"narHash": "sha256-w9dNUedNe2qnhHuhcRf7A1l29+/6DxdMfwN6g4U3c/w=",
"lastModified": 1730743354,
"narHash": "sha256-gU4NySYyXeAzVaF5bI6BKmj2CdgiwGFnuPjXUId3Dx0=",
"owner": "hyprwm",
"repo": "contrib",
"rev": "d72bc8b1cd30d448bd438e8328f8eeb4c0f2ddb6",
"rev": "792f6b83dc719214e0e2a0b380c34f147b28ece2",
"type": "github"
},
"original": {
@ -569,11 +569,11 @@
"nixpkgs-lib": "nixpkgs-lib"
},
"locked": {
"lastModified": 1730031145,
"narHash": "sha256-GZz0LGkeduajnF7zUuPu5evNyoOATcSsRZCkG1OqiwY=",
"lastModified": 1730635946,
"narHash": "sha256-CdeoMnMXpCq4wBWEWHfUUs68zoyAJLfp1JmfXWtmAgc=",
"owner": "nix-community",
"repo": "lib-aggregate",
"rev": "7d235f23a84b54c39b1579b68b13e1ff83f5b1ad",
"rev": "d0ecc1890f77e9e170f2de279d6902d84a0cbc51",
"type": "github"
},
"original": {
@ -585,38 +585,36 @@
"lix": {
"flake": false,
"locked": {
"lastModified": 1730328739,
"narHash": "sha256-qs7u2nCwfEV93SKV1QSikOwRbHDEA1CWYZiVKI9Hhxk=",
"rev": "beb193d1e2121cdbd51e8309572522ee9a841395",
"lastModified": 1729298361,
"narHash": "sha256-hiGtfzxFkDc9TSYsb96Whg0vnqBVV7CUxyscZNhed0U=",
"rev": "ad9d06f7838a25beec425ff406fe68721fef73be",
"type": "tarball",
"url": "https://git.lix.systems/api/v1/repos/lix-project/lix/archive/beb193d1e2121cdbd51e8309572522ee9a841395.tar.gz?rev=beb193d1e2121cdbd51e8309572522ee9a841395"
"url": "https://git.lix.systems/api/v1/repos/lix-project/lix/archive/ad9d06f7838a25beec425ff406fe68721fef73be.tar.gz?rev=ad9d06f7838a25beec425ff406fe68721fef73be"
},
"original": {
"type": "tarball",
"url": "https://git.lix.systems/lix-project/lix/archive/main.tar.gz"
"url": "https://git.lix.systems/lix-project/lix/archive/2.91.1.tar.gz"
}
},
"lix-module": {
"inputs": {
"flake-utils": "flake-utils_2",
"flakey-profile": "flakey-profile",
"lix": [
"lix"
],
"lix": "lix",
"nixpkgs": [
"nixpkgs"
]
},
"locked": {
"lastModified": 1727752861,
"narHash": "sha256-jowmo2aEzrEpPSM96IWtajuogdJm7DjAWxFTEb7Ct0s=",
"rev": "fd186f535a4ac7ae35d98c1dd5d79f0a81b7976d",
"lastModified": 1729360442,
"narHash": "sha256-6U0CyPycIBc04hbYy2hBINnVso58n/ZyywY2BD3hu+s=",
"rev": "9098ac95768f7006d7e070b88bae76939f6034e6",
"type": "tarball",
"url": "https://git.lix.systems/api/v1/repos/lix-project/nixos-module/archive/fd186f535a4ac7ae35d98c1dd5d79f0a81b7976d.tar.gz?rev=fd186f535a4ac7ae35d98c1dd5d79f0a81b7976d"
"url": "https://git.lix.systems/api/v1/repos/lix-project/nixos-module/archive/9098ac95768f7006d7e070b88bae76939f6034e6.tar.gz?rev=9098ac95768f7006d7e070b88bae76939f6034e6"
},
"original": {
"type": "tarball",
"url": "https://git.lix.systems/lix-project/nixos-module/archive/main.tar.gz"
"url": "https://git.lix.systems/lix-project/nixos-module/archive/2.91.1-1.tar.gz"
}
},
"my-nixpkgs": {
@ -723,11 +721,11 @@
"treefmt-nix": "treefmt-nix"
},
"locked": {
"lastModified": 1728593025,
"narHash": "sha256-j/p2ftkP8MXYEK7Vx65jH/Knr2QkEcRSVoDnVOUDe6Q=",
"lastModified": 1730389079,
"narHash": "sha256-g/CJ/KKe5MGsVx1oCBl0F9aCdcNSDeOw8H7e5QDGa2c=",
"owner": "nix-community",
"repo": "nix-eval-jobs",
"rev": "a3307ac4b38b6dae769f771c877a6f2c236ee238",
"rev": "7f9159a16584ee86eed077c8a73e845690b7d513",
"type": "github"
},
"original": {
@ -765,11 +763,11 @@
]
},
"locked": {
"lastModified": 1729999765,
"narHash": "sha256-LYsavZXitFjjyETZoij8usXjTa7fa9AIF3Sk3MJSX+Y=",
"lastModified": 1730604744,
"narHash": "sha256-/MK6QU4iOozJ4oHTfZipGtOgaT/uy/Jm4foCqHQeYR4=",
"owner": "nix-community",
"repo": "nix-index-database",
"rev": "0e3a8778c2ee218eff8de6aacf3d2fa6c33b2d4f",
"rev": "cc2ddbf2df8ef7cc933543b1b42b845ee4772318",
"type": "github"
},
"original": {
@ -810,11 +808,11 @@
"nixpkgs": "nixpkgs_3"
},
"locked": {
"lastModified": 1730120924,
"narHash": "sha256-I6hwd+YlgefioLfmsM04MxzbEAES1N328/T+VqhcWnQ=",
"lastModified": 1730453870,
"narHash": "sha256-d+kIgz4BvTXb7emjSFV3zjNydGmLUmuluQjdBb51R9o=",
"owner": "nix-community",
"repo": "NixOS-WSL",
"rev": "b124084667fb4c912fda68fdd9d05f59e18b6ef7",
"rev": "adb6bc4b661a43328752b4575be4968a4990c033",
"type": "github"
},
"original": {
@ -825,11 +823,11 @@
},
"nixpkgs": {
"locked": {
"lastModified": 1729413321,
"narHash": "sha256-I4tuhRpZFa6Fu6dcH9Dlo5LlH17peT79vx1y1SpeKt0=",
"lastModified": 1730531603,
"narHash": "sha256-Dqg6si5CqIzm87sp57j5nTaeBbWhHFaVyG7V6L8k3lY=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "1997e4aa514312c1af7e2bda7fad1644e778ff26",
"rev": "7ffd9ae656aec493492b44d0ddfb28e79a1ea25d",
"type": "github"
},
"original": {
@ -841,11 +839,11 @@
},
"nixpkgs-lib": {
"locked": {
"lastModified": 1729990941,
"narHash": "sha256-hUP9oxmnOmNnKcDOf5Y55HQ+NnoT0+bLWHLQWLLw9Ks=",
"lastModified": 1730595754,
"narHash": "sha256-F6DyPKY2WAUf8fpaT9vQwwRUs74InQM36ng//h9wNhY=",
"owner": "nix-community",
"repo": "nixpkgs.lib",
"rev": "7d68864343650322045894951602d6e82b5296d7",
"rev": "2376a861a1a15f05339245fbaa4422f2d1bdf485",
"type": "github"
},
"original": {
@ -878,11 +876,11 @@
"nixpkgs": "nixpkgs_6"
},
"locked": {
"lastModified": 1730337937,
"narHash": "sha256-CCjeZD8RpgDUBlVtfwGHwjz6pNZm9287mKy47mIxLlQ=",
"lastModified": 1730638537,
"narHash": "sha256-2HOixA1kKx0gmPFWlg6lYlQ452rvt9Ims2+/wk+nsQM=",
"owner": "nix-community",
"repo": "nixpkgs-wayland",
"rev": "1bb7ec644d299edf5b88fd2dc67042d14c6638ae",
"rev": "2920f4cc370aedb9043644343ac7fc0251f2cde8",
"type": "github"
},
"original": {
@ -925,11 +923,11 @@
},
"nixpkgs_4": {
"locked": {
"lastModified": 1729880355,
"narHash": "sha256-RP+OQ6koQQLX5nw0NmcDrzvGL8HDLnyXt/jHhL1jwjM=",
"lastModified": 1730531603,
"narHash": "sha256-Dqg6si5CqIzm87sp57j5nTaeBbWhHFaVyG7V6L8k3lY=",
"owner": "nixos",
"repo": "nixpkgs",
"rev": "18536bf04cd71abd345f9579158841376fdd0c5a",
"rev": "7ffd9ae656aec493492b44d0ddfb28e79a1ea25d",
"type": "github"
},
"original": {
@ -957,11 +955,11 @@
},
"nixpkgs_6": {
"locked": {
"lastModified": 1729880355,
"narHash": "sha256-RP+OQ6koQQLX5nw0NmcDrzvGL8HDLnyXt/jHhL1jwjM=",
"lastModified": 1730531603,
"narHash": "sha256-Dqg6si5CqIzm87sp57j5nTaeBbWhHFaVyG7V6L8k3lY=",
"owner": "nixos",
"repo": "nixpkgs",
"rev": "18536bf04cd71abd345f9579158841376fdd0c5a",
"rev": "7ffd9ae656aec493492b44d0ddfb28e79a1ea25d",
"type": "github"
},
"original": {
@ -1058,11 +1056,11 @@
"rust-overlay": "rust-overlay"
},
"locked": {
"lastModified": 1730263683,
"narHash": "sha256-cYDUzVP+CjMOfpw4pBQNUUS447HE0Ys5r2sf3TbGAGw=",
"lastModified": 1730680060,
"narHash": "sha256-3lGO5mV8tDaH8Odxu1gPY1g8lSSb8Kh9AqGqDP2Qc2s=",
"owner": "roc-lang",
"repo": "roc",
"rev": "69dd8d77f3127cb21eaa34f8c7533930e30b923a",
"rev": "faaf69599eccd043ac62cf349581c1989aba4265",
"type": "github"
},
"original": {
@ -1078,7 +1076,6 @@
"hyprland": "hyprland",
"hyprland-contrib": "hyprland-contrib",
"hyprman": "hyprman",
"lix": "lix",
"lix-module": "lix-module",
"my-nixpkgs": "my-nixpkgs",
"nim2nix": "nim2nix_2",
@ -1303,11 +1300,11 @@
"nixpkgs": "nixpkgs_8"
},
"locked": {
"lastModified": 1730325917,
"narHash": "sha256-Ku8nypKSmPSIpqfubsnjqFDBnF9m5Pw+9sXHMmZbyFY=",
"lastModified": 1730391705,
"narHash": "sha256-OxFmkw/4WXidYGFU3TZR0qf2HUbwzqqMFShkBgtHjUA=",
"ref": "refs/heads/main",
"rev": "aa0dbe4d05b3109b947f8bd0444228a800f55dc6",
"revCount": 18,
"rev": "d86dff8360781e4ccd82a0e5a8efdf1ad07e97db",
"revCount": 20,
"type": "git",
"url": "https://git.dayl.in/daylin/utils.git"
},
@ -1344,11 +1341,11 @@
]
},
"locked": {
"lastModified": 1728166987,
"narHash": "sha256-w6dVTguAn9zJ+7aPOhBQgDz8bn6YZ7b56cY8Kg5HJRI=",
"lastModified": 1730743262,
"narHash": "sha256-iTLqj3lU8kFehPm5tXpctzkD274t/k1nwSSq3qCWXeg=",
"owner": "hyprwm",
"repo": "xdg-desktop-portal-hyprland",
"rev": "fb9c8d665af0588bb087f97d0f673ddf0d501787",
"rev": "09b23cef06fe248e61cec8862c04b9bcb62f4b6d",
"type": "github"
},
"original": {
@ -1391,11 +1388,11 @@
]
},
"locked": {
"lastModified": 1730334608,
"narHash": "sha256-NT/xmtGvwkiFfDC+FdIThG387OakQS0hnnT3etJbbNE=",
"lastModified": 1730722337,
"narHash": "sha256-tvbAprVy34KXPywdbPhIW9+0ZfrHvmtaGWSk16dg/Z8=",
"owner": "mitchellh",
"repo": "zig-overlay",
"rev": "0802240ae001576ebf9cf0bbc003a8b1291c910b",
"rev": "efff314a4daabec1de625a1780e774fdaea50605",
"type": "github"
},
"original": {
@ -1416,11 +1413,11 @@
]
},
"locked": {
"lastModified": 1730064361,
"narHash": "sha256-myb/4V8tP3n3WJQlaDrCmQkbmcMEcgX1mFu2jdfwTsk=",
"lastModified": 1730680575,
"narHash": "sha256-mTBk+bkTSL6hjghP7BpSEpCWwQkqqhhjDpZYA4HuAaI=",
"owner": "zigtools",
"repo": "zls",
"rev": "b2e89dfe92850cf02cbd4b73004aaaecd5cf1739",
"rev": "04e7f5f78ac37395ee020b30460c01dfdc0803ed",
"type": "github"
},
"original": {

View file

@ -12,14 +12,19 @@
nixos-wsl.url = "github:nix-community/NixOS-WSL";
nix-index-database.url = "github:nix-community/nix-index-database";
lix = {
url = "https://git.lix.systems/lix-project/lix/archive/main.tar.gz";
flake = false;
};
# lix = {
# url = "https://git.lix.systems/lix-project/lix/archive/main.tar.gz";
# flake = false;
# };
# lix-module = {
# url = "https://git.lix.systems/lix-project/nixos-module/archive/main.tar.gz";
# inputs.nixpkgs.follows = "nixpkgs";
# inputs.lix.follows = "lix";
# };
lix-module = {
url = "https://git.lix.systems/lix-project/nixos-module/archive/main.tar.gz";
url = "https://git.lix.systems/lix-project/nixos-module/archive/2.91.1-1.tar.gz";
inputs.nixpkgs.follows = "nixpkgs";
inputs.lix.follows = "lix";
};
# https://github.com/ghostty-org/ghostty/issues/2025

View file

@ -16,6 +16,7 @@
|> listify;
}
// (
# llm
''
vpn|desktop|hyprland|chrome
backups|hp-scanner|llm

View file

@ -2,22 +2,18 @@
pkgs,
config,
mkOizysModule,
# enabled,
flake,
...
}:
let
inherit (pkgs) python3Packages;
# llm-ollama = python3Packages.callPackage ./llm-plugins/llm-ollama { };
llm-claude3 = python3Packages.callPackage ./llm-plugins/llm-claude-3 { };
in
mkOizysModule config "llm" {
# services.ollama = enabled;
environment.systemPackages = with pkgs; [
(python3.withPackages (ps: [
ps.llm
llm-claude3
]))
(python3.withPackages (ps:
with (flake.pkgs "self");
[
llm
llm-claude-3
]
))
];
}

View file

@ -1,7 +1,11 @@
{ pkgs, ... }:
let inherit (pkgs) python3Packages;
in
{
nph = pkgs.callPackage ./nim/nph { }; # doesn't compile with 2.2.0 :/
nimlangserver = pkgs.callPackage ./nim/nimlangserver { };
nimble = pkgs.callPackage ./nim/nimble { };
distrobox = pkgs.callPackage ./distrobox {};
llm = python3Packages.callPackage ./llm {};
llm-claude-3 = python3Packages.callPackage ./llm-plugins/llm-claude-3 {};
}

View file

@ -13,7 +13,7 @@
buildPythonPackage rec {
pname = "llm-claude-3";
version = "0.4";
version = "0.7";
pyproject = true;
src = fetchFromGitHub {

96
pkgs/llm/default.nix Normal file
View file

@ -0,0 +1,96 @@
{
lib,
buildPythonPackage,
fetchFromGitHub,
pytestCheckHook,
pythonOlder,
setuptools,
click-default-group,
numpy,
openai,
pip,
pluggy,
pydantic,
python-ulid,
pyyaml,
sqlite-migrate,
cogapp,
pytest-httpx,
puremagic,
sqlite-utils,
}:
let
llm = buildPythonPackage rec {
pname = "llm";
version = "0.17.1";
pyproject = true;
build-system = [ setuptools ];
disabled = pythonOlder "3.8";
src = fetchFromGitHub {
owner = "simonw";
repo = "llm";
rev = "refs/tags/${version}";
hash = "sha256-6OO0SIIxChM5HRJoUM4CYGbsINmc3i+iyL/oahLHhrY=";
};
# patches = [ ./001-disable-install-uninstall-commands.patch ];
dependencies = [
click-default-group
numpy
openai
pip
pluggy
pydantic
python-ulid
pyyaml
setuptools # for pkg_resources
sqlite-migrate
sqlite-utils
puremagic
];
nativeCheckInputs = [
cogapp
numpy
pytest-httpx
pytestCheckHook
];
doCheck = true;
pytestFlagsArray = [
"-svv"
"tests/"
];
pythonImportsCheck = [ "llm" ];
passthru = {
inherit withPlugins;
};
meta = with lib; {
homepage = "https://github.com/simonw/llm";
description = "Access large language models from the command-line";
changelog = "https://github.com/simonw/llm/releases/tag/${version}";
license = licenses.asl20;
mainProgram = "llm";
maintainers = with maintainers; [
aldoborrero
mccartykim
];
};
};
withPlugins = throw ''
llm.withPlugins was confusing to use and has been removed.
Please migrate to using python3.withPackages(ps: [ ps.llm ]) instead.
See https://nixos.org/manual/nixpkgs/stable/#python.withpackages-function for more usage examples.
'';
in
llm

View file

@ -134,8 +134,14 @@ proc evaluateDerivations(drvs: seq[string]): Table[string, NixDerivation] =
cmd.addArgs drvs
let (output, _) =
runCmdCaptWithSpinner(cmd, "evaluating derivations")
fromJson(output, Table[string,NixDerivation])
fromJson(output, Table[string, NixDerivation])
proc nixDerivationShow(drvs: seq[string]): Table[string, NixDerivation] =
var cmd = "nix derivation show"
cmd.addArgs drvs
let (output, _ ) =
runCmdCaptWithSpinner(cmd, "evaluating " & drvs.join(" "))
fromJson(output, Table[string, NixDerivation])
# TODO: replace asserts in this proc, would be easier with results type
proc findSystemPaths(drvs: Table[string, NixDerivation]): seq[string] =
@ -172,33 +178,36 @@ func isIgnored(drv: string): bool =
if name.startswith(pkg):
return true
# proc systemPathDrvsToBuild(): seq[string] =
type
OizysDerivation = object
drv: NixDerivation # do i need this ?
output: string
name: string
iterator getSystemPathDrvs(drvs: Table[string, NixDerivation]): string =
let systemPaths = findSystemPaths(drvs)
for p in systemPaths:
for d in drvs[p].inputDrvs.keys():
yield d
proc getSystemPathDrvs(): seq[string] =
let systemDrvs = nixDerivationShow(nixosConfigAttrs())
let systemPathDrvs = findSystemPaths(systemDrvs)
result =
collect:
for k, drv in nixDerivationShow(systemPathDrvs):
for inputDrv, _ in drv.inputDrvs:
inputDrv
proc getOizysDerivations(): seq[OizysDerivation] =
let toBuild = toBuildNixosConfiguration()
let drvs = evaluateDerivations(nixosConfigAttrs())
let
toBuildDrvs = toBuildNixosConfiguration()
systemPathDrvs = getSystemPathDrvs()
toActullyBuildDrvs = systemPathDrvs.filterIt(it in toBuildDrvs and not isIgnored(it))
for name in getSystemPathDrvs(drvs):
if name in toBuild and not isIgnored(name):
let nixDrv = drvs[name]
result.add OizysDerivation(
for name, drv in nixDerivationShow(toActullyBuildDrvs):
result.add OizysDerivation(
name: name,
output: nixDrv.outputs.`out`.path,
drv: nixDrv,
)
output: drv.outputs.`out`.path,
drv: drv,
)
# TODO: remove this proc
proc systemPathDrvsToBuild(): seq[string] =
var inputDrvs, dropped: seq[string]
let toBuild = toBuildNixosConfiguration()
@ -210,12 +219,6 @@ proc systemPathDrvsToBuild(): seq[string] =
(result, _) = filterSeq(inputDrvs, (s) => s in toBuild)
(dropped, result) = filterSeq(result, isIgnored)
echo "SOMETHING SHOULD HAPPEN HERE!"
for drv in result:
echo drv
echo drvs[drv]
debug fmt"ignored {dropped.len} derivations"
result = result.mapIt(it & "^*")
@ -294,8 +297,6 @@ proc nixBuildWithCache*(name: string, rest:seq[string], service: string, jobs: i
var cmd = "nix build"
cmd.addArg drv.name & "^*"
cmd.addArg "--no-link"
# cmd.addArg "--print-out-paths"
# cmd.addArg "-L"
cmd.addArgs rest
let buildCode = runCmd(cmd)
if buildCode != 0: