Skip to content

Commit 3128109

Browse files
committed
some markdown tweaks; add changelog/contributing/coc; rewrite paths in readme
1 parent 6982282 commit 3128109

File tree

8 files changed

+40
-19
lines changed

8 files changed

+40
-19
lines changed

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ cd hvcc/
7474
pip3 install -e .
7575
```
7676

77-
Also review our [Contribution Guide](/CONTRIBUTING.md) before opening a pull request.
77+
Also review our [Contribution Guide](CONTRIBUTING.md) before opening a pull request.
7878

7979
## Usage
8080

@@ -168,7 +168,7 @@ Displays all the available parameters and options for hvcc.
168168

169169
## Contact
170170

171-
The Heavy community aims to be safe and inclusive, please read our [Code of Conduct](/CODE_OF_CONDUCT.md) before engaging.
171+
The Heavy community aims to be safe and inclusive, please read our [Code of Conduct](CODE_OF_CONDUCT.md) before engaging.
172172

173173
There are several places where heavy/hvcc conversation is happening:
174174

docs/adr/ADR-003-Control-Rate-Expr.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
# ADR-003: Control Rate Expr
22

33
Date: 2025-12-05
4+
45
Issue: https://github.com/Wasted-Audio/hvcc/issues/21
56

67
## Context

docs/adr/ADR-004-Signal-Rate-Expr.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
# ADR-004: Signal Rate Expr
22

33
Date: 2025-12-05
4+
45
Issue: https://github.com/Wasted-Audio/hvcc/issues/21
56

67
## Context

docs/generators/unity.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -169,7 +169,7 @@ The android NDK comes with a `<NDK>/build/cmake/android.toolchain.cmake` file th
169169

170170
From the hvcc export `unity` directory containing the `CMakeLists.txt`.
171171

172-
```
172+
```shell
173173
cmake -S . -B cmake-build-android -G Ninja \
174174
-DCMAKE_TOOLCHAIN_FILE=$NDK/build/cmake/android.toolchain.cmake \
175175
-DANDROID_ABI=arm64-v8a \
@@ -185,13 +185,13 @@ https://docs.unity3d.com/Manual/PluginInspector.html
185185

186186
iOS builds are unique in that the source code is needed when compiling the Unity game for the device.
187187

188-
Once the game is working as expected in the Unity editor (the macos plugins are required for that) and the heavy C# scripts are correctly attached to the gameobjects, go to `File` > `Build Settings` in the Unity menu. Then generate the Xcode project by selecting iOS platform, adding the required scenes and clicking `Build`.
188+
Once the game is working as expected in the Unity editor (the macos plugins are required for that) and the heavy C# scripts are correctly attached to the gameobjects, go to `File > Build Settings` in the Unity menu. Then generate the Xcode project by selecting iOS platform, adding the required scenes and clicking `Build`.
189189

190190
Open the Xcode project from the directory previously selected in Unity's build menu.
191191

192192
Create a new group in the left-hand side Project explorer section, the group name is not important but in this case we'll called it `heavy`.
193193

194-
Download the [Unity source target](../getting-started/patching.md#using-the-generated-targets) from the patch compile page and copy the contents of the `source/heavy/` folder into the `heavy` Xcode group that was created previously. Make sure to copy every file.
194+
Download the Unity source target from the patch compile page and copy the contents of the `source/heavy/` folder into the `heavy` Xcode group that was created previously. Make sure to copy every file.
195195

196196
![unity_ios_xcode](../img/docs_unity_ios_xcode.png)
197197

docs/generators/wwise.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ Heavy currently supports the following Wwise features:
1818

1919
## Source Generator or FX Unit
2020

21-
The type of plugin that **heavy** generates is dynamically determined depending on the [I/O channel configuration](../getting-started/patching.md#audio-input-output). If an `[adc~]` object exists in the patch the generated plugin with be an FX unit. Otherwise it'll be a source generator plugin.
21+
The type of plugin that **heavy** generates is dynamically determined depending on the [I/O channel configuration](../getting-started/patching.md#audio-inputoutput). If an `[adc~]` object exists in the patch the generated plugin with be an FX unit. Otherwise it'll be a source generator plugin.
2222

2323
## RTPCs
2424

docs/getting-started/index.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ The files that `hvcc` generates are split into two types:
6565

6666
- [Static](https://github.com/Wasted-Audio/hvcc/tree/master/hvcc/generators/ir2c/static): this code is independent of the input patch contents and provides the basic DSP functionality with which generated output can link against. It has a liberal [ISC](https://github.com/Wasted-Audio/hvcc/blob/master/hvcc/generators/ir2c/static/HeavyContext.hpp#L2) licence.
6767

68-
- Generated: this relates to all the source files that use information about the input patch, for example `Heavy_{{name}}.cpp`. By default all these files will have a `Copyright (c) 2018 Enzien Audio, Ltd` header, but this can be modified with the [user copyright argument](../index.md#--copyright-user-copyright).
68+
- Generated: this relates to all the source files that use information about the input patch, for example `Heavy_{{name}}.cpp`. By default all these files will have a `Copyright (c) 2018 Enzien Audio, Ltd` header, but this can be modified with the [user copyright argument](../index.md#-copyright-user-copyright).
6969

7070
## How to start patching for heavy
7171

docs/mkdocs_hooks.py

Lines changed: 20 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,20 @@
1-
import os
2-
import re
1+
import re, os
32

43

54
def python_indent(content):
6-
# Pattern: classic markdown indent (2 spaces) to Python-Markdown indent (4 spaces)
7-
return re.sub(r'^(\ \ -\ .*)', r' \1', content, flags=re.MULTILINE)
5+
""" Pattern: classic markdown indent (2 spaces) to Python-Markdown indent (4 spaces)
6+
Handle both single and double indent. In reverse so we don't overwrite.
7+
"""
8+
# double
9+
content = re.sub(r'^(\ \ \ \ -\ .*)', r' \1', content, flags=re.MULTILINE)
10+
# single
11+
content = re.sub(r'^(\ \ -\ .*)', r' \1', content, flags=re.MULTILINE)
812

13+
return content
914

10-
def on_page_markdown(markdown, page, config, files):
15+
16+
def on_page_markdown(markdown: str, page, config, files):
17+
print(page.file.src_path)
1118
if page.file.src_path == 'index.md':
1219
readme_path = os.path.join(os.path.dirname(config['config_file_path']), 'README.md')
1320
try:
@@ -23,10 +30,18 @@ def on_page_markdown(markdown, page, config, files):
2330

2431
content = python_indent(content)
2532

33+
# file paths
34+
content = content.replace('CONTRIBUTING.md', 'about/contributing.md')
35+
content = content.replace('CODE_OF_CONDUCT.md', 'about/code_of_conduct.md')
36+
2637
return content
2738
except Exception as e:
2839
print(f"Error including README.md: {e}")
2940
return markdown
3041

42+
elif page.file.src_path == 'about/contributing.md':
43+
markdown = markdown.replace('CHANGELOG.md', 'about/changelog.md')
44+
return markdown
45+
3146
markdown = python_indent(markdown)
3247
return markdown

mkdocs.yml

Lines changed: 11 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -32,16 +32,16 @@ nav:
3232
- Patching Guide: getting-started/patching.md
3333
- Generators:
3434
- Overview: generators/index.md
35-
- Unity: generators/unity.md
36-
- Wwise: generators/wwise.md
3735
- Daisy:
3836
- Basics: generators/daisy.md
3937
- JSON Params: generators/daisy_json.md
4038
- DPF: generators/dpf.md
41-
- Javascript: generators/javascript.md
4239
- FMOD: generators/fmod.md
40+
- Javascript: generators/javascript.md
4341
- OWL: generators/owl.md
4442
- Pd External: generators/pdext.md
43+
- Wwise: generators/wwise.md
44+
- Unity: generators/unity.md
4545
- Custom: generators/custom.md
4646
- Reference:
4747
- MIDI: reference/midi.md
@@ -54,7 +54,11 @@ nav:
5454
- Heavy GUI IR: reference/ir/heavy_gui_ir.md
5555
- ADRs:
5656
- Overview: adr/index.md
57-
- GUI Send/Receive: adr/ADR-001-GUI-Send-Receive.md
58-
- pd2gui Parser: adr/ADR-002-pd2gui-Parser.md
59-
- Control Rate Expr: adr/ADR-003-Control-Rate-Expr.md
60-
- Signal Rate Expr: adr/ADR-004-Signal-Rate-Expr.md
57+
- 001 - GUI Send/Receive: adr/ADR-001-GUI-Send-Receive.md
58+
- 002 - pd2gui Parser: adr/ADR-002-pd2gui-Parser.md
59+
- 003 - Control Rate Expr: adr/ADR-003-Control-Rate-Expr.md
60+
- 004 - Signal Rate Expr: adr/ADR-004-Signal-Rate-Expr.md
61+
- About:
62+
- Contributing: about/contributing.md
63+
- Code Of Conduct: about/code_of_conduct.md
64+
- Changelog: about/changelog.md

0 commit comments

Comments
 (0)