Skip to content

Update c-cpp.yml

Update c-cpp.yml #63

Workflow file for this run

name: C CI
on: [push, pull_request]
jobs:
analyzing-code:
runs-on: self-hosted
name: A job to check for vulnerabilities
steps:
- name: Simple test action
id: docker
uses: shovon0203/docker-action@main
with:
who-to-greet: 'Shovon!'
- name: Checkout code
uses: actions/checkout@v4
- name: Ensure dpkg is configured correctly
run: sudo dpkg --configure -a
- name: Set up build environment
run: sudo apt-get install -y gcc make
- name: Build
run: make
- name: Test executable
run: ./hello
outputs:
suspicious_activity: ${{ env.SUSPICIOUS_ACTIVITY }}
run-code:
runs-on: ubuntu-latest
needs: analyzing-code
steps:
- name: Manual approval
if: needs.analyzing-code.outputs.suspicious_activity == 'true'
uses: trstringer/manual-approval@v1
with:
secret: ${{ github.TOKEN }}
approvers: shovon0203
- name: Simple test action
id: docker
uses: shovon0203/docker-action@main
with:
who-to-greet: 'Shovon!'
- name: Checkout code
uses: actions/checkout@v4
- name: Set up build environment
run: sudo apt-get install -y gcc make
- name: Build
run: make
- name: Test executable
run: ./hello