We need support for these file types. Many will be setup the same as each other:
@mhutch anything you can think of that's missing from this list?
For iOS and Android I would add:
.storyboard
.axml
.plist
.xib
.strings
These are all really just XML.
HTML/XML
JavaScript
JSON
We will discuss which of these file types fit our roadmap.
In order to support conditions in the places I required them, I had to add configuration for yml, Dockerfile, and nuget.config.
"SpecialCustomOperations": {
"**/*.yml": {
"operations": [
{
"type": "conditional",
"configuration": {
"if": [ "#-if" ],
"else": [ "#-else" ],
"elseif": [ "#-elseif" ],
"endif": [ "#-endif" ],
"trim": true,
"wholeLine": true,
"evaluator": "C++"
}
}
]
},
"**/Dockerfile": {
"operations": [
{
"type": "conditional",
"configuration": {
"if": [ "#-if" ],
"else": [ "#-else" ],
"elseif": [ "#-elseif" ],
"endif": [ "#-endif" ],
"trim": true,
"wholeLine": true,
"evaluator": "C++"
}
}
]
},
"**/nuget.config": {
"operations": [
{
"type": "conditional",
"configuration":{
"if": [ "<!--#if" ],
"else": [ "<!--#else" ],
"elseif": [ "<!--#elseif" ],
"endif": [ "<!--#endif" ],
"trim": true,
"wholeLine": true,
"evaluator": "C++"
}
}
]
}
}
I'd like to add:
*.md.gitattributes.editorconfigThese are the configurations I'm using to add support for *.md, *.editorconfig, Dockerfile and *.yml. Crucially, these include support for uncommenting.
"**/*.md": {
"operations": [
{
"type": "conditional",
"configuration": {
"actionableIf": [ "<!--#if" ],
"actionableElse": [ "#else", "<!--#else" ],
"actionableElseif": [ "#elseif", "<!--#elseif", "#elif", "<!--#elif" ],
"endif": [ "#endif", "<!--#endif" ],
"trim": "true",
"wholeLine": "true",
"actions": [ "fixPseudoNestedComments" ]
}
},
{
"type": "balancednesting",
"configuration": {
"id": "fixPseudoNestedComments",
"startToken": "<!--",
"realEndToken": "-->",
"pseudoEndToken": "-- >",
"resetFlag": "_TestResetFlag_"
}
}
]
},
"**/.editorconfig": {
"operations": [
{
"type": "conditional",
"configuration": {
"if": [ "#if" ],
"else": [ "#else" ],
"elseif": [ "#elseif" ],
"endif": [ "#endif" ],
"actionableIf": [ "##if" ],
"actionableElse": [ "##else" ],
"actionableElseif": [ "##elseif" ],
"actions": [ "uncomment", "reduceComment" ],
"trim": "true",
"wholeLine": "true",
"evaluator": "C++"
}
},
{
"type": "replacement",
"configuration": {
"original": "#",
"replacement": "",
"id": "uncomment"
}
},
{
"type": "replacement",
"configuration": {
"original": "##",
"replacement": "#",
"id": "reduceComment"
}
}
]
},
"**/Dockerfile": {
"operations": [
{
"type": "conditional",
"configuration": {
"if": [ "#if" ],
"else": [ "#else" ],
"elseif": [ "#elseif" ],
"endif": [ "#endif" ],
"actionableIf": [ "##if" ],
"actionableElse": [ "##else" ],
"actionableElseif": [ "##elseif" ],
"actions": [ "uncomment", "reduceComment" ],
"trim": "true",
"wholeLine": "true",
"evaluator": "C++"
}
},
{
"type": "replacement",
"configuration": {
"original": "#",
"replacement": "",
"id": "uncomment"
}
},
{
"type": "replacement",
"configuration": {
"original": "##",
"replacement": "#",
"id": "reduceComment"
}
}
]
},
"**/*.yml": {
"operations": [
{
"type": "conditional",
"configuration": {
"if": [ "#if" ],
"else": [ "#else" ],
"elseif": [ "#elseif" ],
"endif": [ "#endif" ],
"actionableIf": [ "##if" ],
"actionableElse": [ "##else" ],
"actionableElseif": [ "##elseif" ],
"actions": [ "uncomment", "reduceComment" ],
"trim": "true",
"wholeLine": "true",
"evaluator": "C++"
}
},
{
"type": "replacement",
"configuration": {
"original": "#",
"replacement": "",
"id": "uncomment"
}
},
{
"type": "replacement",
"configuration": {
"original": "##",
"replacement": "#",
"id": "reduceComment"
}
}
]
}
Most helpful comment