Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: ✨ add vscode language matching guide microblog, update aqua too…
…ling instructions
- Loading branch information
1 parent
46d3965
commit 8ad664c
Showing
2 changed files
with
41 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
33 changes: 33 additions & 0 deletions
33
content/posts/2024/2024-02-29-improve-language-matching-in-vscode.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
--- | ||
|
||
date: 2024-02-29T20:15:36+0000 | ||
title: Improve Language Matching in Vscode | ||
slug: improve-language-matching-in-vscode | ||
tags: | ||
|
||
- tech | ||
- development | ||
- microblog | ||
|
||
# images: [/images/] | ||
|
||
typora-root-url: ../../../static | ||
typora-copy-images-to: ../../../static/images | ||
--- | ||
|
||
Let's say you have the Red Hat YAML extension. | ||
This does a great job with formatting and validation. | ||
|
||
However, other directories contain files for Azure DevOps Pipelines that are also `yaml`. | ||
You can tweak the matching logic based on common paths you'd use and get those to default to a different language. | ||
|
||
```json | ||
"files.associations": { | ||
"*.json5": "json5", | ||
"CODEOWNERS": "plaintext", | ||
"*.aliases": "gitconfig", | ||
"{**/tasks/*.y*ml,**/jobs/*.y*ml,**/variables/*.y*ml,**/stages/*.y*ml,**/pipelines/*.y*ml,**/ci/*.y*ml,**/build/*.y*ml,**/templates/*.y*ml}": "azure-pipelines" | ||
}, | ||
``` | ||
|
||
You can see the icon in the explorer switch to the new type as well to have a quick visual validation. |