Writerside Help

Build on TeamCity Cloud

This article describes how to use TeamCity Cloud to build a help instance.

  1. Create a new project on TeamCity from a repository URL.

  2. Open the project, click Edit project and select New build configuration.

  3. In the Create Build Configuration dialog, click Manually, then specify the name, ID and (optionally) description for the build configuration.

    Click Create.

  4. Under General Settings, in the Artifacts paths field, specify the following:

    helproot => webhelp.zip
  5. Create VCS roots and specify VCS-specific settings. Read more in TeamCity help.

  6. In the Build Steps section, add a new build step with the type Command line and the following script content:

    set -e export DISPLAY=:99 Xvfb $DISPLAY & sleep 1 /opt/builder/bin/idea.sh helpbuilderinspect -source-dir . -product $INSTANCE -output-dir artifacts/ echo "Test existing of $ARTIFACT artifact" test -e artifacts/$ARTIFACT echo "$ARTIFACT exists"
  7. In the Run step within Docker container field, specify registry.jetbrains.team/p/writerside/builder/writerside-builder:<DOCKER_VERSION>, where <DOCKER_VERSION> is the Docker image tag that corresponds to the version of Writerside you are using.

    The Docker image tag for the latest Writerside version is 232.10275.

    registry.jetbrains.team/p/writerside/builder/writerside-builder:232.10275
  8. Click Save.

  9. Add one more build step with the type Command line and the following script content:

    ls -lR mkdir -p helproot/img/ echo "Unzip artifact to shared folder" python3 -m zipfile -e artifacts/$ARTIFACT helproot/
  10. Under Parameters, add the following environmental variables:

    env.INSTANCE

    The name of the help module and help instance ID separated by a slash.

    When you create a new Writerside project or a help instance in an existing project, the default help module name is Writerside and the default instance ID is hi. So, in this case, set INSTANCE: Writerside/hi.

    To locate the help module name, check the folder name with the following icon module icon in the Project tool window.

    env.ARTIFACT

    The name of the produced archive is webHelpXX2-all.zip, where XX is the ID of the help instance in capital letters.

    For example, if the help instance is Foo Help, and its ID is fh, then set ARTIFACT: webHelpFH2-all.zip.

To find the built artifact, go to the Artifacts tab of the build results page or use the artifacts icon Artifact icon in TeamCity on the page that list the builds.

Last modified: 21 November 2023