Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix CI workflow by using locally checked out reactor-ts #157

Merged
merged 12 commits into from
Jun 30, 2023
22 changes: 20 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,26 +27,44 @@ jobs:
lingua-franca:
runs-on: ubuntu-latest
steps:
- name: Check out reactor-ts repository
uses: actions/checkout@v3
with:
path: "reactor-ts"
fetch-depth: 0
- name: Read lingua-franca-ref.txt
run: echo "lingua-franca-ref=$(wget -qO- https://raw.githubusercontent.com/lf-lang/reactor-ts/${{ github.head_ref || github.ref_name }}/lingua-franca-ref.txt)" >> $GITHUB_ENV
run: echo "lingua-franca-ref=$(cat ./reactor-ts/lingua-franca-ref.txt)" >> $GITHUB_ENV
- name: Check out lingua-franca repository
axmmisaka marked this conversation as resolved.
Show resolved Hide resolved
uses: actions/checkout@v3
with:
repository: lf-lang/lingua-franca
ref: ${{ env.lingua-franca-ref }}
fetch-depth: 0
path: "lingua-franca"
submodules: true
- name: Move Lingua Franca to default pwd
axmmisaka marked this conversation as resolved.
Show resolved Hide resolved
run: |
axmmisaka marked this conversation as resolved.
Show resolved Hide resolved
shopt -s dotglob
axmmisaka marked this conversation as resolved.
Show resolved Hide resolved
mv -- ./lingua-franca/* ${{ github.workspace }}
axmmisaka marked this conversation as resolved.
Show resolved Hide resolved
lhstrh marked this conversation as resolved.
Show resolved Hide resolved
shopt -u dotglob
axmmisaka marked this conversation as resolved.
Show resolved Hide resolved
- name: Prepare build environment
uses: ./.github/actions/prepare-build-env
axmmisaka marked this conversation as resolved.
Show resolved Hide resolved
- name: Setup Node.js environment
uses: actions/setup-node@v3
with:
node-version: 18
cache: 'npm'
cache-dependency-path: 'reactor-ts/package-lock.json'
- name: Build reactor-ts
run: |
cd ./reactor-ts
npm install
npm run build
- name: Install pnpm
run: npm i -g pnpm
- name: Install RTI
uses: ./.github/actions/install-rti
if: ${{ runner.os == 'macOS' || runner.os == 'Linux' }}
- name: Perform Lingua Franca TypeScript tests
run: |
./gradlew targetTest -Ptarget=TypeScript -Druntime="git://github.com/lf-lang/reactor-ts.git#${{ github.head_ref || github.ref_name }}"
./gradlew targetTest -Ptarget=TypeScript -Druntime="file:/${{ github.workspace }}/reactor-ts"