Tslint: Use default global config file

Created on 11 Feb 2015  路  8Comments  路  Source: palantir/tslint

I'm trying to figure out how can I make tslint automatically default to a global tslint.json config (like jshint does)? Or better, .tslintrc so it fits naming conventions of config files and because it's hidden.

Most helpful comment

Any news on this?

All 8 comments

~/tslint.json works for me. But I completely agree that it should be changed to a "dotfile" like every other config file does. Right now it sticks out like a sore thumb:

screen shot 2015-02-13 at 14 11 51

we can resort to a global tslint.json in the user's home directory. i disagree that the *.json nomenclature should be changed to a dotfile. every other configuration file follows the json nomenlature -- package.json, eslint.json, tsconfig.json etc.

Coffeelint is specifying coffeelint.json as default, but it works with .coffeelintrc also. And I think it's the same with jshint, but I can't say for sure since I haven't tested it with .json extension.

And it still can be .tslint.json, it's the dot that makes it hidden, extension doesn't change anything. Except the usual format of dotfiles is name without extension.

sure, we can support the dot prefix _in addition_ to the existing filename.

This should work fine. My main point was make it global and not shown in file explorer / ls by default.

Any news on this?

Showing in ls under home directory is messy and triggering. Recommend dot file

Closing this. I think tslint.json files should be project specific so that they are tracked with the rest of the project. If this is a big issue, perhaps use extends to extend a default config (which you could name .tslintconfig or similar).

Was this page helpful?
0 / 5 - 0 ratings