Last active
December 18, 2017 16:02
-
-
Save mildronize/da6e2f2ce1d4d97c99f81648918d8066 to your computer and use it in GitHub Desktop.
Docker Cmder Alias - setup docker environment if the docker machine is started
This file contains hidden or 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
| @ECHO OFF | |
| @FOR /f "tokens=*" %%i IN ('docker-machine status') DO ( | |
| @IF "%%i"=="Running" ( | |
| @FOR /f "tokens=*" %%j IN ('docker-machine env') DO @%%j | |
| ) | |
| ) |
This file contains hidden or 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
| ;= Docker | |
| docker-start=docker-machine start & "%CMDER_ROOT%\config\docker-env.bat" | |
| docker-stop=docker-machine stop |
This file contains hidden or 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
| call "%CMDER_ROOT%\config\docker-env.bat" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment