docs: add nix syntax highlighting

This commit is contained in:
Martin Toman 2022-08-10 10:07:30 -07:00
parent 18c8e247b5
commit 71e4ba973a
5 changed files with 11 additions and 5 deletions

View File

@ -48,7 +48,7 @@ Unit tests can be executed via `nix run .#tests-unit`
Add an example flake under `./examples/name-of-example`.
The flake can be tested via:
```command
```shell
nix run .#tests-examples name-of-example --show-trace
```
The flake will be tested in the CI-pipeline as well.
@ -72,7 +72,7 @@ Further instructions are contained in the template in form of code comments.
Add an example flake under `./examples/name-of-example`.
The flake can be tested via:
```command
```shell
nix run .#tests-examples name-of-example --show-trace
```
The flake will be tested in the CI-pipeline as well.

View File

@ -14,7 +14,7 @@ dream2nix.lib.init {
```
this file should look like this:
```nix
{dlib, lib, config, ...}:
{ dlib, lib, config, ... }:
{
subsystems.rust.translators.example-translator = ./rust-translator.nix;
# you can declare modules using functions here

View File

@ -114,7 +114,7 @@ Poetry uses `pyproject.toml` and `poetry.lock` to lock dependencies
- Input: pyproject.toml, poetry.lock (toml)
- Translator: written in pure nix, reading the toml input and generating the generic lock format
- Generic Lock (for explanatory purposes dumped to json and commented):
```json5
```json
{
// generic lock format version
"version": 1,

View File

@ -17,7 +17,7 @@ This translator simply executes `pip download` on the given source and observes
The downside of this approach is, that this translator cannot be used with a granular builder. It does not understand the exact relation between the dependencies, and therefore it only allows to build all dependencies in one large derivation.
#### **pip** optional translator arguments
```
```nix
{{#include ../../../src/subsystems/python/translators/pip/args.nix}}
```

6
docs/theme/highlight.js vendored Normal file

File diff suppressed because one or more lines are too long