diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index ea9f3e15..112ee4d8 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -31,7 +31,7 @@ jobs: run: | cd tests/TestWithModules call "%programfiles(x86)%\Microsoft Visual Studio\2019\Enterprise\VC\Auxiliary\Build\vcvars64.bat" - dir %Qt5_Dir%/lib/cmake + dir %Qt5_DIR%/lib/cmake qmake shell: cmd @@ -39,6 +39,6 @@ jobs: if: (!startsWith(matrix.os, 'windows')) run: | cd tests/TestWithModules - ls $Qt5_Dir/lib/cmake + ls $Qt5_DIR/lib/cmake qmake shell: bash diff --git a/README.md b/README.md index caad22a7..7d6ee8d8 100644 --- a/README.md +++ b/README.md @@ -55,9 +55,9 @@ Android: `android_armv7` ### `dir` This is the directory prefix that Qt will be installed to. -For example, if you set dir to `/example/`, your bin folder will be located at `/example/Qt/5.12.7/(your_arch)/bin`. When possible, access your Qt directory through the `Qt5_Dir` environment variable. +For example, if you set dir to `${{ github.workspace }}/example/`, your bin folder will be located at `$GITHUB_WORKSPACE/example/Qt/5.12.7/(your_arch)/bin`. When possible, access your Qt directory through the `Qt5_DIR` environment variable. -Default: `${RUNNER_WORKSPACE}` (this is one folder above the starting directory) +Default: `$RUNNER_WORKSPACE` (this is one folder above the starting directory) ### `install-deps` Whether or not to automatically install Qt dependencies on Linux (you probably want to leave this on). @@ -120,7 +120,7 @@ Default: `==0.6b8` host: 'windows' target: 'desktop' arch: 'win64_msvc2017_64' - dir: '/example/' + dir: '${{ github.workspace }}/example/' install-deps: 'true' modules: 'qtcharts qtwebengine' mirror: 'http://mirrors.ocf.berkeley.edu/qt/' @@ -131,7 +131,7 @@ Default: `==0.6b8` ## More info -The Qt bin directory is added to your `path` environment variable. `Qt5_Dir` is also set appropriately for cmake. +The Qt bin directory is added to your `path` environment variable. `Qt5_DIR` is also set appropriately for cmake. Big thanks to the [aqtinstall](https://github.com/miurahr/aqtinstall/) developers for making this easy. Please go support them, they did all of the hard work here. diff --git a/src/main.ts b/src/main.ts index 3cb5702d..2da4bb74 100644 --- a/src/main.ts +++ b/src/main.ts @@ -87,7 +87,8 @@ async function run() { let qtPath = dir + "/" + version; qtPath = glob.sync(qtPath + '/**/*')[0]; - core.exportVariable('Qt5_Dir', qtPath); + core.exportVariable('Qt5_Dir', qtPath); // Incorrect name that was fixed, but kept around so it doesn't break anything + core.exportVariable('Qt5_DIR', qtPath); core.addPath(qtPath + "/bin"); } catch (error) { core.setFailed(error.message);