Add a flake.nix for NixOS Flake users#2734
Conversation
|
Important Review skippedAuto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: Repository UI Review profile: CHILL Plan: Pro Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
ApprovabilityVerdict: Approved This PR adds NixOS Flake packaging support through new files (flake.nix, flake.lock) and documentation. It provides an alternative installation method by wrapping existing AppImage releases - no application code is modified and there's no runtime behavior change to the application itself. You can customize Macroscope's approvability policy. Learn more. |
|
minor update: im switching to using the provided appimages instead of building from source |
- Add clear sections for releases, download hash, and platforms - Update hash by running: nix hash url <download-url> - Only support x86_64-linux (no ARM AppImage available) - Simplify code for easier maintenance
UpdatesM - flake.nix this started out building from source but ive pivoted due to sandboxing issues, instead deciding to wrap the pre-build appimage with MaintenancereleaseTag = "v0.0.23"; // version
appimageHash = "sha256-..."; // update with `nix hash url <appimage-url>
supportedSystems = [ "x86_64-linux" ];i have tested this build on my local flake, AND my fork with the changes. the app built, and opened through my launcher just fine. README.md updates that for some reason arent appearing on my end.NixOS (Flakes)# /path/to/your/flake.nix
{
inputs = {
# This flake is pinned to nixpkgs stable
nixpkgs.url = "github:nixos/nixpkgs/nixos-25.05";
t3code-flake.url = "github:pingdotgg/t3code";
t3code-flake.inputs.nixpkgs.follows = "nixpkgs";
};
}# /path/to/your/configuration.nix
{
nix.settings.experimental-features = [ "nix-command" "flakes" ];
environment.systemPackages = [
pkgs.appimage-run
inputs.t3code-flake.packages.${system}
];
}this addresses the appimage issue. |
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 2 potential issues.
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit 01f0ee6. Configure here.
… an example for pinning the releaseTag. (Currently wired for 0.0.24)
Dismissing prior approval to re-evaluate 09f2ab4
| environment.systemPackages = [ | ||
| pkgs.appimage-run | ||
| inputs.t3code-flake.packages.${system}.default | ||
| ]; | ||
| } |
There was a problem hiding this comment.
🟢 Low README.md:64
The configuration.nix example includes pkgs.appimage-run (line 65), which is unnecessary because the flake builds t3code natively without the AppImage wrapper. Users copying this verbatim will install an unused dependency. Consider removing pkgs.appimage-run from the example.
| environment.systemPackages = [ | |
| pkgs.appimage-run | |
| inputs.t3code-flake.packages.${system}.default | |
| ]; | |
| } | |
| environment.systemPackages = [ | |
| - pkgs.appimage-run | |
| inputs.t3code-flake.packages.${system}.default | |
| ]; |
🤖 Copy this AI Prompt to have your agent fix this:
In file README.md around lines 64-68:
The `configuration.nix` example includes `pkgs.appimage-run` (line 65), which is unnecessary because the flake builds t3code natively without the AppImage wrapper. Users copying this verbatim will install an unused dependency. Consider removing `pkgs.appimage-run` from the example.

What Changed
A - flake.nix
A - flake.lock
M - README.md
flake.nixlooks at the parent repo (pingdotgg/t3code), pulls it, builds it from source, and caches the build in anix/storedirectory on first build. unless the user runs 'nix flake update', manually updating their flake inputs, t3code on the user machine will not receive codebase changes from the repository. It also will not rebuild the application unless the nix/store hash, and updated repo hash are different.README.mdnow includes how to install this application on nixos flake enabled machines.Why
Currently using t3code on nixos requires using appimages, and other "not-very-nix" ways of installing applications depending on your mode of attack. Ive spent the past few hours creating a flake.nix that reads the repo, builds it from source, and only rebuilds the app if the repo updates. this enables a simple and easy oneliner installation of t3code on nixos machines.
there is very little maintenance on your behalf, only ever needing to update
flake.nix:6:nixpkgs.url=to be the latest nixpkgs stable release, OR for a set-and-forget you can set it tonixos-unstable, and change the readme accordingly. the flake handles the nixos specific runtime shenanigans, your source code just tells it what to buildChecklist
Note
Low Risk
Low risk: adds Nix packaging and documentation only; no changes to application runtime logic beyond how the AppImage is fetched/wrapped for NixOS.
Overview
Adds NixOS flake support by introducing
flake.nix/flake.lockthat exposepackages.x86_64-linux.default, fetching a pinned GitHub-release AppImage and wrapping it with at3codelauncher that runs viaappimage-run.Updates
README.mdwith NixOS (Flakes) installation snippets showing how to add the flake as an input (optionally pin a tag) and install the package viaenvironment.systemPackages.Reviewed by Cursor Bugbot for commit 911b652. Bugbot is set up for automated code reviews on this repo. Configure here.
Note
Add a Nix flake for installing
t3codeon NixOSx86_64-linuxpackage that fetches thet3codeAppImage from GitHub releases and wraps it withappimage-run.NixOS (Flakes)section showing how to add the flake input and install the package viaenvironment.systemPackages.nixos-25.05; maintainers must manually updatereleaseTagandappimageHashon new releases.Macroscope summarized 911b652.