summaryrefslogtreecommitdiff
path: root/modules
AgeCommit message (Collapse)Author
2023-07-12Update modules/services/cachix-agent.nixDomen Kožar
Co-authored-by: Michael Hoang <Enzime@users.noreply.github.com>
2023-07-12cachix-agent: clarify what should be in the token fileDomen Kožar
2023-07-12flake: use `nix-darwin` instead of `darwin`Michael Hoang
2023-07-12etc: use `.before-nix-darwin` instead of `.orig`Michael Hoang
2023-07-11etc: fail if we can't add a fileMichael Hoang
Fixes #598
2023-07-11doc: store a copy of known filesMichael Hoang
2023-07-11readme: update with new flaky instructionsMichael Hoang
2023-07-11Allow flaky installation with `darwin-rebuild`Michael Hoang
2023-07-11flake: add `packages.darwin-{option,rebuild}`Michael Hoang
2023-07-10Add system.systemBuilderCommands and systemBuilderArgsMarco Rebhan
These are the equivalents of the NixOS options with the same name, introduced in https://github.com/NixOS/nixpkgs/commit/d3ac0938a7a0ce6455fc580f16eb7476cca87dc6. Allows running extra commands while building the system configuration output, for example to add extra files into the output directory, and passing arguments to the system builder's mkDerivation.
2023-07-10nix: Remove readOnlyStore option as it has no effectAndrew Marshall
This being under `nix` in upstream is misleading as it is only used in the NixOS boot stage, not as configuration for the Nix daemon.
2023-07-10Fix spellingAndrew Marshall
2023-07-10trezord: Add launchd user agent service module for configuring trezordmitchmindtree
This adds a small module for configuring the trezor-bridge service, trezord. This service enables users to interact with their Trezor hardware wallet through the trezor suite web interface, or to use the device for U2F auth, SSH login, GPG or password mgmt. https://trezor.io/learn/a/what-is-trezor-bridge The options were copied directly from the nixos service module here: https://github.com/NixOS/nixpkgs/blob/9d6e454b857fb472fa35fc8b098fa5ac307a0d7d/nixos/modules/services/hardware/trezord.nix#L16 The implementation was adapted from the nixos module's systemd service to a launchd user agent. Tested successfully locally on an Air M2.
2023-07-10fix zsh eating output without new line endingCuichen Li
2023-07-09Merge pull request #723 from emilazy/rationalize-nixpkgs-handlingDaiderd Jordan
Rationalize handling of Nixpkgs
2023-07-09eval-config: rationalize handling of NixpkgsEmily
This is a big change that disentangles a lot of mistaken assumptions about mixing multiple versions of Nixpkgs, treating external flake inputs as gospel for the source of Nixpkgs and nix-darwin, etc.; the end result should be much simpler conceptually, but it will be a breaking change for anyone using `eval-config.nix` directly. Hopefully that shouldn't be a big issue, as it is more of an internal API and it's quite likely that existing uses may have been broken in the same way the internal ones were. It was previously easy to get into a state where your `lib` comes from nix-darwin's `nixpkgs` input or a global channel and your `pkgs` comes from another major version of Nixpkgs. This is pretty fundamentally broken due to the coupling of `pkgs` to its corresponding `lib`, but the brokenness was hidden much of the time until something surfaced it. Now there is exactly one mandatory `lib` input to system evaluation, and the handling of various additional options like `pkgs` and `system` can be done modularly; maintaining backwards compatibility with the previous calling convention is punted to the `default.nix` and `lib.darwinSystem` entry points. `inputs` is no longer read by nix-darwin or special in any way, merely a convention for user code, and the argument is retained in the entry points only for backwards compatibility. All correct invocations of the entry points should keep working after this change, and some previously-broken ones should be fixed too. The documentation and template have been adjusted to show the newly-recommended modular way of specifying various things, but no deprecation warnings have been introduced yet by this change. There is one potential, mostly cosmetic regression: `system.nixpkgsRevision` and related options are less likely to be set than before, in cases where it is not possible to determine the origin of the package set. Setting `nixpkgs.source` explicitly will make this work again, and I hope to look into sending changes upstream to Nixpkgs to make `lib.trivial.revisionWithDefault` behave properly under flakes, which would fix this regression and potentially allow reducing some of the complexity. Fixes: #669
2023-07-09version: rewrite Git revision logicEmily
We trust the version information from `nixpkgs.source` when `pkgs` was constructed by the `nixpkgs` module or `nixpkgs.source` was explicitly set by the configuration. Otherwise, we rely on Nixpkgs to report its own version, which handles the same cases as the old logic and opens the door to Nixpkgs automatically reporting the correct revision when using flakes.
2023-07-09version: default Git revision options to `null`Emily
This allows for more uniform handling in the documentation generator, and avoids lying about the Git reference being `master` internally.
2023-07-09linux-builder: fix evaluation errorsMichael Hoang
- `modules` cannot be a nested list - `nix.settings.extra-trusted-users` might not be set
2023-07-08nixpkgs: rebase module on latest NixOSEmily
This is based on the current NixOS `nixpkgs` module, adjusted for the nix-darwin context and without adding the options due for deprecation in NixOS. This gives us the ability to set the package set modularly through `nixpkgs.pkgs` and builds up infrastructure for handling user-specified Nixpkgs instantiations more robustly. The cross-compilation options are currently not very useful due to even Darwin->Darwin cross-compilation not being wholly functional yet, but it looks feasible to build an `aarch64-darwin` system from `x86_64-darwin` with some patching and it should be possible to make cross-compilation more widely supported after the Darwin SDK situation in Nixpkgs improves. One casualty is the error for setting `nixpkgs.*` options when overriding the package set. That could be ported over to this new scheme, but it'd increase divergence with the NixOS module and reduce cross-compatibility of configurations, so I lean towards adding it upstream to NixOS if anything. (But if people want to keep it I can add it back.)
2023-07-08documentation: use feature test for docs generatorEmily
This should be less brittle than the version-based check, although arguably this kind of `lib.version` mismatch should break as early as possible... Fixes: #718
2023-07-08nix/linux-builder: initMichael Hoang
2023-07-02Merge pull request #711 from Enzime/fix/magicdnsDomen Kožar
tailscale: improve MagicDNS setup
2023-06-30documentation: Link to nixpkgs master if rev is unknownRobert Hensing
This fixes error: The option `system.nixpkgsRevision' is used but not defined.
2023-06-27feat: add dock icon magnification settingsPiotr Żelazko
2023-06-27tailscale: improve MagicDNS setupMichael Hoang
2023-06-25fix darwin-option descriptionsDaiderd Jordan
Also drops the eval hacks in favour of jq.
2023-06-25Merge pull request #675 from serokell/rvem/update-buildkite-moduleDaiderd Jordan
buildkite-agent: fix launchd daemon environment
2023-06-24doc/manual: use `nixos-render-docs`Emily
Now that all the DocBook documentation is gone, we can switch to the new NixOS documentation generator. No meaningful change in HTML output, except that I removed the rather pointless preface and changed the title accordingly. Manual page output is greatly improved; it was kind of broken before. The `sed` hack is pretty gross but I have confirmed that nixpkgs will be happy to accept a PR to make things a little more customizable. This also drops the `manual` alias (deprecated in nixpkgs in 2018 and imported into nix-darwin), and `manualEpub` (because the NixOS documentation generator doesn't support it and also nobody wants this as an ebook).
2023-06-24treewide: convert all option docs to MarkdownEmily
This process was automated by [my fork of `nix-doc-munge`]; thanks to @pennae for writing this tool! It automatically checks that the resulting documentation doesn't change, although my fork loosens this a little to ignore some irrelevant whitespace and typographical differences. As of this commit there is no DocBook remaining in the options documentation. You can play along at home if you want to reproduce this commit: $ NIX_PATH=nixpkgs=flake:nixpkgs/c1bca7fe84c646cfd4ebf3482c0e6317a0b13f22 \ nix shell nixpkgs#coreutils \ -c find . -name '*.nix' \ -exec nix run github:emilazy/nix-doc-munge/0a7190f600027bf7baf6cb7139e4d69ac2f51062 \ {} + [my fork of `nix-doc-munge`]: https://github.com/emilazy/nix-doc-munge
2023-06-24treewide: manually convert some docs to MarkdownEmily
These all use DocBook markup too complex for `nix-doc-munge` to handle, have syntax that clashes with Markdown, or already contain Markdown syntax that currently isn't rendering correctly. Converting DocBook list syntax makes me think that maybe Markdown isn't so bad after all.
2023-06-24{offlineimap,tailscale}: fix `enable` option docsEmily
The argument to `mkEnableOption` is automatically wrapped in a full sentence.
2023-06-24treewide: tweak DocBook docs for conversionEmily
These help `nix-munge-doc` automate more of the Markdown conversion process. See the following nixpkgs commits for explanations of many of these changes: * https://github.com/NixOS/nixpkgs/commit/275a34e0d8a937a81b267e47302dd8a92fa781df * https://github.com/NixOS/nixpkgs/commit/694d5b19d30bf66687b42fb77f43ea7cd1002a62 * https://github.com/NixOS/nixpkgs/commit/f1d39b6d6187997b630647400c5efe5b01e06a23 * https://github.com/NixOS/nixpkgs/commit/16102dce2fbad670bd47dd75c860a8daa5fe47ad I couldn't think of any particularly good way to format the `system.defaults` breadcrumbs, so I just made them standalone paragraphs. They weren't rendering correctly in DocBook anyway.
2023-06-24doc/manual: use `nixosOptionDoc`Emily
The only change to `options.json` are that the `declarations` fields now contain correct GitHub URLs. The changes to the HTML manual are all either strict improvements: * "Declared by:" links point to the correct URLs. * `lib.mdDoc` documentation is included. or else trivial: * Additional whitespace in the HTML source. * Some interchange of `<pre class="programlisting">` and `<code class="literal">`. * Fancy quotes used in some type descriptions. `optionsDocBook` is exported temporarily as it is used by `nix-doc-munge` for the Markdown conversion process. This drops support for building the manual on 22.11, which lacks a complete implementation of this processor, and provides stubbed-out manual packages with an explanation on that version.
2023-06-24wq-quick: document `publicKey` optionEmily
All exposed options should have documentation, and `nixosOptionDoc` will give an error if it's missing.
2023-06-23activity monitor: change settings to nullzowoq
treewide these seem to be the only settings that aren't unset by default which seems inconsistent
2023-06-21buildkite-agent: fix launcd daemon environmentRoman Melnikov
Add missing 'NIX_SSL_CERT_FILE'
2023-06-20Merge pull request #671 from sxyazi/pr-e0f2168dDaiderd Jordan
Add `mouseDriverCursorSize` option
2023-06-20Merge pull request #672 from sxyazi/pr-af01ed5dDaiderd Jordan
Add `AppleScrollerPagingBehavior` option
2023-06-20Merge pull request #673 from sxyazi/pr-4df4da65Daiderd Jordan
feat: add `AppleWindowTabbingMode` option
2023-06-20Merge pull request #679 from dbaynard/patch-1Daiderd Jordan
Document font overriding behaviour
2023-06-20Merge pull request #686 from CathalMullan/masterDaiderd Jordan
nix: Add build machines protocol option.
2023-06-18Merge pull request #695 from jmmaloney4/masterDomen Kožar
add ipfs service
2023-06-18add ipfs serviceJack Maloney
2023-06-17templates.flake: add contents of simple.nixMichael Hoang
2023-06-17flake: add template with basic flake configMichael Hoang
2023-06-10nix: Add build machines protocol option.Cathal Mullan
2023-06-08Merge pull request #681 from cole-h/auto-uidDomen Kožar
system/checks: allow disabling the buildUsers check
2023-06-08Merge pull request #677 from Enzime/fix/ssh-pubkeysDomen Kožar
ssh: fix public keys in home directory not working
2023-06-08ssh: fix public keys in home directory not workingMichael Hoang
Added `services.openssh.authorizedKeysFiles` option from NixOS.