github / gh-valet

Valet helps facilitate the migration of Azure DevOps, CircleCI, GitLab CI, Jenkins, and Travis CI pipelines to GitHub Actions.
MIT License
510 stars 35 forks source link

Check if Valet container image is present before running commands #13

Closed ethanis closed 2 years ago

ethanis commented 2 years ago

This adds a guard before executing commands to first check that the Valet container image is available on the machine. If it is not, then an exception will be thrown instructing the user to first run gh valet update.

Hows this tested

First, remove all valet container images from machine

$ docker rmi $(docker images | grep 'valet-cli')

Then, run a command:

➜ dotnet run --project Valet/Valet.csproj -- version
Unable to locate Valet image locally. Please run `gh valet update` to fetch the latest image prior to running this command.

Closes github/valet#4104

github-actions[bot] commented 2 years ago

Unit Test Results

1 files  ±0  1 suites  ±0   0s :stopwatch: ±0s 9 tests +2  9 :heavy_check_mark: +2  0 :zzz: ±0  0 :x: ±0 

Results for commit 6b4d3342. ± Comparison against base commit 58d7adb1.

:recycle: This comment has been updated with latest results.