Skip to main content
Glama
ci.yml3.9 kB
name: CI on: push: branches: [main] pull_request: branches: [main] jobs: lint-workflows: name: Lint Workflows runs-on: ubuntu-latest steps: - name: Checkout uses: actions/checkout@v4 - name: Run actionlint uses: docker://rhysd/actionlint:latest with: args: -color lint-code: name: Lint Code runs-on: ubuntu-latest steps: - name: Checkout uses: actions/checkout@v4 - name: Setup Node.js uses: actions/setup-node@v4 with: node-version: '20' cache: 'npm' - name: Install dependencies run: npm ci - name: Run ESLint run: npm run lint - name: Check Prettier formatting run: npm run format:check - name: Type check run: npm run typecheck build-and-test: name: Build & Test (Node ${{ matrix.node-version }}) runs-on: ubuntu-latest strategy: matrix: node-version: ['18', '20', '22'] fail-fast: false steps: - name: Checkout uses: actions/checkout@v4 - name: Setup Node.js ${{ matrix.node-version }} uses: actions/setup-node@v4 with: node-version: ${{ matrix.node-version }} cache: 'npm' - name: Install dependencies run: npm ci - name: Build TypeScript run: npm run build - name: Run tests with coverage if: matrix.node-version != '18' run: npm test -- --coverage - name: Run tests (no coverage) if: matrix.node-version == '18' run: npm test - name: Upload coverage to Codecov if: matrix.node-version == '20' uses: codecov/codecov-action@v4 with: token: ${{ secrets.CODECOV_TOKEN }} files: ./coverage/lcov.info fail_ci_if_error: false verbose: true security-audit: runs-on: ubuntu-latest steps: - name: Checkout uses: actions/checkout@v4 - name: Setup Node.js uses: actions/setup-node@v4 with: node-version: '20' cache: 'npm' - name: Install dependencies run: npm ci - name: Security audit run: npm audit --audit-level=high # Fails on high/critical vulnerabilities # Use --audit-level=moderate for stricter checks - name: Write audit summary if: always() run: | echo "## Security Audit Results" >> "$GITHUB_STEP_SUMMARY" npm audit --json 2>/dev/null | jq -r ' if .metadata.vulnerabilities.high > 0 or .metadata.vulnerabilities.critical > 0 then "### Warning: High/Critical vulnerabilities found\n" + "- Critical: \(.metadata.vulnerabilities.critical // 0)\n" + "- High: \(.metadata.vulnerabilities.high // 0)\n" + "- Moderate: \(.metadata.vulnerabilities.moderate // 0)\n" + "- Low: \(.metadata.vulnerabilities.low // 0)" else "### No high/critical vulnerabilities\n" + "- Moderate: \(.metadata.vulnerabilities.moderate // 0)\n" + "- Low: \(.metadata.vulnerabilities.low // 0)" end ' >> "$GITHUB_STEP_SUMMARY" || echo "Audit summary unavailable" >> "$GITHUB_STEP_SUMMARY" commitlint: name: Lint Commits runs-on: ubuntu-latest if: github.event_name == 'pull_request' steps: - name: Checkout uses: actions/checkout@v4 with: fetch-depth: 0 - name: Setup Node.js uses: actions/setup-node@v4 with: node-version: '20' cache: 'npm' - name: Install dependencies run: npm ci - name: Validate PR commits run: npx commitlint --from ${{ github.event.pull_request.base.sha }} --to ${{ github.event.pull_request.head.sha }} --verbose

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/littlebearapps/wp-navigator-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server