-
Notifications
You must be signed in to change notification settings - Fork 179
Generate Ballerina By Examples on demand
Updating the Ballerina By Examples can be done against the nightly PR builds.
The sections below provide the instructions to do this by simply running the Create PR for new Swan Lake BBEs pages on demand GitHub workflow.
Change the source of the Ballerina by Examples on the <ballerina-distribution>
GitHub repository by merging a Pull Request.
The Create PR for new Swan Lake BBEs pages on demand
GitHub workflow requires three input values to run it.
The sections below provide the instructions to obtain them.
In the Ballerina distributions, the PR merge builds and daily builds archive the artifacts. You need to get the ID of the Ballerina ZIP artifact, which is appended as the last element in the URL.
Follow the steps below to obtain it.
- In the
<ballerina-distribution>
repo, click Actions, and then click Build. - Wait until the build of the topmost entry (which is the latest) is successful.
Tip: This will be indicated by a green color tick.
- Scroll down and right-click on the
BALLERINA.zip
file, and click Copy Link. - Get the last element (the integer code) from the appended URL, which is the Artifact ID.
(E.g., The artifact ID of https://github.com/ballerina-platform/ballerina-distribution/suites/2891309717/artifacts/64739040 is
64739040
.)
Click on the <ballerina-distribution>/gradle.properties
file, and pick the master version (e.g., swan-lake-beta1-SNAPSHOT
) and the short version (e.g., slbeta1
).
E.g., version=swan-lake-beta2-SNAPSHOT
and shortVersion=slbeta2
.
Follow the steps below in this ballerina-dev-website
repo to run the respective workflow.
- In this
ballerina-dev-website
repo, click Actions in the top menu. - Click on the Create PR for new Swan Lake BBEs pages on demand workflow, and click Run workflow.
- Select the Branch on which you need to update the BBE changes.
- Enter the Artifact ID, Artifact version, and Artifact short version (you obtained above).
- Click Run workflow. (This creates a PR to update the BBEs on the dev site.)
- Get the PR approved and merged.
After running the workflow, once the PR build is successful, it creates a PR. Check out the branch of that PR, and build the website locally to verify your changes.