microsoft / vscode-docker

Docker Extension for Visual Studio Code
https://marketplace.visualstudio.com/items?itemName=ms-azuretools.vscode-docker
Other
1.19k stars 508 forks source link

ARG double evaluation #4194

Open ohhmm opened 6 months ago

ohhmm commented 6 months ago

When evaluated ARG contains another ARG reference it expected to be fully expanded. Example line: https://github.com/ohhmm/openmind/blob/e7e9170d4ebb86e32112ae0b4397db51925478f6/.devcontainer/Dockerfile#L4

ARG LLVM_MAJOR_VERSION=17
ARG LLVM_FULL_VERSION=$LLVM_MAJOR_VERSION.0.6

Hovering LLVM_FULL_VERSION hints $LLVM_MAJOR_VERSION.0.6 but 17.0.6 is expected.

dbreshears commented 6 months ago

@rcjsuen, what are your thoughts on supporting this?

rcjsuen commented 5 months ago

Very interesting use case. @ohhmm I guess it knows that the . is a word separator? If you use _ I presume Docker won't interpret things quite the same way?