d2/ci/release/README.md

50 lines
1.3 KiB
Markdown
Raw Permalink Normal View History

2022-11-11 09:17:06 +00:00
# release
2022-11-14 00:57:47 +00:00
## _install.sh
The template for the install script in the root of the d2 repository.
2022-11-14 00:57:47 +00:00
### gen_install.sh
Generates the install.sh script in the root of the repository by prepending the libraries
it depends on from ../sub/lib.
## release.sh
- ./release.sh is the top level script to generate a new release.
Run with --help for usage.
## build.sh
- ./build.sh builds the release archives for each platform into ./build/<VERSION>/*.tar.gz
Run with --help for usage.
> note: Remember for production releases you need to set the $TSTRUCT_OS_ARCH_BUILDER
> variables as we must compile d2 directly on each release target to include dagre.
> See https://github.com/terrastruct/d2/issues/31
2022-12-14 08:47:07 +00:00
Use `--host-only` to build only the release for the host's `$OS-$ARCH` pair.
2022-11-14 06:41:58 +00:00
2022-11-14 00:57:47 +00:00
### build_docker.sh
Helper script called by build.sh to build D2 on each linux runner inside Docker.
2022-12-14 08:47:07 +00:00
The Dockerfile is in ./linux/Dockerfile
2022-11-14 00:57:47 +00:00
### _build.sh
Called by build.sh (with --local or macOS) or build_docker.sh (on linux) to create the
release archive.
Do not invoke directly. If you want to produce a build for a single platform run build.sh
as so:
```sh
# To only build the linux-amd64 release.
./build.sh --run=linux-amd64
```
```sh
# To only build the linux-amd64 release locally.
./build.sh --local --run=linux-amd64
```