|
4 | 4 | steps: |
5 | 5 | - name: Install gnuplot (via apt-get) |
6 | 6 | shell: bash |
| 7 | + if: runner.os == 'Linux' |
7 | 8 | run: | |
8 | | - if ${{ toJSON( runner.os == 'Linux' ) }}; then |
9 | | - echo "::group::Install gnuplot (via apt-get)" |
10 | | - sudo apt-get -y update && sudo apt-get install --no-install-recommends -y gnuplot gnuplot-qt |
11 | | - echo "::endgroup::" |
12 | | - fi |
| 9 | + echo "::group::Install gnuplot (via apt-get)" |
| 10 | + sudo apt-get -y update && sudo apt-get install --no-install-recommends -y gnuplot gnuplot-qt |
| 11 | + echo "::endgroup::" |
13 | 12 | - name: Install gnuplot (via brew) |
14 | 13 | shell: bash |
| 14 | + if: runner.os == 'macOS' |
15 | 15 | run: | |
16 | | - if ${{ toJSON( runner.os == 'macOS' ) }}; then |
17 | | - echo "::group::Install gnuplot (via brew)" |
18 | | - brew update |
19 | | - brew upgrade python || true # currently (2024-03-25) 3.12 link fails |
20 | | - HOMEBREW_NO_INSTALLED_DEPENDENTS_CHECK=1 brew install gnuplot |
21 | | - echo "::endgroup::" |
22 | | - fi |
| 16 | + echo "::group::Install gnuplot (via brew)" |
| 17 | + brew update |
| 18 | + brew upgrade python || true # currently (2024-03-25) 3.12 link fails |
| 19 | + HOMEBREW_NO_INSTALLED_DEPENDENTS_CHECK=1 brew install gnuplot |
| 20 | + echo "::endgroup::" |
23 | 21 | - name: Install gnuplot (extract from archive) |
24 | 22 | shell: bash |
| 23 | + if: runner.os == 'Windows' |
25 | 24 | env: |
26 | 25 | GNUPLOT_URI: "https://sourceforge.net/projects/gnuplot/files/gnuplot/5.4.6/gp546-win64-mingw-2.7z/download" |
27 | 26 | GNUPLOT_FILE: "gp546-win64-mingw-2.7z" |
28 | 27 | run: | |
29 | | - if ${{ toJSON( runner.os == 'Windows' ) }}; then |
30 | | - echo "::group::Install gnuplot (extract from archive)" |
31 | | - num_attempts=1 |
32 | | - until \ |
33 | | - pwsh -c ' [Net.ServicePointManager]::SecurityProtocol = "tls12, tls11, tls"; $request = Invoke-WebRequest -MaximumRetryCount 3 -UserAgent Curl -Uri $Env:GNUPLOT_URI -OutFile $Env:GNUPLOT_FILE' \ |
34 | | - || [[ $num_attempts -gt 3 ]]; do |
35 | | - echo $((num_attempts++)); |
36 | | - done |
37 | | - 7z x $GNUPLOT_FILE -o.. |
38 | | - pwsh -c 'echo "'$( cygpath -w $( realpath ../gnuplot/bin ) )'" | Out-File -FilePath $env:GITHUB_PATH -Encoding utf8 -Append' |
39 | | - echo "::endgroup::" |
40 | | - fi |
| 28 | + echo "::group::Install gnuplot (extract from archive)" |
| 29 | + num_attempts=1 |
| 30 | + until \ |
| 31 | + pwsh -c ' [Net.ServicePointManager]::SecurityProtocol = "tls12, tls11, tls"; $request = Invoke-WebRequest -MaximumRetryCount 3 -UserAgent Curl -Uri $Env:GNUPLOT_URI -OutFile $Env:GNUPLOT_FILE' \ |
| 32 | + || [[ $num_attempts -gt 3 ]]; do |
| 33 | + echo $((num_attempts++)); |
| 34 | + done |
| 35 | + 7z x $GNUPLOT_FILE -o.. |
| 36 | + pwsh -c 'echo "'$( cygpath -w $( realpath ../gnuplot/bin ) )'" | Out-File -FilePath $env:GITHUB_PATH -Encoding utf8 -Append' |
| 37 | + echo "::endgroup::" |
0 commit comments