Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/ryosukedtomita/asciidoc_env
Build PlantUML with asciidoc and embedded PlantUML in gradle
https://github.com/ryosukedtomita/asciidoc_env
asciidoc asciidoctor-diagram asciidoctor-gradle-plugin devcontainer docker github-actions github-pages plantuml
Last synced: about 2 months ago
JSON representation
Build PlantUML with asciidoc and embedded PlantUML in gradle
- Host: GitHub
- URL: https://github.com/ryosukedtomita/asciidoc_env
- Owner: RyosukeDTomita
- License: unlicense
- Created: 2024-10-03T16:47:00.000Z (3 months ago)
- Default Branch: main
- Last Pushed: 2024-11-15T02:35:00.000Z (about 2 months ago)
- Last Synced: 2024-11-15T03:25:46.286Z (about 2 months ago)
- Topics: asciidoc, asciidoctor-diagram, asciidoctor-gradle-plugin, devcontainer, docker, github-actions, github-pages, plantuml
- Language: Dockerfile
- Homepage: https://ryosukedtomita.github.io/asciidoc_env/test.html
- Size: 85 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
- Codeowners: CODEOWNERS
Awesome Lists containing this project
README
# Asciidoc Edit Environment (Dev Contaienr)
![un license](https://img.shields.io/github/license/RyosukeDTomita/asciidoc_env)
## INDEX
- [ABOUT](#about)
- [ENVIRONMENT](#environment)
- [PREPARING](#preparing)
- [HOW TO USE](#how-to-use)
- [ERROR LOG](#error-log)---
## ABOUT
tiny asciidoc sample.
Reference: [Asciidoctor Docs](https://docs.asciidoctor.org/)
---
## ENVIRONMENT
### asciidoctor gradle plugin
Gradleでbuildすることでasciidoctorでビルドするよりもライブラリの管理や依存関係の設定が楽になる。
- [asciidoctor-gradle-glugin guide](https://asciidoctor.github.io/asciidoctor-gradle-plugin/master)
- [Official repository](https://github.com/asciidoctor/asciidoctor-gradle-plugin)> [!NOTE]
> gradlew: 特定のversionのGradleを作るためのもの。今回の場合はDockerのgradle imageを使っているためGradleのversionは固定だが,GitHub Actionsで実行することを見据えて追加した。
>
> ```shell
> # 作成
> gradle wrapper
> # 削除
> rm gradlew
> rm gradlew.bat
> rm -rf gradle/wrapper/
> ```### PlantUML
- PlantUMLで図を生成するためにはlibXext.so.6が必要。Dockerfileにaptで追加している。
- Asciidocに直接`.pu`ファイルを埋め込んでいる。
- [asciidoctor-diagram](https://docs.asciidoctor.org/gradle-plugin/latest/asciidoctor-diagram/)が必要(build.gradleに記載)### GitHub Pages
作成したAsciiDocをgithubでホストする。
例: https://ryosukedtomita.github.io/asciidoc_env/test.html#### 初期設定
- [リポジトリの設定](https://github.com/RyosukeDTomita/asciidoc_env/settings/pages)からBuild and deploymentをGithub Actionsに変更
- [リポジトリの環境変数設定](https://github.com/RyosukeDTomita/asciidoc_env/settings/environments/)からfeature/github-pagesを追加---
## PREPARING
1. install VSCode, Docker
2. install VSCode Extensions `Dev Container`---
## HOW TO USE
html and svg (created with PlantUML) are stored under `build/`.
### just build html
```shell
docker buildx bake
docker compose up
```### use asciidoc Dev Container
Open this repository and `Rebuild and Reopen in Container`
```shell
# create html
gradle asciidoctor# delete html
gradle clean
```---
## ERROR LOG
### PlantUMLの日本語が重なる
Dev Containerに日本語フォントが入っていないのが原因。[素晴らしいQiita](https://qiita.com/yomon8/items/a3e016b7ffc3e4fbb7e5)