blob: 1f246f83ac3d74c3951d954b57436c45f1ffa08f (
plain) (
tree)
|
|
name: Build foo.exe
description: Build foo.exe
inputs:
version:
description: Version to use
required: false
platform:
description: Target platform
required: true
runs:
using: composite
steps:
- run: |
$version = '${{ inputs.version }}'
$version = if ($version) { "-$version" } else { $version }
$flags = @()
if ('${{ matrix.platform }}' -eq 'x86') {
$flags += '-m32'
}
$flags += '-std=c++11','-o','foo','foo.cpp'
if ('${{ runner.os }}' -eq 'Linux') {
$flags += '-lpthread'
}
& "g++$version" $flags
shell: pwsh
|