GitHub Actions

Run BoxLang in your GitHub actions seamlessly.

To run BoxLang in your GitHub Actions workflow, you need to add a step to your workflow file to set up and execute BoxLang. Below is an example of how you can use the action to run BoxLang with default settings:

name: Run BoxLang

on: [push]

jobs:
  build:
    runs-on: ubuntu-latest

    steps:
    - name: Checkout code
      uses: actions/checkout@v2

    - name: Set up BoxLang
      uses: boxlang/setup-boxlang@v1
      with:
        version: latest # or specify a version like '1.2.3'
        modules: "module1 module2" # optional: specify modules to install

    - name: Run BoxLang Script
      run: boxlangyour_script.bx

This setup installs BoxLang, optionally installs modules, and runs a BoxLang script within your repository. Adjust the version and modules as needed.

Inputs

The following are all the different input variables you can use with the action, allowing you to set up BoxLang in your GitHub Actions workflow.

Input
Type
Default
Description

modules

string

---

If added, a space-delimited list of modules to install upon installation of the binary for you.

version

semver

latest

The BoxLang version to install, if not passed we use the latest stable.

Usage Examples

Simple usage:

- name: Setup BoxLang
  uses: ortus-boxlang/setup-boxlang@v1

With Specific Modules:

- name: Setup BoxLang
  uses: ortus-boxlang/setup-boxlang@v1
  with:
    modules: bx-ai bx-orm bx-pdf

Install a specific version of BoxLang:

- name: Setup BoxLang with specific version
  uses: ortus-boxlang/setup-boxlang@v1
  with:
    version: snapshot

Here is another one:

- name: Setup BoxLang with specific version
  uses: ortus-boxlang/setup-boxlang@v1
  with:
    version: 1.1.0

System Requirements

This action will automatically install the following system packages if they are not already available:

  • openjdk-21-jre (or equivalent) - Java Runtime Environment for BoxLang

Last updated

Was this helpful?