mirror of
https://github.com/nim-lang/Nim.git
synced 2025-12-28 17:04:41 +00:00
* Implement Pandoc Markdown concise link extension This implements https://github.com/nim-lang/Nim/issues/20127. Besides reference to headings we also support doing references to Nim symbols inside Nim modules. Markdown: ``` Some heading ------------ Ref. [Some heading]. ``` Nim: ``` proc someFunction*() ... ... ## Ref. [someFunction] ``` This is substitution for RST syntax like `` `target`_ ``. All 3 syntax variants of extension from Pandoc Markdown are supported: `[target]`, `[target][]`, `[description][target]`. This PR also fixes clashes in existing files, particularly conflicts with RST footnote feature, which does not work with this PR (but there is a plan to adopt a popular [Markdown footnote extension](https://pandoc.org/MANUAL.html#footnotes) to make footnotes work). Also the PR fixes a bug that Markdown links did not work when `[...]` section had a line break. The implementation is straightforward since link resolution did not change w.r.t. RST implementation, it's almost only about new syntax addition. The only essential difference is a possibility to add a custom link description: form `[description][target]` which does not have an RST equivalent. * fix nim 1.0 gotcha
42 lines
2.0 KiB
Plaintext
42 lines
2.0 KiB
Plaintext
::
|
|
|
|
nim command [options] [projectfile] [arguments]
|
|
|
|
Command:
|
|
//compile, c compile project with default code generator (C)
|
|
//r compile to $nimcache/projname, run with `arguments`
|
|
using backend specified by `--backend` (default: c)
|
|
//doc generate the documentation for inputfile for
|
|
backend specified by `--backend` (default: c)
|
|
|
|
Arguments:
|
|
arguments are passed to the program being run (if --run option is selected)
|
|
|
|
Options:
|
|
-p, --path:PATH add path to search paths
|
|
-d, --define:SYMBOL(:VAL)
|
|
define a conditional symbol
|
|
(Optionally: Define the value for that symbol,
|
|
see: "compile time define pragmas")
|
|
-u, --undef:SYMBOL undefine a conditional symbol
|
|
-f, --forceBuild:on|off force rebuilding of all modules
|
|
--stackTrace:on|off turn stack tracing on|off
|
|
--lineTrace:on|off turn line tracing on|off
|
|
--threads:on|off turn support for multi-threading on|off
|
|
-x, --checks:on|off turn all runtime checks on|off
|
|
-a, --assertions:on|off turn assertions on|off
|
|
--opt:none|speed|size optimize not at all or for speed|size
|
|
Note: use -d:release for a release build!
|
|
--debugger:native use native debugger (gdb)
|
|
--app:console|gui|lib|staticlib
|
|
generate a console app|GUI app|DLL|static library
|
|
-r, --run run the compiled program with given arguments
|
|
--eval:cmd evaluate nim code directly; e.g.: `nim --eval:"echo 1"`
|
|
defaults to `e` (nimscript) but customizable:
|
|
`nim r --eval:'for a in stdin.lines: echo a'`
|
|
--fullhelp show all command line switches
|
|
-h, --help show this help
|
|
-v, --version show detailed version information
|
|
|
|
Note, single letter options that take an argument require a colon. E.g. -p:PATH.
|