name: C/C++ CI env: FEATURES: '--enable-option-checking=fatal --with-live555=/usr/local --enable-blank --enable-cineform --enable-decklink --enable-file --enable-gl --enable-jack --enable-jack-transport --enable-libavcodec --enable-natpmp --enable-openssl --enable-pcp --enable-portaudio --enable-qt --enable-rtdxt --enable-rtsp --enable-rtsp-server --enable-scale --enable-sdl2 --enable-sdp-http --enable-speexdsp --enable-swmix --enable-libswscale --enable-text --enable-video-mixer --enable-ximea --enable-zfec' CUDA_FEATURES: '--enable-cuda_dxt --enable-gpujpeg --enable-ldgm-gpu --enable-uyvy' on: push: branches: - master - ndi-build - 'release/*' paths: - '.github/scripts/**' - '.github/workflows/ccpp.yml' - '**.c' - '**.cpp' - '**.cu' - '**.h' - '**.hpp' - '**.m' - '**.mm' - 'autogen.sh' - 'cineform-sdk' - 'configure.ac' - 'data/scripts/**' - 'gpujpeg' - 'Makefile.in' jobs: prepare: runs-on: ubuntu-latest env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # This token is provided by Actions, we do not need to create own token. steps: - uses: actions/checkout@v2 id: checkout if: github.repository == 'CESNET/UltraGrid' && (github.ref == 'refs/heads/master' || startsWith(github.ref, 'refs/heads/release/')) with: persist-credentials: true - name: Retag if: steps.checkout.conclusion != 'skipped' run: | . .github/scripts/environment.sh git fetch --prune --unshallow --tags git tag -f $TAG git push -f origin refs/tags/$TAG:refs/tags/$TAG - name: Update Release if: steps.checkout.conclusion != 'skipped' && env.VERSION == 'continuous' run: | sudo apt install jq URL=$(curl -S -H "Authorization: token $GITHUB_TOKEN" -X GET https://api.github.com/repos/$GITHUB_REPOSITORY/releases/tags/continuous | jq -r '.url') REQ=PATCH if [ $URL = null ]; then # release doesn't yet exist REQ=POST URL=https://api.github.com/repos/$GITHUB_REPOSITORY/releases fi DATE=$(date -Iminutes) curl -S -H "Authorization: token $GITHUB_TOKEN" -X $REQ $URL -T - <