diff --git a/.github/workflows/golangci-lint.yml b/.github/workflows/golangci-lint.yml index c2ac66273..2845b05a5 100644 --- a/.github/workflows/golangci-lint.yml +++ b/.github/workflows/golangci-lint.yml @@ -33,10 +33,6 @@ jobs: display_name: Windows - os: ubuntu-latest display_name: Linux - - os: ubuntu-latest - display_name: JS - goos: js - goarch: wasm name: ${{ matrix.display_name }} runs-on: ${{ matrix.os }} timeout-minutes: 15 @@ -44,7 +40,7 @@ jobs: - name: Checkout code uses: actions/checkout@v4 - name: Check for duplicate constants - if: matrix.os == 'ubuntu-latest' && matrix.goos != 'js' + if: matrix.os == 'ubuntu-latest' run: | ! awk '/const \(/,/)/{print $0}' management/server/activity/codes.go | grep -o '= [0-9]*' | sort | uniq -d | grep . - name: Install Go @@ -53,13 +49,10 @@ jobs: go-version: "1.23.x" cache: false - name: Install dependencies - if: matrix.os == 'ubuntu-latest' && matrix.goos != 'js' + if: matrix.os == 'ubuntu-latest' run: sudo apt update && sudo apt install -y -q libgtk-3-dev libayatana-appindicator3-dev libgl1-mesa-dev xorg-dev libpcap-dev - name: golangci-lint uses: golangci/golangci-lint-action@v4 with: version: latest args: --timeout=12m --out-format colored-line-number - env: - GOOS: ${{ matrix.goos }} - GOARCH: ${{ matrix.goarch }} diff --git a/.github/workflows/wasm-build-validation.yml b/.github/workflows/wasm-build-validation.yml index 6ec2c6da1..b4537f36d 100644 --- a/.github/workflows/wasm-build-validation.yml +++ b/.github/workflows/wasm-build-validation.yml @@ -11,6 +11,29 @@ concurrency: cancel-in-progress: true jobs: + js_lint: + name: "JS / Lint" + runs-on: ubuntu-latest + steps: + - name: Checkout repository + uses: actions/checkout@v4 + - name: Install Go + uses: actions/setup-go@v5 + with: + go-version: "1.23.x" + - name: Install golangci-lint + uses: golangci/golangci-lint-action@v4 + with: + version: latest + install-mode: binary + skip-cache: true + skip-pkg-cache: true + skip-build-cache: true + - name: Run golangci-lint for WASM + run: | + GOOS=js GOARCH=wasm golangci-lint run --timeout=12m --out-format colored-line-number + continue-on-error: true + js_build: name: "JS / Build" runs-on: ubuntu-latest