screenshot #15
This file contains hidden or 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
| on: | |
| push: | |
| branches: [ "main" ] | |
| pull_request: | |
| branches: [ "main" ] | |
| jobs: | |
| build: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v3 | |
| - name: Set up Go | |
| uses: actions/setup-go@v4 | |
| with: | |
| go-version: '1.21' | |
| - name: Install Chromium dependencies (no-sandbox workaround) | |
| run: | | |
| sudo apt-get update | |
| sudo apt-get install -y libatk-bridge2.0-0 libgtk-3-0 libxss1 libasound2t64 | |
| - name: Set environment for Chrome no-sandbox | |
| run: echo "CHROME_FLAGS=--no-sandbox" >> $GITHUB_ENV | |
| - name: Set environment for CI timeouts | |
| run: echo "CI=true" >> $GITHUB_ENV | |
| - name: Build CLI | |
| run: make build | |
| - name: Run example (GET) | |
| env: | |
| CHROME_FLAGS: --no-sandbox | |
| run: go run examples/get.go | |
| - name: Run example (POST) | |
| env: | |
| CHROME_FLAGS: --no-sandbox | |
| run: go run examples/post.go | |