I want to use the Black formatter for my Python files, but not for my JSON settings.
I have these set in my settings.json:
"python.formatting.provider": "black",
"editor.formatOnSave": true,
I have tried to use the --exclude tag by adding the following to settings.json:
"python.formatting.blackArgs": [
"--exclude /*\\.json/"
],
which is equivalent to a commandline call with black --exclude /*\.json/
I also tried
"python.formatting.blackArgs": [
"--exclude /*\\.json/"
],
based on this post: VS Code Python + Black formatter arguments - python.formatting.blackArgs.
However, it is still formatting my settings.json.