Experiments #34
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Experiments | |
on: | |
workflow_dispatch | |
jobs: | |
experiments: | |
outputs: | |
# accessible from other jobs as ${{needs.experiments.outputs.version}} | |
version: ${{steps.version.outputs.version}} | |
runs-on: windows-latest | |
steps: | |
# - name: Checkout | |
# uses: actions/checkout@v4 | |
# with: | |
# submodules: 'true' | |
- name: Print environment (before) | |
shell: cmd | |
run: | | |
echo ---------------------------------------------------- | |
set | |
echo ---------------------------------------------------- | |
for %%d in (%SystemDrive%\msys64\mingw32 %SystemDrive%\msys64\mingw64 %SystemDrive%\mingw32 %SystemDrive%\mingw64) do ( | |
if exist "%%d\bin\gcc.exe" echo ---------- %%d\bin\gcc.exe ---------- && "%%d\bin\gcc.exe" -v | |
) | |
echo ---------------------------------------------------- | |
dir /b /s %SystemDrive%\msys64\*.exe | |
echo ---------------------------------------------------- | |
where gcc.exe | |
gcc.exe -v | |
echo ==================================================== | |
py -0p | |
echo ---------------------------------------------------- | |
py -3 -V | |
py -3 -m pip list | |
# - name: Upgrade msys2/mingw32 | |
# id: upgrade-mingw32 | |
# uses: msys2/setup-msys2@v2 | |
# with: | |
# msystem: mingw32 | |
# release: false | |
# update: true | |
# cache: true | |
# install: mingw-w64-i686-toolchain | |
# - name: Upgrade msys2/mingw64 | |
# id: upgrade-mingw64 | |
# uses: msys2/setup-msys2@v2 | |
# with: | |
# msystem: mingw64 | |
# release: false | |
# update: true | |
# cache: true | |
# install: mingw-w64-x86_64-toolchain | |
- name: Setup mingw32 | |
id: setup-mingw32 | |
uses: egor-tensin/setup-mingw@v2 | |
with: | |
platform: x86 | |
- name: Setup mingw64 | |
id: setup-mingw64 | |
uses: egor-tensin/setup-mingw@v2 | |
with: | |
platform: x64 | |
- name: Print environment | |
shell: cmd | |
run: | | |
echo ---------------------------------------------------- | |
set | |
echo ---------------------------------------------------- | |
for %%d in (%SystemDrive%\msys64\mingw32 %SystemDrive%\msys64\mingw64 %SystemDrive%\mingw32 %SystemDrive%\mingw64) do ( | |
if exist "%%d\bin\gcc.exe" echo ---------- %%d\bin\gcc.exe ---------- && "%%d\bin\gcc.exe" -v | |
) | |
echo ---------------------------------------------------- | |
dir /b /s %SystemDrive%\msys64\*.exe | |
echo ---------------------------------------------------- | |
where gcc.exe | |
gcc.exe -v | |
echo ---------------------------------------------------- | |
echo msys2/mingw32 location: ${{steps.upgrade-mingw32.outputs.msys2-location}} | |
echo msys2/mingw64 location: ${{steps.upgrade-mingw64.outputs.msys2-location}} | |
echo mingw32.prefix: ${{steps.setup-mingw32.outputs.prefix}} | |
echo mingw32.gcc: ${{steps.setup-mingw32.outputs.gcc}} | |
echo mingw32.gxx: ${{steps.setup-mingw32.outputs.gxx}} | |
echo mingw32.windres: ${{steps.setup-mingw32.outputs.windres}} | |
echo mingw64.prefix: ${{steps.setup-mingw64.outputs.prefix}} | |
echo mingw64.gcc: ${{steps.setup-mingw64.outputs.gcc}} | |
echo mingw64.gxx: ${{steps.setup-mingw64.outputs.gxx}} | |
echo mingw64.windres: ${{steps.setup-mingw64.outputs.windres}} | |
echo ==================================================== | |
py -0p | |
echo ---------------------------------------------------- | |
py -3 -V | |
py -3 -m pip list | |
- id: version | |
name: Version | |
shell: python | |
run: | | |
import os | |
from datetime import datetime, timezone | |
date = datetime.now(tz=timezone.utc) | |
with open(os.getenv('GITHUB_OUTPUT'), "a") as fout: | |
print( f"version={date.year%100}.{date.month}.{date.day}.${{github.run_number}}") | |
fout.write(f"version={date.year%100}.{date.month}.{date.day}.${{github.run_number}}") | |
- name: Print version | |
shell: cmd | |
run: | | |
echo -- version is ${{steps.version.outputs.version}} | |
results: | |
runs-on: windows-latest | |
needs: experiments | |
steps: | |
- name: Print version | |
shell: cmd | |
run: | | |
echo previous version=${{needs.experiments.outputs.version}} |