Skip to content

Merge branch 'main' into refactor-examples #406

Merge branch 'main' into refactor-examples

Merge branch 'main' into refactor-examples #406

Workflow file for this run

name: uuids
on: [push, pull_request]
jobs:
check_uuids:
runs-on: ubuntu-22.04
env:
NIM_VERSION: '2.0.0'
steps:
- uses: actions/checkout@3df4ab11eba7bda6032a0b82a6bb43b11571feac
- name: Get the versions of the installed GCC and OpenSSL
run: |
echo "GCC_VERSION=$(gcc --version | head -n1 | cut -d' ' -f3)" >> "${GITHUB_ENV}"
echo "OPENSSL_VERSION=$(openssl version | cut -d' ' -f2 )" >> "${GITHUB_ENV}"
- name: Cache binary
id: cache-uuids
uses: actions/cache@704facf57e6136b1bc63b828d79edcd491f0ee84
with:
path: _test/check_uuids
key: check_uuids-${{ hashFiles('_test/check_uuids.nim') }}-${{ runner.os }}-nim${{ env.NIM_VERSION }}-gcc${{ env.GCC_VERSION }}-openssl${{ env.OPENSSL_VERSION }}
- name: Install Nim
if: steps.cache-uuids.outputs.cache-hit != 'true'
uses: iffy/install-nim@96e44cd5d6df83f65cd844a8631e8301944bc958
with:
version: "binary:${{ env.NIM_VERSION }}"
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Run tests for `check_uuids.nim`
if: steps.cache-uuids.outputs.cache-hit != 'true'
run: nim c --styleCheck:error -d:test -r ./_test/check_uuids.nim
- name: Compile `check_uuids.nim`
if: steps.cache-uuids.outputs.cache-hit != 'true'
run: nim c --styleCheck:error -d:ssl -d:release --passC:-flto --passL:-s ./_test/check_uuids.nim
- name: Run `check_uuids`
run: ./_test/check_uuids