Closed rwols closed 2 years ago
ping @asbjornenge
@rwols, I like the idea, but what about other scenarios where bash is not the shell? One such example is windows containers...
@andyneff huh, I was not aware of running powershell statements in a Dockerfile. Let me change this this into an auxiliary syntax then.
Now there's two sublime-syntaxes, one for the "generic" case and one assuming bash. The bash one has no first line match, and has no files associated to it. So the generic one will always be used when opening a Dockerfile. However, users can override this (using "Open all with current extension as..." for example), or they can select this variant in the command palette.
Hi!
Thanks for a great PR @rwols :tada: I'm currently on holiday in Spain (and will be for two more weeks), so limited time to reply and review. In general I really like the idea of highlighting the shell scripts syntax, but I'm not sure we should be adding assumptions like this into the repo, even if bash is the most common by far 🤔 Perhaps better that this exists as a separate fork and users can "opt in" by downloading and selecting it...?
I would gladly accept an updated README.md with links to useful forks :+1:
Thoughts @princemaple ?
Had a quick look. Will do some digging before coming back to it. (On phone)
@asbjornenge if @rwols is willing to maintain this version, it totally can live in this repo.
@rwols in our original version we highlight CMD and ENTRYPOINT a little differently to indicate that they are runtime commands. Your version seems to treat everything the same? Just an idea.
Also Raoul, from_directive
is unused in your syntax.
willing to maintain this version, it totally can live in this repo.
Sure, no problem. I'll keep an eye on the issues.
in our original version we highlight CMD and ENTRYPOINT a little differently to indicate that they are runtime commands. Your version seems to treat everything the same? Just an idea.
I'll have a look at it in the weekend.
Should we merge this or what? I have not worked on this repo for years 😂
//cc @princemaple
🤔 woah.
This might be not as up-to-date as we'd hope today, but we can iterate on it.
I've been using this modified branch for a while now, and it works great for my purposes. Basically we include the shell script syntax where appropriate to get highlighting for
RUN
commands et al. Also, a part of the JSON syntax is included for things likeENTRYPOINT
.Here is a screenshot on how that looks: