From 4aedf4df7798f5463fb06f5b3578f5a6c0d45680 Mon Sep 17 00:00:00 2001 From: Guillaume Tardif Date: Thu, 8 Jul 2021 17:01:16 +0200 Subject: [PATCH] Users can create Dev Env on a given branch (#13095) * Users can create Dev Env on a given branch Signed-off-by: Guillaume Tardif * Minor style updates * Add known bug on branches in https:// git urls with .git suffix Signed-off-by: Guillaume Tardif Co-authored-by: Usha Mandya <47779042+usha-mandya@users.noreply.github.com> --- desktop/dev-environments.md | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/desktop/dev-environments.md b/desktop/dev-environments.md index f96e093a5c..bc4689b45b 100644 --- a/desktop/dev-environments.md +++ b/desktop/dev-environments.md @@ -56,6 +56,22 @@ You can launch the application by running the command `make run` in your VS Code ![Single container Dev environment](/images/dev-env-localhost.png){:width="700px"} +### Create a Dev Environment from a specific branch or tag + +You can create a dev environment from a specific branch (for example, a branch corresponding to a Pull Request) or a tag by adding `@mybranch` or `@tag` as a suffix to your Git URL: + + `https://github.com/dockersamples/single-dev-env@mybranch` + + or + + `git@github.com:dockersamples/single-dev-env.git@mybranch` + +Docker then clones the repository with your specified branch or tag. + +> **Note** +> +> Known issue: when cloning a Git branch using `https://`, you must remove the `.git` suffix at the end of the URL. + ### Recap Let's summarize the tasks we performed so far to start a single container Dev Environment.