https://github.com/daelvn/fir
🌲Language-agnostic documentation generator.
https://github.com/daelvn/fir
documentation-generator language-agnostic lua moonscript
Last synced: 4 months ago
JSON representation
🌲Language-agnostic documentation generator.
- Host: GitHub
- URL: https://github.com/daelvn/fir
- Owner: daelvn
- License: unlicense
- Created: 2021-01-10T13:41:20.000Z (almost 5 years ago)
- Default Branch: main
- Last Pushed: 2024-10-07T22:47:35.000Z (about 1 year ago)
- Last Synced: 2025-04-19T19:25:03.517Z (7 months ago)
- Topics: documentation-generator, language-agnostic, lua, moonscript
- Language: MoonScript
- Homepage: https://daelvn.github.io/fir/
- Size: 2.05 MB
- Stars: 9
- Watchers: 1
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE.md
- Roadmap: ROADMAP.md
Awesome Lists containing this project
README
# Fir 2





Fir is a language-agnostic documentation generator framework. It is fully modular, which means you can mix a comment extractor with a different comment parser and emitter (but you aren't going to go through the hassle of writing anything). A set of generic modules for generating Markdown documentation is provided, don't expect much more (unless you press me to write more).
> [!TIP]
> Check out the new Fir 2 update! Renewed, with symbol support, verbatim inputs, and a little more. [Changelog below](#2).
## Table of contents
- [Fir 2](#fir-2)
- [Table of contents](#table-of-contents)
- [Install](#install)
- [Compiling from source](#compiling-from-source)
- [Changelog](#changelog)
- [Documentation](#documentation)
- [Extra features](#extra-features)
- [License](#license)
## Install
You can install Fir via LuaRocks:
```
$ luarocks install fir
```
### Compiling from source
If you want to compile from source, you will need to install the following dependencies from LuaRocks:
- `argparse` (CLI)
- `ansikit` (CLI, optional if using CLI with `--silent`)
- `lpath` (Library, CLI)
- `lrexlib-pcre2` (Library, CLI)
- `yuescript` (Compiling)
- `alfons` (Compiling)
- `rockbuild` (Compiling)
Then, simply run `alfons compile make -v 1.0`. To clean the project, simply `alfons clean`.
## Changelog
### 2.x
- **2.0.0** (04.10.2024)
Fir 2 is being released! Out of the necessity to use a more modern documentation for my other, better project, [Alfons](https://github.com/daelvn/alfons), I decided to update this project. Here's the main changes:
- **Revamped test suite generator.** The `tests` format now actually works, and generates robust tests from your documentation that can check for many conditions. It's even [TAP](https://testanything.org/tap-version-14-specification.html) compliant for your CI needs!
- **Symbol linking.** Fir CLI using the Generic backend will now collect all symbols and let you link to them with `@@@` syntax.
- **Verbatim inputs.** Those inputs will be copied over directly to the output folder.
- **Alfons integration.** Fir automatically installs a loadable [Alfons](https://github.com/daelvn/alfons) task, so you can integrate it into your Alfons workflows. Use `load 'fir'` to load it.
- **Symbol summaries can now be longer than one line.** The summary ends on the first line that does not begin with a \ character.
- **Aliases are deranked.** Now (under the Generic backend) aliases are not put beside the name.
- **Better error reporting.** No more unparsable errors.
- **Output for MkDocs.** The Generic Markdown emitter now has specific MkDocs options.
- **Updated documentation.** It's easier to understand how the fuck to use this.
- **Documentation now uses [Material for MkDocs](https://squidfunk.github.io/mkdocs-material).** For a more clean, updated and powerful look and feel.
- **Switched to more robust libraries.** [lpath](https://github.com/starwing/lpath) for FS operations, [lrexlib on PCRE2 backend](https://github.com/rrthomas/lrexlib) for symbol syntax.
- **Updated from MoonPlus to Yuescript.** MoonPlus has not been a thing for years and instead transitioned into being [Yuescript](https://yuescript.org).
## Documentation
Check out the documentation [here](//daelvn.github.io/fir/).
## Extra features
I kindly welcome new features that anyone wants to suggest or add! Feel free to open an issue or PR.
## License
This project is [Unlicensed](LICENSE.md), and released to the public domain. Do whatever you wish with it!