Releases: huff-language/vscode-huff
Wsl main release - syntax highlighting improvements
Released wsl support from pre-release, the workaround mentioned in release 0.0.27
still stands and is detailed within the readme.
Many thanks to @sintaro0221 for pushing to add syntax highlighting for custom errors. That has also been included in this release.
0.0.27 - WSL Support
Overview
This release addresses the extension environment for users running in the wsl runtime.
There is another quality of life regex improvement where over matching occurred in some edge cases.
Cause of the wsl issue
Before this pr the extension had no wsl support. Vscode extensions run in a separate environment to wsl, therefore if any users have installed huffc through wsl the extension was unable to find it.
Fix
I've added some checks throughout the code which detect if the user is operating in wsl and if so, the commands are piped through wsl instead.
Caveats
This is a NOT a complete fix, if the user has install through huffup a workaround is required to get it working. Unfortunately the wsl api does NOT run ~/.bashrc
whenever a fresh shell is created. Commands such as -l which are supposed to force execute the ~/.profile
scripts do not also run ~/.bashrc
even if it is EXPRESSLY included in the profile script itself. I am not sure what causes this behaviour, I am also not sure if this issue exists on all machines. But it was an issue that I faced when creating this patch.
Therefore, in order to get this integration to work, huffc must be added to the path within the ~/.profile
script rather than a ~/*rc
script.
Add this snippet below to your profile if you installed using huffup:
if [ -d "$HOME/.huff/bin" ]; then
PATH="$HOME/.huff/bin:$PATH"
fi
Acknowledgements
- discord::@uncle_scrooge For bringing this to our attention.