diff --git a/docs/binary-caching.md b/docs/binary-caching.md index 2189e01db..ad01e1d4e 100644 --- a/docs/binary-caching.md +++ b/docs/binary-caching.md @@ -27,8 +27,8 @@ To specify `pre-commit-hooks` as a cache to pull from and `mycache` to pull from You'll likely not want every user to push to the cache. -It's usually convenient to push [explicitly](./files-and-variables/#devenvlocalnix), for example as part of CI run: +It's usually convenient to push [explicitly](files-and-variables.md#devenvlocalnix), for example as part of CI run: ```shell-session $ echo '{ cachix.push = "mycache"; }' > devenv.local.nix -``` \ No newline at end of file +``` diff --git a/docs/community/contributing.md b/docs/community/contributing.md index f7a19397e..a121e5346 100644 --- a/docs/community/contributing.md +++ b/docs/community/contributing.md @@ -6,7 +6,7 @@ We have a rule that new features need to come with documentation and tests (`dev ## Preparing the `devenv` development environment -1. Follow the [installation instructions for Nix and Cachix](../../getting-started/#installation) and [install direnv](../../automatic-shell-activation/). +1. Follow the [installation instructions for Nix and Cachix](../getting-started.md#installation) and [install direnv](../automatic-shell-activation.md). 2. `git clone https://github.com/cachix/devenv.git` diff --git a/docs/composing-using-imports.md b/docs/composing-using-imports.md index 83fd5ae1e..544676daa 100644 --- a/docs/composing-using-imports.md +++ b/docs/composing-using-imports.md @@ -25,7 +25,7 @@ For example, ``devenv up`` will start both the frontend and backend processes. !!! note - While composing ``devenv.nix`` is a key feature, + While composing ``devenv.nix`` is a key feature, composing ``devenv.yaml`` [hasn't been implemented yet](https://github.com/cachix/devenv/issues/14). -See [devenv.yaml reference](reference/yaml-options.md#inputs) for all supported imports. +See [devenv.yaml reference](reference/yaml-options.md#an-extensive-example) for all supported imports. diff --git a/docs/containers.md b/docs/containers.md index 46802c522..6d54780de 100644 --- a/docs/containers.md +++ b/docs/containers.md @@ -16,7 +16,7 @@ Examples of what `devenv container` can do: - `devenv container build shell`: Generate a container and [start the environment](#entering-the-development-environment), equivalent of using `devenv shell`. - `devenv container build processes`: Generate a container and [start processes](#running-processes), equivalent of using `devenv up`. -- `devenv container --registry docker://ghcr.io/ copy `: [Copy the container](#copying-container-to-a-registry) `` into the **GitHub package registry**. +- `devenv container --registry docker://ghcr.io/ copy `: [Copy the container](#copying-a-container-to-a-registry) `` into the **GitHub package registry**. - `devenv container run `: Run the container `` using **Docker**. ## Entering the development environment @@ -46,7 +46,7 @@ $ devenv container run shell (devenv) bash-5.2# python Python 3.10.9 (main, Dec 6 2022, 18:44:57) [GCC 12.2.0] on linux Type "help", "copyright", "credits" or "license" for more information. ->>> +>>> ``` ## Running processes @@ -63,7 +63,7 @@ A common deployment strategy is to run each [process](./processes.md) as an entr processes.hello-nix.exec = "while true; do echo 'Hello Nix!' && sleep 1; done"; # Exclude the source repo to make the container smaller. - containers."processes".copyToRoot = null; + containers."processes".copyToRoot = null; } ``` @@ -108,7 +108,7 @@ If you're building binaries as part of the development environment, you can choo { # watch local changes and build the project to ./dist processes.build.exec = "${pkgs.watchexec}/bin/watchexec my-build-tool"; - + containers."prod".copyToRoot = ./dist; containers."prod".startupCommand = "/mybinary serve"; } @@ -129,7 +129,7 @@ To copy a container into a registry use `copy` subcommand: $ devenv container --registry docker:// copy processes ``` -Another common example is deploying to [fly.io](https://fly.io). +Another common example is deploying to [fly.io](https://fly.io). Any arguments passed to `--copy-args` are forwarded to [skopeo copy](https://github.com/containers/skopeo/blob/main/docs/skopeo-copy.1.md#options): @@ -159,7 +159,7 @@ If you want to provide the `openssl` package to native and container environment { pkgs, config, lib, ... }: { - packages = [ pkgs.openssl ] + packages = [ pkgs.openssl ] ++ lib.optionals (!config.container.isBuilding) [ pkgs.git ]; } ``` diff --git a/docs/inputs.md b/docs/inputs.md index 67cbc3852..1c9a74d32 100644 --- a/docs/inputs.md +++ b/docs/inputs.md @@ -57,17 +57,17 @@ There are a few special inputs passed into `devenv.nix`: - `pkgs` is a `nixpkgs` input containing [all of the available packages](./packages.md#searching) for your system. - `lib` is [a collection of functions for working with Nix data structures](https://nixos.org/manual/nixpkgs/stable/#sec-functions-library). You can use [noogle](https://noogle.dev/) to search for a function. -- `config` is the final resolved configuration for your developer environment, which you can use to reference any other options set in [devenv.nix](./reference/options.md). +- `config` is the final resolved configuration for your developer environment, which you can use to reference any other options set in [devenv.nix](./reference/options.md). Since Nix supports lazy evaluation, you can reference any option you define in the same file as long as it doesn't reference itself! !!! note ``...`` is a catch-all pattern for any additional inputs, so you can safely omit the inputs you're not using. -See [devenv.yaml reference](reference/yaml-options.md#inputs) for all supported inputs. +See [devenv.yaml reference](reference/yaml-options.md) for all supported inputs. ## Locking and updating inputs When you run any of the commands, `devenv` resolves inputs like `github:NixOS/nixpkgs/nixpkgs-unstable` into a commit revision and writes them to `devenv.lock`. This ensures that your environment is reproducible. -To update an input to a newer commit, run `devenv update` or read the [devenv.yaml reference](reference/yaml-options.md#inputs) to learn how to pin down the revision/branch at the input level. +To update an input to a newer commit, run `devenv update` or read the [devenv.yaml reference](reference/yaml-options.md) to learn how to pin down the revision/branch at the input level. diff --git a/docs/reference/options.md b/docs/reference/options.md index 30d137818..fd2b10e6f 100644 --- a/docs/reference/options.md +++ b/docs/reference/options.md @@ -29217,10 +29217,10 @@ string '' [files] ignore-dot = true - + [default] binary = false - + [type.py] extend-glob = [] '' @@ -30981,9 +30981,9 @@ string ``` '' --- - + extends: relaxed - + rules: indentation: enable '' @@ -63007,10 +63007,10 @@ string '' [files] ignore-dot = true - + [default] binary = false - + [type.py] extend-glob = [] '' @@ -64771,9 +64771,9 @@ string ``` '' --- - + extends: relaxed - + rules: indentation: enable '' @@ -65940,7 +65940,7 @@ strings concatenated with “\\n” { debug } - + # Site block example.com { encode gzip @@ -66005,7 +66005,7 @@ string -Use saved config, if any (and prefer over configuration passed with [` caddy.config `](\#caddyconfig)). +Use saved config, if any (and prefer over configuration passed with [` caddy.config `](\#servicescaddyconfig)). @@ -67866,7 +67866,7 @@ strings concatenated with “\\n” ``` '' log4j.rootLogger=INFO, stdout - + log4j.appender.stdout=org.apache.log4j.ConsoleAppender log4j.appender.stdout.layout=org.apache.log4j.PatternLayout log4j.appender.stdout.layout.ConversionPattern=[%d] %p %m (%c)%n @@ -71846,7 +71846,7 @@ strings concatenated with “\\n” ``` '' vcl 4.0; - + backend default { .host = "127.0.0.1"; .port = "80"; @@ -72527,5 +72527,3 @@ list of string *Declared by:* - [https://github.com/cachix/devenv/blob/main/src/modules/top-level.nix](https://github.com/cachix/devenv/blob/main/src/modules/top-level.nix) - - diff --git a/docs/supported-services/caddy.md b/docs/supported-services/caddy.md index d734ff5db..409bc8a29 100644 --- a/docs/supported-services/caddy.md +++ b/docs/supported-services/caddy.md @@ -123,7 +123,7 @@ strings concatenated with “\\n” { debug } - + # Site block example.com { encode gzip @@ -179,7 +179,7 @@ string -Use saved config, if any (and prefer over configuration passed with [` caddy.config `](\#caddyconfig))\. +Use saved config, if any (and prefer over configuration passed with [` caddy.config `](\#servicescaddyconfig))\. diff --git a/mkdocs.yml b/mkdocs.yml index e5f5b4249..8ef0bc97a 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -4,6 +4,12 @@ site_url: "https://devenv.sh" repo_name: "cachix/devenv" repo_url: "https://github.com/cachix/devenv" edit_uri: "edit/main/docs" +strict: true +validation: + omitted_files: warn + absolute_links: info # Or 'relative_to_docs' - new in MkDocs 1.6 + unrecognized_links: warn + anchors: warn # New in MkDocs 1.6 extra_css: - assets/top-level.css theme: diff --git a/src/modules/services/caddy.nix b/src/modules/services/caddy.nix index 790aecf89..11c0312fe 100644 --- a/src/modules/services/caddy.nix +++ b/src/modules/services/caddy.nix @@ -144,7 +144,7 @@ in default = false; type = types.bool; description = '' - Use saved config, if any (and prefer over configuration passed with [`caddy.config`](#caddyconfig)). + Use saved config, if any (and prefer over configuration passed with [`caddy.config`](#servicescaddyconfig)). ''; };