update unexplrd-mise template

This commit is contained in:
2026-03-29 17:00:20 +03:00
parent ea4a5a007b
commit ffa3ce0bdc
3 changed files with 24 additions and 9 deletions
+17 -3
View File
@@ -19,7 +19,6 @@ This example has the following structure:
│ ├── error-log.jpg │ ├── error-log.jpg
│ └── ... │ └── ...
├── doc.toml ├── doc.toml
├── appendices.typ
├── main.typ ├── main.typ
└── utils.typ └── utils.typ
``` ```
@@ -30,13 +29,28 @@ This example has the following structure:
- Fixed dependencies: locked Typst version, `nure` package fetched from a specific commit - Fixed dependencies: locked Typst version, `nure` package fetched from a specific commit
- Customizable: it's just a `.toml` file, modify it according to your needs - Customizable: it's just a `.toml` file, modify it according to your needs
## Mise tasks ## Project structure
All work contents are stored in `src/` to avoid clutter.
### Files
- `src/doc.toml`: work-specific settings, could be auto-filled, see (TODO: add a demo nushell script)
- `src/utils.typ`: utilities and functions used across the project
- `src/main.typ`: main entry file
### Directories
- `src/chapters/`: for breaking up the project into multiple files, if necessary
- `src/figures/`: for images and pictures
- `src/assets/`: other non-image, non-typst files
## Mise
### Tasks
- `compile`: Execute `typst compile` on `src/main.typ` - `compile`: Execute `typst compile` on `src/main.typ`
- `watch`: Execute `typst watch` on `src/main.typ` - `watch`: Execute `typst watch` on `src/main.typ`
- `fetch-nure-package`: clone package git repository to a directory specified in `[vars]` - `fetch-nure-package`: clone package git repository to a directory specified in `[vars]`
- `update-package-rev`: updates `vars.nure_package_rev` with the last commit id from the specified branch (`vars.nure_package_ref`) - `update-package-rev`: updates `vars.nure_package_rev` with the last commit id from the specified branch (`vars.nure_package_ref`)
## Examples ### Examples
- A patch to add new subjects to the package: - A patch to add new subjects to the package:
```diff ```diff
diff --git a/src/config/universities.yaml b/src/config/universities.yaml diff --git a/src/config/universities.yaml b/src/config/universities.yaml
@@ -1,4 +0,0 @@
#import "utils.typ": code
// = Код програми sample.c <foo-c>
// #code(read("/assets/sample.c"))
+7 -2
View File
@@ -9,8 +9,9 @@
// #show: style.dstu // #show: style.dstu
#show: pz-lb.with(..toml("doc.toml"), title: "") // set title to none if empty #show: pz-lb.with(..toml("doc.toml"), title: "") // set title to none if empty
// Useful snippets /// Useful snippets
/// Import a .csv table
// #figure( // #figure(
// caption: [], // caption: [],
// table( // table(
@@ -20,4 +21,8 @@
// ), // ),
// ) // )
// #style.appendices(include "appendices.typ") /// Appendices
// #style.appendices(include "chapters/appendices.typ")
// or
// #show: style.appendices
// = ...