summaryrefslogtreecommitdiff
path: root/nix/devShell.nix
AgeCommit message (Collapse)Author
2025-09-23setup basic doxygen for docsMitchell Hashimoto
We may not stick with Doxygen, but it gives us something to start with.
2025-09-04devshell: add poopJeffrey C. Ollie
2025-09-04ai: add `gh-issue` command to help diagnose GitHub issuesMitchell Hashimoto
This enables agents (namely Amp) to use `/gh-issue <number/url>` to begin diagnosing a GitHub issue, explaining the problem, and suggesting a plan of action. This action explicitly prompts the AI to not write code. I've used this manually for months with good results, so now I'm formalizing it in the repo for other contributors. Example diagnosing #8523: https://ampcode.com/threads/T-3e26e8cc-83d1-4e3c-9b5e-02d9111909a7
2025-07-23devshell: add deps that allow GTK to load SVG resourcesJeffrey C. Ollie
GTK dynamically loads librsvg when it needs to convert a SVG-only icon (or any other SVG-only resource) for display. This PR adds the libraries that GTK needs so that running programs from within the developer shell can display those SVG resources.
2025-07-11ci: add shellcheck linting for shell scriptsBryan Lee
Add shellcheck to CI pipeline to ensure shell scripts follow best practices and catch common errors. Fix existing shellcheck warnings in test scripts to pass the new linting requirements.
2025-07-06pin GitHub Actions to specific SHAsBreno A.
2025-05-26nix: temporarily remove snapcraft from the devshellJeffrey C. Ollie
2025-05-13gtk: implement custom audio for bellJeffrey C. Ollie
2025-04-22ci: flatpakMitchell Hashimoto
2025-04-10ci: add a script and workflow for requesting i18n reviewtrag1c
2025-03-19build: distribute gresource c/h with source tarballMitchell Hashimoto
This introduces the concept of a "dist resource" (specifically a `GhosttyDist.Resource` type). This is a resource that may be present in dist tarballs but not in the source tree. If the resource is present and we're not in a Git checkout, then we use it directly instead of generating it. This is used for the first time in this commit for the gresource c/h files, which depend on a variety of external tools (blueprint-compiler, glib-compile-resources, etc.) that we do not want to require downstream users/packagers to have and we also do not want to worry about them having the right versions. This also adds a check for `distcheck` to ensure our distribution contains all the expected files.
2025-03-18CI: Add checks for blueprint compiler / Nix refactorsJeffrey C. Ollie
1. Refactored Nix devshell/package to make it easier to keep LD_LIBRARY_PATH & buildInputs in sync (plus make it easier to re-use in other Nix environment). 2. Added a CI job to ensure that Blueprints are formatted correctly and that they will compile using `blueprint-compiler` 0.16.0. 3. Reformatted all Blueprints with `blueprint-compiler format`.
2025-03-16update zon2nixJeffrey C. Ollie
Upstream is now mostly pure Zig and the build.zig.zon.* files are generated directly by zon2nix. The JSON file is no longer used as an intermediate file but is retained for downstream packager usage.
2025-03-13pkg/glfwMitchell Hashimoto
Closes #6702 This removes our mach-glfw dependency and replaces it with an in-tree pkg/glfw that includes both the source for compiling glfw as well as the Zig bindings. This matches the pattern from our other packages. This is based on the upstream mach-glfw work and therefore includes the original license and copyright information. The reasoning is stated in the issue but to summarize for the commit: - mach-glfw is no longer maintained, so we have to take ownership - mach-glfw depended on some large blobs of header files to enable cross-compilation but this isn't something we actually care about, so we can (and do) drop the blobs - mach-glfw blobs were hosted on mach hosts. given mach-glfw is unmaintained, we can't rely on this hosting - mach-glfw relied on a "glfw" package which was owned by another person to be Zig 0.14 compatible, but we no longer need to rely on this - mach-glfw builds were outdated based on latest Zig practices
2025-03-11nix: must not inject xcrun into PATH on macOSMitchell Hashimoto
2025-03-05gtk: add localization support, take 3 (#6004)Leah Amelia Chen
This is my third (!) attempt at implementing localization support. By leveraging GTK builder to do most of the `gettext` calls, I can avoid the whole mess about missing symbols on non-glibc platforms. Added some documentation too for contributors and translators, just for good measure. Supersedes #5214, resolves the GTK half of #2357
2025-03-03gtk: add localization support, take 3Leah Amelia Chen
This is my third (!) attempt at implementing localization support. By leveraging GTK builder to do most of the `gettext` calls, I can avoid the whole mess about missing symbols on non-glibc platforms. Added some documentation too for contributors and translators, just for good measure.
2025-02-28gtk: implement quick terminalLeah Amelia Chen
Using `gtk4-layer-shell` still seems like the path of least resistance, and to my delight it pretty much Just Works. Hurrah! This implementation could do with some further polish (e.g. animations, which can be implemented via libadwaita's animations API, and global shortcuts), but as a MVP it works well enough. It even supports tabs! Fixes #4624.
2025-02-15nix: use snapcraft only on LinuxMitchell Hashimoto
2025-02-15Merge remote-tracking branch 'origin/add_snap_package' into add_snap_packageKen VanDine
2025-02-15Add snap to nix, add arm64 buildersMitchell Hashimoto
2025-02-14nix: snapcraft should only be installed on LinuxMitchell Hashimoto
2025-02-14Add snap to nix, add arm64 buildersMitchell Hashimoto
2025-02-14build: generate a build.zig.zon.txt file for easy zig fetch scriptingJeffrey C. Ollie
This fixes a regression in 1.1.1/1.1.2 where our PACKAGING docs mention using `fetch-zig-cache.sh` but it was removed. This commit adds it back, generating its contents from the build.zig.zon file (via zon2nix which we use for our Nix packaging). For packagers, there are no dependency changes: you still need Zig and POSIX sh. For release time, Ghostty has a new dependency on `jq` but otherwise the release process is the same. The check-zig-cache.sh script is updated to generate the new build.zig.zon.txt file.
2025-02-12gtk: add support for using GTK Builder UI files and BlueprintsJeffrey C. Ollie
Adds buildtime and comptime checks to make sure that Blueprints/UI files are availble and correctly formed. Will also compile Blueprints to UI files so that they are available to GTK code.
2025-02-11nix: use zig2nix to manage nix cache/depsJeffrey C. Ollie
This brings the internal package more in line with how the nixpkgs package is built. It also handles recursive dependencies better than the current system.
2025-02-10gtk: introduce Zig bindings for GTK/GObjectLeah Amelia Chen
`zig-gobject` is a set of GObject bindings that allow us to write GTK-facing code in Zig instead of getting hands dirty with C. It's been tested and refined in real-life applications and several GTK contributors agree that it is a marked improvement over using the C API directly, such as allowing method call syntax and avoiding many manual `@ptrCast`s. This commit doesn't actually contain any changes to our preexisting GTK code — the migration process is intended to begin in chunks, firstly in self-contained components (e.g. the header bar, overlays, etc.), and then full-scale migration can begin when we remove non-Adwaita GTK builds for 1.2. (After all, why port code that you'll remove later either way?)
2025-01-05build: add waylandLeah Amelia Chen
2024-12-17nix: address warning to use toplevel adwaita-icon-themeAnund
2024-12-05flake: update to Nix 24.11Mitchell Hashimoto
2024-10-24ci: add signing and tarball generation to release-tip workflowMitchell Hashimoto
2024-10-24build: use Zig system packaging optionsMitchell Hashimoto
This allows dynamically linking against system libraries, which is particularly useful for packaging.
2024-10-14font/sprite: replace pixman with z2d, extend Box coverageQwerasd
More complete coverage of the Symbols For Legacy Computing block, including characters from Unicode 16.0. Pixman and the web canvas impl for Canvas have been removed in favor of z2d for drawing, since it has a nicer API with more powerful methods, and is in Zig with no specific platform optimizations so should compile to wasm no problem.
2024-10-14refactor(nix): stdenv.isX -> stdenv.hostPlatform.isXisabel
In preparation for the deprecation of `stdenv.isX` https://github.com/NixOS/nixpkgs/commit/e0464e47880a69896f0fb1810f00e0de469f770a
2024-09-27nix: remove tracy from the devshellJeffrey C. Ollie
2024-09-03nix: remove ZLSMitchell Hashimoto
Fixes #2171 ZLS has caused us issues in our Nix shell before and I noted when we first added it that we probably shouldn't. We now pin to release versions of Zig so I think its reasonable to expect developers to have ZLS installed themselves with the proper version or not use it at all.
2024-08-05chore: clean up typosŁukasz Niemier
2024-04-11nix: do not build ZLS on linux aarch64, see commentMitchell Hashimoto
2024-03-29nix: use packages = instead of (native)buildInputs as that is recommendedRGBCube
2024-02-07add hyperfine to the nix development environmentJeffrey C. Ollie
2024-02-05simd: basic ISA detection, boilerplateMitchell Hashimoto
2024-01-21Generate documenation (manpages, etc.) from help strings.Jeffrey C. Ollie
2023-12-16nix: only add shellhook on linuxMitchell Hashimoto
2023-12-16nix: fix GTK icons for debug buildsDenys Pavlov
Set `XDG_DATA_DIRS` in `nix develop` shell to include default Gnome icon sets and gsettings schemas. Sourced from [nixos wiki](https://nixos.wiki/wiki/Development_environment_with_nix-shell#No_GSettings_schemas_are_installed_on_the_system).
2023-12-12Use Alejandra to format Nix modules.Jeffrey C. Ollie
2023-12-08Add garnix cache and clean up all nix codeRGBCube