Skip to content

Commit c671c2e

Browse files
authored
Merge pull request #2262 from Janik-Haag/master
Add nix to default languages
2 parents 8ae86d4 + c9df8dd commit c671c2e

File tree

5 files changed

+13
-1
lines changed

5 files changed

+13
-1
lines changed

CONTRIBUTING.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -148,7 +148,7 @@ The following are instructions for updating [highlight.js](https://highlightjs.o
148148
1. Clone the repository at <https://github.com/highlightjs/highlight.js>
149149
1. Check out a tagged release (like `10.1.1`).
150150
1. Run `npm install`
151-
1. Run `node tools/build.js :common apache armasm coffeescript d handlebars haskell http julia nginx nim properties r scala x86asm yaml`
151+
1. Run `node tools/build.js :common apache armasm coffeescript d handlebars haskell http julia nginx nim nix properties r scala x86asm yaml`
152152
1. Compare the language list that it spits out to the one in [`syntax-highlighting.md`](https://github.com/camelid/mdBook/blob/master/guide/src/format/theme/syntax-highlighting.md). If any are missing, add them to the list and rebuild (and update these docs). If any are added to the common set, add them to `syntax-highlighting.md`.
153153
1. Copy `build/highlight.min.js` to mdbook's directory [`highlight.js`](https://github.com/rust-lang/mdBook/blob/master/src/theme/highlight.js).
154154
1. Be sure to check the highlight.js [CHANGES](https://github.com/highlightjs/highlight.js/blob/main/CHANGES.md) for any breaking changes. Breaking changes that would affect users will need to wait until the next major release.

guide/src/format/theme/syntax-highlighting.md

+1
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,7 @@ your own `highlight.js` file:
4545
- markdown
4646
- nginx
4747
- nim
48+
- nix
4849
- objectivec
4950
- perl
5051
- php

src/theme/highlight.js

+1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

test_book/src/languages/README.md

+1
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@ This Currently contains following languages
2828
- markdown
2929
- nginx
3030
- nim
31+
- nix
3132
- objectivec
3233
- perl
3334
- php

test_book/src/languages/highlight.md

+9
Original file line numberDiff line numberDiff line change
@@ -563,6 +563,15 @@ int main(int argc, const char * argv[]) {
563563

564564
```
565565
566+
## nix
567+
568+
```nix
569+
let
570+
world = "World!";
571+
in
572+
"Hello " + world
573+
```
574+
566575
## perl
567576

568577
```perl

0 commit comments

Comments
 (0)