This repository has been archived by the owner on Jan 1, 2025. It is now read-only.
build(deps): bump follow-redirects from 1.15.3 to 1.15.4 in /src #17
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# The purpose of this workflow is to validate pull requests. | |
# It is a stripped down version of the full workflow. | |
name: electron-ci-pr | |
on: | |
pull_request: | |
branches: | |
- develop | |
jobs: | |
build: | |
runs-on: ${{ matrix.os }} | |
strategy: | |
matrix: | |
os: [windows-latest, macos-latest] | |
include: | |
- os: windows-latest | |
build_command: "buildwin" | |
artifact_name: "fsolauncher-win-pr" | |
- os: macos-latest | |
build_command: "builddarwin" | |
artifact_name: "fsolauncher-mac-pr" | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v2 | |
- name: Set up Node.js | |
uses: actions/setup-node@v2 | |
with: | |
node-version: 16 | |
- name: Cache Node.js modules | |
id: cache-node-modules | |
uses: actions/cache@v2 | |
with: | |
path: src/node_modules | |
key: ${{ runner.os }}-node-modules-${{ hashFiles('src/package-lock.json') }} | |
restore-keys: | | |
${{ runner.os }}-node-modules- | |
- name: Playwright Skip Browser Download | |
run: echo "PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD=1" >> $GITHUB_ENV | |
- name: python3 fix | |
if: matrix.os == 'macos-latest' | |
run: python3 -m pip install setuptools | |
- name: Install dependencies | |
if: steps.cache-node-modules.outputs.cache-hit != 'true' | |
run: npm ci | |
working-directory: src | |
- name: Run ESLint | |
run: npm run lint | |
working-directory: src | |
- name: Build | |
run: npm run ${{ matrix.build_command }} | |
working-directory: src | |
- name: Run e2e tests | |
run: npm run test | |
env: | |
GITHUB_RATELIMIT_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
working-directory: src | |
- name: List contents of the release directory (Windows) | |
if: matrix.os == 'windows-latest' | |
run: | | |
dir "release" | |
- name: List contents of the release directory (macOS) | |
if: matrix.os == 'macos-latest' | |
run: | | |
ls -la release | |
- name: Upload artifacts (Windows) | |
uses: actions/upload-artifact@v2 | |
if: matrix.os == 'windows-latest' | |
with: | |
name: ${{ matrix.artifact_name }} | |
path: release/FreeSO Launcher Setup.exe | |
- name: Upload artifacts (macOS) | |
uses: actions/upload-artifact@v2 | |
if: matrix.os == 'macos-latest' | |
with: | |
name: ${{ matrix.artifact_name }} | |
path: release/FreeSO Launcher.dmg | |
post_comment: | |
needs: build | |
runs-on: ubuntu-latest | |
steps: | |
- name: Comment PR with Workflow Run URL | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
run: | | |
URL="https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}" | |
PR_COMMENT="Workflow run for this pull request is completed. Check out the results [here]($URL). You can find the download links for the build artifacts specific to this pull request at the bottom of the page." | |
curl -sSL \ | |
-H "Authorization: token $GITHUB_TOKEN" \ | |
-H "Accept: application/vnd.github.v3+json" \ | |
-X POST \ | |
-d "{\"body\": \"$PR_COMMENT\"}" \ | |
"https://api.github.com/repos/${{ github.repository }}/issues/${{ github.event.pull_request.number }}/comments" |