Skip to content

Add support for *.hlsl and *.hlsli#572

Merged
asottile merged 1 commit intopre-commit:mainfrom
petamas:add-hlsl
Feb 20, 2026
Merged

Add support for *.hlsl and *.hlsli#572
asottile merged 1 commit intopre-commit:mainfrom
petamas:add-hlsl

Conversation

@petamas
Copy link
Contributor

@petamas petamas commented Feb 10, 2026

Documentation: https://learn.microsoft.com/en-us/windows/win32/direct3dhlsl/dx-graphics-hlsl

I did not find any direct source in the above docs saying that .hlsl is the standard extension, but Google's not giving me anything else, so it seem unambigiouos enough.

I've found this on the Stack Overflow answer on the .hlsl / .hlsli distinction though, and it matches existing practice I've seen in the wild: https://stackoverflow.com/questions/46809070/what-is-the-difference-between-hlsl-and-hlsli

'hbs': {'text', 'handlebars'},
'hcl': {'text', 'hcl'},
'hlsl': {'text', 'hlsl'},
'hlsli': {'text', 'header', 'hlsl'},
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

generally header is meant for c / c++ headers and really isn't that useful of a tag so I'm not adding it to new things

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That's fine by me, I only included it because it already existed, and to be able to potentially differentiate between the two extensions.

@asottile asottile enabled auto-merge February 20, 2026 00:10
@asottile asottile merged commit 7783767 into pre-commit:main Feb 20, 2026
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

2 participants