Skip to content

Conversation

@gigamonster256
Copy link
Contributor

standardizes dev packages to the regular callPackage style and brings best practices from nixpkgs upstream

maintains compatibility with current nix based CI updates to node_modules hashes

NOTE: this removes the flake-update CI job - read the commit desc for why - open to discussion

Superscedes #8998

would love feedback/get testing from recent nix committers @gbpdt @Alb-O @jerome-benoit

the whole point of having a lock file is to have a stable set of
packages to develop against. bun was recently updated to 1.3.6 in
nixpkgs-unstable so until opencode moves to 1.3.6 we should stay pinned
to a commit of nixpkgs that has bun 1.3.5

if automated flake lock updates are desired, the update should at least
be conditioned on the apps still building
@github-actions
Copy link
Contributor

Thanks for your contribution!

This PR doesn't have a linked issue. All PRs must reference an existing issue.

Please:

  1. Open an issue describing the bug/feature (if one doesn't exist)
  2. Add Fixes #<number> or Closes #<number> to this PR description

See CONTRIBUTING.md for details.

@github-actions
Copy link
Contributor

The following comment was made by an LLM, it may be inaccurate:

Related PR Found:

The current PR #9032 is not a duplicate but rather a successor to #8998. It appears #8998 should likely be closed in favor of this more comprehensive nix overhaul.

@rekram1-node
Copy link
Collaborator

Yes would love to hear feedback from the other nix folks

@Alb-O
Copy link
Contributor

Alb-O commented Jan 17, 2026

I was hoping someone else who better knew what they were doing would take over the nix code, thank you 😄

Works great on my machine

@gigamonster256 gigamonster256 force-pushed the push-osnrnvnwzxsz branch 2 times, most recently from aea0dd0 to db2812b Compare January 17, 2026 07:46
@Alb-O
Copy link
Contributor

Alb-O commented Jan 17, 2026

Now is probably a good time to update the meta description too. From the current README: The open source AI coding agent.

@gigamonster256 gigamonster256 force-pushed the push-osnrnvnwzxsz branch 10 times, most recently from 5ff415e to 9cd7b85 Compare January 17, 2026 09:43
@jerome-benoit
Copy link
Contributor

Yes would love to hear feedback from the other nix folks

It's a step in the good direction at removing a lot of unneeded existing build indirections, I will review it thoroughly ASAP.

@jerome-benoit
Copy link
Contributor

Yes would love to hear feedback from the other nix folks

Please, authorize the CI workflow to run to avoid blind review.

Copy link
Contributor

@jerome-benoit jerome-benoit left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The namespace collision is a showstopper for binary resolution in the PATH on macOS for example when both packages are installed.

The rest is mainly cleanup + robustness review comments.

Since you seem to have the knowledge and the time, it would be great if you can implement standard checks (formatting, build, derivation, ...) the nix way: the CI and devs would only need to do nix check to run a comprehensive validation of the nix opencode packaging :)

nix/desktop.nix Outdated
mainProgram = "opencode-desktop";
platforms = platforms.linux ++ platforms.darwin;
license = lib.licenses.mit;
mainProgram = "OpenCode";
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Namespace collision, introduce breakage on case insensitive FS and existing installation, etc. as seen in #8998.

If it's a recent change in the desktop app on the binary name output, it should be fixed (and would never have been accepted). If it's an already existing longtime issue, it should be reported and fixed ... (and it's a bit worrying, binary namespace for cross platform is well documented in the literature).

Please workaround it for now.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

sure, I can make a workaround for now.

it looks to be a change as of 96975ef - before it had a space in it which is perhaps it was falling back to the rust package name of opencode-desktop. This should definitely be raised as a new issue to see if co-located cli and desktop installs are supported

to note, the desktop packages distribute the opencode binary as "opencode-cli"

@jerome-benoit
Copy link
Contributor

jerome-benoit commented Jan 17, 2026

NOTE: this removes the flake-update CI job - read the commit desc for why - open to discussion

The whole project dependencies handling should be handled that way :)

A tool like renovate or dependabot should be properly configured and open PRs for deps updates that MUST pass the CI before being merged (including nix packages)

Copy link
Contributor

@gbpdt gbpdt left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks like a great cleanup!

@rekram1-node
Copy link
Collaborator

Thank yall lmk how I can help

@gigamonster256 gigamonster256 force-pushed the push-osnrnvnwzxsz branch 3 times, most recently from 1d3cd21 to 0342bb3 Compare January 18, 2026 00:32
@gigamonster256 gigamonster256 force-pushed the push-osnrnvnwzxsz branch 2 times, most recently from 4e72506 to 632fd0a Compare January 18, 2026 00:48
standardizes dev packages to the regular callPackage style and brings
best practices from nixpkgs upstream

maintains compatibility with current nix based CI updates to
node_modules hashes
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants