Skip to content

GitHub Actions

GitHub release

This action wraps LikeC4 CLI as a GitHub Action.

steps:
- uses: actions/checkout@v4
- name: ⚙️ build
uses: likec4/actions@v1
with:
action: build
path: src/likec4
output: dist
base: /baseurl/
- name: upload artifacts
uses: actions/upload-artifact@v3
with:
name: likec4
path: dist
steps:
- name: export diagrams
uses: likec4/actions@v1
with:
export: png
path: src/likec4
output: out/images
use-dot-bin: 'true'
steps:
- name: code generation
uses: likec4/actions@v1
with:
codegen: react
output: __generated__/likec4.jsx
Name Description
action Action to perform (build / export / codegen)
export Can be used instead of action: export
codegen Can be used instead of action: codegen, same values as in cli
path Path in repository to likec4 sources, root otherwise
output Output directory/file
base Custom baseUrl for website
use-dot-bin if 'true' will use dot binary of graphviz

All inputs are optional.
By default CLI builds a website to dist directory.