Merge pull request #19 from Nonannet/dev

Dev
This commit is contained in:
Nicolas Kruse 2025-12-28 09:47:45 +01:00 committed by GitHub
commit 344c3415fd
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 6 additions and 4 deletions

View File

@ -121,7 +121,7 @@ jobs:
- uses: actions/upload-artifact@v4 - uses: actions/upload-artifact@v4
if: strategy.job-index == 0 if: strategy.job-index == 0
with: with:
name: runner-linux name: runner-linux-x86_64
path: build/runner/* path: build/runner/*
build-arm64: build-arm64:
@ -290,7 +290,7 @@ jobs:
mkdir -p release mkdir -p release
cp tmp/stencil-object-files/* release/ cp tmp/stencil-object-files/* release/
cp tmp/musl-object-files/* release/ cp tmp/musl-object-files/* release/
cp tmp/runner-linux/coparun release/ cp tmp/runner-linux-x86_64/coparun release/
cp tmp/runner-linux-arm64/coparun release/coparun-aarch64 cp tmp/runner-linux-arm64/coparun release/coparun-aarch64
cp tmp/runner-linux-armv6/coparun release/coparun-armv6 cp tmp/runner-linux-armv6/coparun release/coparun-armv6
cp tmp/runner-linux-armv7/coparun release/coparun-armv7 cp tmp/runner-linux-armv7/coparun release/coparun-armv7

View File

@ -12,7 +12,7 @@ def extract_sections(md_text: str) -> dict[str, str]:
# regex captures: heading marks (###...), heading text, and the following content # regex captures: heading marks (###...), heading text, and the following content
pattern = re.compile( pattern = re.compile(
r'^(#{1,6})\s+(.*?)\s*$' # heading level + heading text r'^(#{1,6})\s+(.*?)\s*$' # heading level + heading text
r'(.*?)' # section content (lazy) r'(.*?(?:```.*?```.*?)*?)' # section content (lazy)
r'(?=^#{1,6}\s+|\Z)', # stop at next heading or end of file r'(?=^#{1,6}\s+|\Z)', # stop at next heading or end of file
re.MULTILINE | re.DOTALL re.MULTILINE | re.DOTALL
) )
@ -37,7 +37,9 @@ if __name__ == '__main__':
readme = extract_sections(f.read()) readme = extract_sections(f.read())
with open(os.path.join(build_dir, 'start.md'), 'wt') as f: with open(os.path.join(build_dir, 'start.md'), 'wt') as f:
f.write('\n'.join(f"# {s}\n" + readme[s] for s in ['Copapy', 'Current state', 'Install', 'License'])) f.write('\n'.join(f"{s}\n" + readme[s.strip(' #')] for s in [
'# Copapy', '## Current state', '## Install', '## Examples',
'### Basic example', '### Inverse kinematics', '## License']))
with open(os.path.join(build_dir, 'compiler.md'), 'wt') as f: with open(os.path.join(build_dir, 'compiler.md'), 'wt') as f:
f.write('\n'.join(readme[s] for s in ['How it works'])) f.write('\n'.join(readme[s] for s in ['How it works']))