feat: update opencode to v1.1.60 and re-enable opencode-desktop
Some checks failed
Update Nix Packages with nix-update / nix-update (push) Failing after 1s

- Update opencode flake input to v1.1.60
- Add nixpkgs-master input for opencode (needs newer bun)
- Re-enable opencode-desktop with workaround for upstream issue #11755
- Add specta/tauri outputHashes for git dependencies
- Add .todos/ to gitignore
- Update AGENTS.md with td task management instructions
This commit is contained in:
m3tm3re
2026-02-12 19:42:11 +01:00
parent 909acf61d3
commit dc2f3b6802
7 changed files with 233 additions and 162 deletions

1
.gitignore vendored
View File

@@ -31,3 +31,4 @@ test-result/
# Local configuration (if you want to keep local overrides)
local.nix
flake.lock.bak
.todos/

View File

@@ -1,5 +1,10 @@
# m3ta-nixpkgs Knowledge Base
## MANDATORY: Use td for Task Management
You must run td usage --new-session at conversation start (or after /clear) to see current work.
Use td usage -q for subsequent reads.
**Generated:** 2026-01-13
**Commit:** 366af12
**Branch:** master

View File

@@ -48,6 +48,7 @@ nix run git+https://code.m3ta.dev/m3tam3re/nixpkgs#zellij-ps
| `msty-studio` | Msty Studio application |
| `n8n` | Free and source-available fair-code licensed workflow automation tool |
| `opencode` | AI coding agent built for the terminal |
| `opencode-desktop` | OpenCode Desktop App with Wayland support (includes workaround for upstream issue #11755) |
| `pomodoro-timer` | Pomodoro timer utility |
| `rofi-project-opener` | Rofi-based project launcher |
| `stt-ptt` | Push to Talk Speech to Text |
@@ -76,8 +77,6 @@ Go to **Actions → Update Nix Packages with nix-update → Run workflow** in Gi
2. Token scopes needed: `user`, `repo`, `write:issue`
3. Add token as secret: Settings → Secrets → New → `NIX_UPDATE_TOKEN`
**Note:** The `opencode-desktop` package is currently disabled due to an upstream issue with missing specta dependency hashes. See [issue #11755](https://github.com/anomalyco/opencode/issues/11755) for details. This is a temporary workaround until the upstream issue is resolved.
For detailed usage, module documentation, package references, and contribution guidelines, see the [full documentation](./docs).
## License

23
flake.lock generated
View File

@@ -16,37 +16,39 @@
"type": "github"
}
},
"nixpkgs_2": {
"nixpkgs-master": {
"locked": {
"lastModified": 1770073757,
"narHash": "sha256-Vy+G+F+3E/Tl+GMNgiHl9Pah2DgShmIUBJXmbiQPHbI=",
"lastModified": 1770917518,
"narHash": "sha256-XSwv/tVrNo/L8SPH8Lx9xZH1PrZd/3Z3J/0SH7Xertg=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "47472570b1e607482890801aeaf29bfb749884f6",
"rev": "3f4a3c08f2f318ee29fc8a2689f390071a94aaf0",
"type": "github"
},
"original": {
"owner": "NixOS",
"ref": "nixpkgs-unstable",
"ref": "master",
"repo": "nixpkgs",
"type": "github"
}
},
"opencode": {
"inputs": {
"nixpkgs": "nixpkgs_2"
"nixpkgs": [
"nixpkgs-master"
]
},
"locked": {
"lastModified": 1770817534,
"narHash": "sha256-AcLT70Gjt78nDd13ACUDavE+QI+ouEBwyZq8hIDDAf8=",
"lastModified": 1770875904,
"narHash": "sha256-8ZEVlGe1saA/2KtDTKgkwWfpLCbxfwFip+m+3FlQQK0=",
"owner": "anomalyco",
"repo": "opencode",
"rev": "edcfd562af6ea5fdc1ade9f46259a676d7663801",
"rev": "03de51bd3cf9e05bd92c9f51763b74a3cdfbe61a",
"type": "github"
},
"original": {
"owner": "anomalyco",
"ref": "v1.1.57",
"ref": "v1.1.60",
"repo": "opencode",
"type": "github"
}
@@ -54,6 +56,7 @@
"root": {
"inputs": {
"nixpkgs": "nixpkgs",
"nixpkgs-master": "nixpkgs-master",
"opencode": "opencode"
}
}

View File

@@ -1,26 +1,23 @@
{
description = "m3ta's personal Nix repository - Custom packages, overlays, and modules";
description =
"m3ta's personal Nix repository - Custom packages, overlays, and modules";
inputs = {
nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
opencode.url = "github:anomalyco/opencode/v1.1.59";
nixpkgs-master.url = "github:NixOS/nixpkgs/master";
# Optional: Add stable channel if needed
# nixpkgs-stable.url = "github:NixOS/nixpkgs/nixos-24.05";
# opencode needs newer bun from master
opencode = {
url = "github:anomalyco/opencode/v1.1.60";
inputs.nixpkgs.follows = "nixpkgs-master";
};
};
outputs = {
self,
nixpkgs,
...
} @ inputs: let
outputs = { self, nixpkgs, ... }@inputs:
let
# Supported systems
systems = [
"x86_64-linux"
"aarch64-linux"
"x86_64-darwin"
"aarch64-darwin"
];
systems =
[ "x86_64-linux" "aarch64-linux" "x86_64-darwin" "aarch64-darwin" ];
# Helper function to generate an attrset for each of the systems
forAllSystems = nixpkgs.lib.genAttrs systems;
@@ -33,12 +30,9 @@
};
in {
# Custom packages - accessible via 'nix build .#package-name'
packages = forAllSystems (
system: let
pkgs = pkgsFor system;
in
import ./pkgs {inherit pkgs inputs;}
);
packages = forAllSystems (system:
let pkgs = pkgsFor system;
in import ./pkgs { inherit pkgs inputs; });
# Overlays - can be imported in your system configuration
overlays = {
@@ -56,8 +50,7 @@
inputs = inputs;
};
modifications = final: prev:
import ./overlays/mods {inherit prev;};
modifications = final: prev: import ./overlays/mods { inherit prev; };
};
# NixOS modules - for system-level configuration
@@ -76,28 +69,19 @@
};
# Library functions - helper utilities for your configuration
lib = forAllSystems (
system: let
pkgs = pkgsFor system;
in
import ./lib {lib = pkgs.lib;}
);
lib = forAllSystems (system:
let pkgs = pkgsFor system;
in import ./lib { lib = pkgs.lib; });
# Development shells for various programming environments
# Usage: nix develop .#<shell-name>
# Available shells: default, python, devops
devShells = forAllSystems (
system: let
pkgs = pkgsFor system;
in
import ./shells {inherit pkgs;}
);
devShells = forAllSystems (system:
let pkgs = pkgsFor system;
in import ./shells { inherit pkgs; });
# Formatter for 'nix fmt'
formatter = forAllSystems (
system:
(pkgsFor system).alejandra
);
formatter = forAllSystems (system: (pkgsFor system).alejandra);
# Templates for creating new packages/modules
templates = {

View File

@@ -1,8 +1,4 @@
{
pkgs,
inputs ? null,
...
}: {
{ pkgs, inputs ? null, ... }: {
# Custom packages registry
# Each package is defined in its own directory under pkgs/
beads = pkgs.callPackage ./beads { };
@@ -22,5 +18,5 @@
# Imported from flake inputs
opencode = inputs.opencode.packages.${pkgs.system}.opencode;
# opencode-desktop = pkgs.callPackage ./opencode-desktop { inherit inputs; };
opencode-desktop = pkgs.callPackage ./opencode-desktop { inherit inputs; };
}

View File

@@ -1,8 +1,91 @@
{ lib, stdenv, symlinkJoin, makeWrapper, inputs ? null, }:
let
opencode-desktop =
inputs.opencode.packages.${stdenv.hostPlatform.system}.desktop;
in symlinkJoin {
{
lib,
stdenv,
symlinkJoin,
makeWrapper,
rustPlatform,
pkg-config,
cargo-tauri,
bun,
nodejs,
cargo,
rustc,
jq,
wrapGAppsHook4,
dbus,
glib,
gtk4,
libsoup_3,
librsvg,
libappindicator,
glib-networking,
openssl,
webkitgtk_4_1,
gst_all_1,
inputs ? null,
}: let
# Get upstream opencode package for shared attributes
opencode = inputs.opencode.packages.${stdenv.hostPlatform.system}.default;
# Workaround for https://github.com/anomalyco/opencode/issues/11755
# Upstream is missing outputHashes for git dependencies
opencode-desktop = rustPlatform.buildRustPackage (finalAttrs: {
pname = "opencode-desktop";
inherit (opencode) version src node_modules patches;
cargoRoot = "packages/desktop/src-tauri";
cargoLock = {
lockFile = finalAttrs.src + "/packages/desktop/src-tauri/Cargo.lock";
outputHashes = {
"specta-2.0.0-rc.22" = "sha256-YsyOAnXELLKzhNlJ35dHA6KGbs0wTAX/nlQoW8wWyJQ=";
"tauri-2.9.5" = "sha256-dv5E/+A49ZBvnUQUkCGGJ21iHrVvrhHKNcpUctivJ8M=";
"tauri-specta-2.0.0-rc.21" = "sha256-n2VJ+B1nVrh6zQoZyfMoctqP+Csh7eVHRXwUQuiQjaQ=";
};
};
buildAndTestSubdir = finalAttrs.cargoRoot;
nativeBuildInputs =
[pkg-config cargo-tauri.hook bun nodejs cargo rustc jq makeWrapper]
++ lib.optionals stdenv.hostPlatform.isLinux [wrapGAppsHook4];
buildInputs = lib.optionals stdenv.isLinux [
dbus
glib
gtk4
libsoup_3
librsvg
libappindicator
glib-networking
openssl
webkitgtk_4_1
gst_all_1.gstreamer
gst_all_1.gst-plugins-base
gst_all_1.gst-plugins-good
gst_all_1.gst-plugins-bad
];
strictDeps = true;
preBuild = ''
cp -a ${finalAttrs.node_modules}/{node_modules,packages} .
chmod -R u+w node_modules packages
patchShebangs node_modules
patchShebangs packages/desktop/node_modules
mkdir -p packages/desktop/src-tauri/sidecars
cp ${opencode}/bin/opencode packages/desktop/src-tauri/sidecars/opencode-cli-${stdenv.hostPlatform.rust.rustcTarget}
'';
tauriBuildFlags = ["--config" "tauri.prod.conf.json" "--no-sign"];
postFixup = lib.optionalString stdenv.hostPlatform.isLinux ''
mv $out/bin/OpenCode $out/bin/opencode-desktop
sed -i 's|^Exec=OpenCode$|Exec=opencode-desktop|' $out/share/applications/OpenCode.desktop
'';
});
# Wrapper for Wayland support
in
symlinkJoin {
name = "opencode-desktop";
paths = [opencode-desktop];