Skip to content

Commit 45c8cb9

Browse files
committed
views doc setup and fixes
1 parent a685885 commit 45c8cb9

File tree

7 files changed

+95
-37
lines changed

7 files changed

+95
-37
lines changed

Sources/Lindenmayer/LSystem.swift

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -28,13 +28,13 @@ import Foundation
2828
///
2929
/// ### Creating a Contextual L-system with Randomness
3030
///
31-
/// - ``LSystem/create(_:with:)-8xbbx``
32-
/// - ``LSystem/create(_:with:)-1otrb``
31+
/// - ``Lindenmayer/LSystem/create(_:with:)-5qbah``
32+
/// - ``Lindenmayer/LSystem/create(_:with:)-9349q``
3333
///
3434
/// ### Creating a Contextual L-system with Randomness and Parameters
3535
///
36-
/// - ``LSystem/create(_:with:using:)-49uk9``
37-
/// - ``LSystem/create(_:with:using:)-49uk9``
36+
/// - ``Lindenmayer/LSystem/create(_:with:using:)-1nce9``
37+
/// - ``Lindenmayer/LSystem/create(_:with:using:)-2nwqc``
3838
///
3939
public enum LSystem {
4040
/// Creates a new Lindenmayer system from an initial state.

Sources/Lindenmayer/Lindenmayer.docc/Lindenmayer.md

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,6 @@ To get support for using this package, see the [Discussions on Github](https://g
2828
- ``ParameterizedRandomContextualLSystem``
2929
- ``LindenmayerSystem``
3030
- ``ModuleSet``
31-
- ``RNGWrapper``
3231
- ``ParametersWrapper``
3332

3433
### Modules
@@ -85,3 +84,9 @@ To get support for using this package, see the [Discussions on Github](https://g
8584

8685
- ``Examples2D``
8786
- ``Examples3D``
87+
88+
### Seeded Pseudo-Random Number Generation
89+
90+
- ``RNGWrapper``
91+
- ``Lindenmayer/SeededRandomNumberGenerator``
92+
- ``Lindenmayer/Xoshiro``

Sources/Lindenmayer/ParameterizedRandomContextualLSystem.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -112,7 +112,7 @@ public struct ParameterizedRandomContextualLSystem<PType, PRNG>: LindenmayerSyst
112112
/// - prng: A psuedo-random number generator to use for stochastic rule productions.
113113
/// - rules: A collection of rules that the Lindenmayer system applies when you call the evolve function.
114114
///
115-
/// Convenient initializers for creating contextual L-systems uses ``LSystem``, calling ``LSystem/create(_:with:using:)-30rc3``, or ``LSystem/create(_:with:using:)-49uk9``.
115+
/// Convenient initializers for creating contextual L-systems uses ``LSystem``, calling ``Lindenmayer/LSystem/create(_:with:using:)-1nce9``, or ``Lindenmayer/LSystem/create(_:with:using:)-2nwqc``
116116
public init(axiom: [Module],
117117
state: [Module]?,
118118
newStateIndicators: [Bool]?,

Sources/Lindenmayer/RandomContextualLSystem.swift

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,8 @@ public struct RandomContextualLSystem<PRNG>: LindenmayerSystem where PRNG: Seede
9090
/// - prng: A psuedo-random number generator to use for stochastic rule productions.
9191
/// - rules: A collection of rules that the Lindenmayer system applies when you call the evolve function.
9292
///
93-
/// Convenient initializers for creating contextual L-systems uses ``LSystem``, calling ``LSystem/create(_:with:)-1otrb``, or ``LSystem/create(_:with:)-1otrb``.
93+
/// Convenient initializers for creating contextual L-systems uses ``LSystem``,
94+
/// calling ``Lindenmayer/LSystem/create(_:with:using:)-1nce9``, or ``Lindenmayer/LSystem/create(_:with:using:)-2nwqc``.
9495
public init(axiom: [Module],
9596
state: [Module]?,
9697
newStateIndicators: [Bool]?,

Sources/LindenmayerViews/LindenmayerViews.docc/LindenmayerViews.md

Lines changed: 31 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,36 @@ LindenmayerViews provides a collection of SwiftUI views to display the results 2
44

55
## Overview
66

7+
## Topics
78

9+
### Example Views
10+
11+
- ``LindenmayerViews/Monopodial4Examples``
12+
- ``LindenmayerViews/Sympodial4Examples``
13+
14+
### 2D View Components
15+
16+
- ``LindenmayerViews/Lsystem2DView``
17+
- ``LindenmayerViews/Dynamic2DLSystemViews``
18+
19+
### 3D View Components
20+
21+
- ``LindenmayerViews/Lsystem3DView``
22+
- ``LindenmayerViews/LSystem3DControlView``
23+
- ``LindenmayerViews/LSystem3DModel``
24+
25+
### General View Components
26+
27+
- ``LindenmayerViews/HorizontalLSystemStateView``
28+
- ``LindenmayerViews/LSystemMetrics``
29+
- ``LindenmayerViews/ModuleDetailView``
30+
- ``LindenmayerViews/ModuleSummaryView``
31+
- ``LindenmayerViews/EmptyModuleSummaryView``
32+
- ``LindenmayerViews/StateSelectorView``
33+
- ``LindenmayerViews/WindowedSmallModuleView``
34+
- ``LindenmayerViews/SummarySizes``
35+
36+
### Debugging Views
37+
38+
- ``LindenmayerViews/RollToVerticalTestView``
839

9-
## Topics

docanalyze.bash

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ xcrun docc convert Sources/Lindenmayer/Lindenmayer.docc \
2222
--analyze \
2323
--fallback-display-name Lindenmayer \
2424
--fallback-bundle-identifier com.github.heckj.Lindenmayer \
25-
--fallback-bundle-version 0.1.0 \
25+
--fallback-bundle-version 0.7.2 \
2626
--additional-symbol-graph-dir .build/symbol-graphs \
2727
--experimental-documentation-coverage \
2828
--level brief

docbuild.bash

Lines changed: 50 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -1,36 +1,58 @@
11
#!/bin/bash
22

3-
set -e
4-
set -x
5-
6-
rm -rf html
7-
mkdir -p html
8-
9-
rm -rf .build
10-
mkdir -p .build/symbol-graphs
11-
12-
# Lindenmayer.symbols.json LindenmayerViews.symbols.json [email protected]
13-
# [email protected] SceneKitDebugTools.symbols.json Squirrel3.symbols.json
14-
15-
16-
swift build --target Lindenmayer \
17-
--target LindenmayerViews \
18-
-Xswiftc -emit-symbol-graph \
19-
-Xswiftc -emit-symbol-graph-dir -Xswiftc .build/symbol-graphs
20-
21-
# cull the non-Lindenmayer specific builds from the symbol graph files
22-
rm -f .build/symbol-graphs/SceneKitDebug* .build/symbol-graphs/Squirrel3*
23-
3+
echo "Make sure you've rebased over the current HEAD branch:"
4+
echo "git rebase -i origin/main docs"
5+
6+
set -e # exit on a non-zero return code from a command
7+
set -x # print a trace of commands as they execute
8+
9+
#rm -rf .build
10+
#mkdir -p .build/symbol-graphs
11+
#
12+
#$(xcrun --find swift) build --target Lindenmayer --target LindenmayerViews \
13+
# -Xswiftc -emit-symbol-graph \
14+
# -Xswiftc -emit-symbol-graph-dir -Xswiftc .build/symbol-graphs
15+
#rm -f .build/symbol-graphs/SceneKitDebug* .build/symbol-graphs/Squirrel3*
16+
17+
# Enables deterministic output
18+
# - useful when you're committing the results to host on github pages
2419
export DOCC_JSON_PRETTYPRINT=YES
2520

26-
xcrun docc convert Sources/Lindenmayer/Lindenmayer.docc \
27-
--enable-inherited-docs \
28-
--output-path Lindenmayer.doccarchive \
29-
--fallback-display-name Lindenmayer \
30-
--fallback-bundle-identifier com.github.heckj.Lindenmayer \
31-
--fallback-bundle-version 0.1.0 \
32-
--additional-symbol-graph-dir .build/symbol-graphs
21+
#xcrun docc convert Sources/Lindenmayer/Lindenmayer.docc \
22+
#--enable-inherited-docs \
23+
#--output-path Lindenmayer.doccarchive \
24+
#--fallback-display-name Lindenmayer \
25+
#--fallback-bundle-identifier com.github.heckj.Lindenmayer \
26+
#--fallback-bundle-version 0.1.0 \
27+
#--additional-symbol-graph-dir .build/symbol-graphs
3328

3429
#--transform-for-static-hosting \
3530
#--hosting-base-path '/' \
3631
#--emit-digest
32+
33+
34+
# Swift package plugin for hosted content:
35+
#
36+
$(xcrun --find swift) package \
37+
--allow-writing-to-directory ./docs \
38+
generate-documentation \
39+
--fallback-bundle-identifier com.github.heckj.Lindenmayer \
40+
--fallback-bundle-version 0.7.2 \
41+
--target Lindenmayer \
42+
--target LindenmayerViews \
43+
--output-path ./docs \
44+
--emit-digest \
45+
--disable-indexing \
46+
--transform-for-static-hosting \
47+
--hosting-base-path 'Lindenmayer'
48+
49+
# Generate a list of all the identifiers to assist in DocC curation
50+
#
51+
52+
cat docs/linkable-entities.json | jq '.[].referenceURL' -r > all_identifiers.txt
53+
sort all_identifiers.txt \
54+
| sed -e 's/doc:\/\/com\.github\.heckj\.Lindenmayer\/documentation\///g' \
55+
| sed -e 's/^/- ``/g' \
56+
| sed -e 's/$/``/g' > all_symbols.txt
57+
58+
echo "Page will be available at https://swiftviz.github.io/Lindenmayer/documentation/Lindenmayer/"

0 commit comments

Comments
 (0)