Skip to content

Add 404 check to CI #80

@maehr

Description

@maehr

Describe what feature you'd like. Pseudo-code, mockups, or screenshots of similar solutions are encouraged!

We could add something like to check for 404 before merging.

    - name: Install required dependencies
      run: |
        sudo apt-get update
        sudo apt-get install -y wget

    - name: Start Quarto preview server
      run: |
        nohup quarto preview --port 5528 &
        sleep 5  # Give the server time to start

    - name: Check for 404 errors
      run: |
        wget --spider --recursive http://localhost:5528/ -o wget-log.txt || true
        if grep "404 Not Found" wget-log.txt; then
          echo "404 errors found in the following URLs:"
          grep "404 Not Found" wget-log.txt -B 1
          exit 1
        else
          echo "No 404 errors found."
        fi

What type of pull request would this be?

Enhancement

Any links to similar examples or other references we should review?

No response

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions