DeveloperBreeze

Git Programming Tutorials, Guides & Best Practices

Explore 4+ expertly crafted git tutorials, components, and code examples. Stay productive and build faster with proven implementation strategies and design patterns from DeveloperBreeze.

Mastering GitHub Workflows for Continuous Integration and Deployment

Tutorial August 29, 2024

Matrix builds allow you to test your code across multiple environments, such as different versions of a language or operating system.

name: Node.js CI

on: [push, pull_request]

jobs:
  build:
    runs-on: ubuntu-latest

    strategy:
      matrix:
        node-version: [12, 14, 16]

    steps:
    - uses: actions/checkout@v3
    - name: Set up Node.js
      uses: actions/setup-node@v3
      with:
        node-version: ${{ matrix.node-version }}
    - name: Install dependencies
      run: npm install
    - name: Run tests
      run: npm test