Skip to content

Commit

Permalink
change appveryor node to 10 (#56)
Browse files Browse the repository at this point in the history
- change language for some prases
- change author url protocol to https
- change readme installation command
  • Loading branch information
arturparkhisenko committed Oct 16, 2020
1 parent 7679670 commit 72002c7
Show file tree
Hide file tree
Showing 9 changed files with 15 additions and 12 deletions.
3 changes: 3 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
Expand Up @@ -8,3 +8,6 @@ end_of_line = lf
insert_final_newline = true
trim_trailing_whitespace = true
charset = utf-8

[*.js]
quote_type = single
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,8 @@ By default, the messages are formatted for human legibility and sorted according

## Installation

```
npm install postcss-reporter
```shell
npm install --save-dev postcss postcss-reporter
```

Version 1.0.0+ is compatible with PostCSS 5+. (Earlier versions are compatible with PostCSS 4.)
Expand Down
2 changes: 1 addition & 1 deletion appveyor.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
environment:
matrix:
- nodejs_version: "6"
- nodejs_version: "10"

version: "{build}"
build: off
Expand Down
2 changes: 1 addition & 1 deletion index.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
var reporter = require('./lib/reporter');

module.exports = reporter;
module.exports.postcss = true
module.exports.postcss = true;
2 changes: 1 addition & 1 deletion lib/formatter.js
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ module.exports = function(opts) {
}

if (location.column) {
str += bold(':' + location.column)
str += bold(':' + location.column);
}

if (location.line || location.column) {
Expand Down
6 changes: 3 additions & 3 deletions lib/reporter.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,12 +16,12 @@ module.exports = function(opts = {}) {
// Every plugin
pluginFilter = function() { return true; };
} else if (opts.plugins.every(function(plugin) { return plugin[0] === '!'; })) {
// Blacklist
// Deny list
pluginFilter = function(message) {
return opts.plugins.indexOf('!' + message.plugin) === -1;
};
} else {
// Whitelist
// Allow list
pluginFilter = function(message) {
return opts.plugins.indexOf(message.plugin) !== -1;
};
Expand All @@ -37,7 +37,7 @@ module.exports = function(opts = {}) {
.filter(messageFilter);

var resultSource = (!result.root.source) ? ''
: result.root.source.input.file || result.root.source.input.id
: result.root.source.input.file || result.root.source.input.id;

var sourceGroupedMessages = groupBy(messagesToLog, message => {
return util.getLocation(message).file || resultSource;
Expand Down
4 changes: 2 additions & 2 deletions lib/util.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@ exports.getLocation = function(message) {

if (!messageInput) return location;

var originLocation = messageInput.origin && messageInput.origin(message.line, message.column)
if (originLocation) return originLocation
var originLocation = messageInput.origin && messageInput.origin(message.line, message.column);
if (originLocation) return originLocation;

location.file = messageInput.file || messageInput.id;
return location;
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
"author": {
"name": "David Clark",
"email": "david.dave.clark@gmail.com",
"url": "http://davidtheclark.com"
"url": "https://davidtheclark.com"
},
"license": "MIT",
"funding": {
Expand Down
2 changes: 1 addition & 1 deletion test/visual.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ fs.readFile('test/fixtures/forVisual.css', { encoding: 'utf8' }, function(err, d
var processOptions = {
from: 'test/fixtures/forVisual.css',
map: { prev: createSourceMap() },
}
};

postcss()
.use(stylelint({
Expand Down

0 comments on commit 72002c7

Please sign in to comment.