mirror of
https://github.com/DavidAnson/markdownlint.git
synced 2025-09-21 21:30:47 +02:00
Update copyright year to 2019, all HTTP links to HTTPS.
This commit is contained in:
parent
045238740f
commit
90bd0810e7
16 changed files with 59 additions and 59 deletions
2
LICENSE
2
LICENSE
|
@ -1,6 +1,6 @@
|
||||||
The MIT License (MIT)
|
The MIT License (MIT)
|
||||||
|
|
||||||
Copyright (c) 2015-2018 David Anson
|
Copyright (c) 2015-2019 David Anson
|
||||||
|
|
||||||
Permission is hereby granted, free of charge, to any person obtaining a copy
|
Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||||
of this software and associated documentation files (the "Software"), to deal
|
of this software and associated documentation files (the "Software"), to deal
|
||||||
|
|
|
@ -19,7 +19,7 @@ The [Markdown](https://en.wikipedia.org/wiki/Markdown) markup language is
|
||||||
designed to be easy to read, write, and understand. It succeeds - and its
|
designed to be easy to read, write, and understand. It succeeds - and its
|
||||||
flexibility is both a benefit and a drawback. Many styles are possible, so
|
flexibility is both a benefit and a drawback. Many styles are possible, so
|
||||||
formatting can be inconsistent. Some constructs don't work well in all
|
formatting can be inconsistent. Some constructs don't work well in all
|
||||||
parsers and should be avoided. The [CommonMark](http://commonmark.org/)
|
parsers and should be avoided. The [CommonMark](https://commonmark.org/)
|
||||||
specification standardizes parsers - but not authors.
|
specification standardizes parsers - but not authors.
|
||||||
|
|
||||||
`markdownlint` is a [static analysis](https://en.wikipedia.org/wiki/Static_program_analysis)
|
`markdownlint` is a [static analysis](https://en.wikipedia.org/wiki/Static_program_analysis)
|
||||||
|
@ -287,7 +287,7 @@ const options = {
|
||||||
See the [style](style) directory for more samples.
|
See the [style](style) directory for more samples.
|
||||||
|
|
||||||
See [markdownlint-config-schema.json](schema/markdownlint-config-schema.json)
|
See [markdownlint-config-schema.json](schema/markdownlint-config-schema.json)
|
||||||
for the [JSON Schema](http://json-schema.org/) of the `options.config` object.
|
for the [JSON Schema](https://json-schema.org/) of the `options.config` object.
|
||||||
|
|
||||||
For more advanced scenarios, styles can reference and extend other styles. The
|
For more advanced scenarios, styles can reference and extend other styles. The
|
||||||
`readConfig` and `readConfigSync` functions can be used to read such styles.
|
`readConfig` and `readConfigSync` functions can be used to read such styles.
|
||||||
|
@ -581,7 +581,7 @@ Output:
|
||||||
}
|
}
|
||||||
```
|
```
|
||||||
|
|
||||||
Integration with the [gulp](http://gulpjs.com/) build system is straightforward:
|
Integration with the [gulp](https://gulpjs.com/) build system is straightforward:
|
||||||
|
|
||||||
```js
|
```js
|
||||||
const gulp = require("gulp");
|
const gulp = require("gulp");
|
||||||
|
@ -615,7 +615,7 @@ bad.md: 1: MD041/first-line-h1 First line in file should be a top level heading
|
||||||
[00:00:00] Finished 'markdownlint' after 10 ms
|
[00:00:00] Finished 'markdownlint' after 10 ms
|
||||||
```
|
```
|
||||||
|
|
||||||
Integration with the [Grunt](http://gruntjs.com/) build system is similar:
|
Integration with the [Grunt](https://gruntjs.com/) build system is similar:
|
||||||
|
|
||||||
```js
|
```js
|
||||||
const markdownlint = require("markdownlint");
|
const markdownlint = require("markdownlint");
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
<?xml version="1.0"?>
|
<?xml version="1.0"?>
|
||||||
<configuration>
|
<configuration>
|
||||||
<!-- Standard ASP.NET configuration; see http://go.microsoft.com/fwlink/?LinkId=169433 -->
|
<!-- Standard ASP.NET configuration; see https://go.microsoft.com/fwlink/?LinkId=169433 -->
|
||||||
<system.web>
|
<system.web>
|
||||||
<compilation debug="false" targetFramework="4.0"/>
|
<compilation debug="false" targetFramework="4.0"/>
|
||||||
</system.web>
|
</system.web>
|
||||||
|
|
|
@ -28,7 +28,7 @@
|
||||||
<div class="flex-columns inset">
|
<div class="flex-columns inset">
|
||||||
<footer><a href="https://github.com/DavidAnson/markdownlint">markdownlint project on GitHub</a></footer>
|
<footer><a href="https://github.com/DavidAnson/markdownlint">markdownlint project on GitHub</a></footer>
|
||||||
<div class="flex-fill"></div>
|
<div class="flex-fill"></div>
|
||||||
<footer>Copyright © 2015-2018 by <a href="//dlaa.me/">David Anson</a></footer>
|
<footer>Copyright © 2015-2019 by <a href="https://dlaa.me/">David Anson</a></footer>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<script src="markdown-it.min.js"></script>
|
<script src="markdown-it.min.js"></script>
|
||||||
|
|
|
@ -143,7 +143,7 @@
|
||||||
markdown.value = [
|
markdown.value = [
|
||||||
"## Introduction",
|
"## Introduction",
|
||||||
"",
|
"",
|
||||||
"`markdownlint` is a [Node.js](https://nodejs.org/)/[io.js](https://iojs.org/) style checker and lint tool for [Markdown](http://en.wikipedia.org/wiki/Markdown)/[CommonMark](http://commonmark.org/) files to automatically validate content, prevent rendering problems, and promote consistency.",
|
"`markdownlint` is a [Node.js](https://nodejs.org/)/[io.js](https://iojs.org/) style checker and lint tool for [Markdown](https://en.wikipedia.org/wiki/Markdown)/[CommonMark](https://commonmark.org/) files to automatically validate content, prevent rendering problems, and promote consistency.",
|
||||||
"This page offers an easy way to try it out interactively!",
|
"This page offers an easy way to try it out interactively!",
|
||||||
"",
|
"",
|
||||||
"#### Instructions",
|
"#### Instructions",
|
||||||
|
@ -158,8 +158,8 @@
|
||||||
"#### Resources",
|
"#### Resources",
|
||||||
"* [`markdownlint` on GitHub](https://github.com/DavidAnson/markdownlint)",
|
"* [`markdownlint` on GitHub](https://github.com/DavidAnson/markdownlint)",
|
||||||
"* [`markdownlint` on npm](https://www.npmjs.com/package/markdownlint)",
|
"* [`markdownlint` on npm](https://www.npmjs.com/package/markdownlint)",
|
||||||
"* [Markdown specification](http://daringfireball.net/projects/markdown/)",
|
"* [Markdown specification](https://daringfireball.net/projects/markdown/)",
|
||||||
"*\t[CommonMark specification](http://commonmark.org/)",
|
"*\t[CommonMark specification](https://commonmark.org/)",
|
||||||
"",
|
"",
|
||||||
"#### Thanks",
|
"#### Thanks",
|
||||||
"",
|
"",
|
||||||
|
|
|
@ -62,7 +62,7 @@ A rule is implemented as an `Object` with four required properties:
|
||||||
|
|
||||||
## References
|
## References
|
||||||
|
|
||||||
- [CommonMark documentation and specification](http://commonmark.org/)
|
- [CommonMark documentation and specification](https://commonmark.org/)
|
||||||
- [`markdown-it` Markdown parser project page](https://github.com/markdown-it/markdown-it)
|
- [`markdown-it` Markdown parser project page](https://github.com/markdown-it/markdown-it)
|
||||||
|
|
||||||
## Params
|
## Params
|
||||||
|
|
20
doc/Rules.md
20
doc/Rules.md
|
@ -294,7 +294,7 @@ when a single space is used after the list marker.
|
||||||
|
|
||||||
Rationale (4 space indent): Same indent as code blocks, simpler for editors to
|
Rationale (4 space indent): Same indent as code blocks, simpler for editors to
|
||||||
implement. See
|
implement. See
|
||||||
<http://www.cirosantilli.com/markdown-styleguide/#indented-lists> for more
|
<https://www.cirosantilli.com/markdown-style-guide/#indentation-of-content-inside-lists> for more
|
||||||
information.
|
information.
|
||||||
|
|
||||||
In addition, this is a compatibility issue with multi-markdown parsers, which
|
In addition, this is a compatibility issue with multi-markdown parsers, which
|
||||||
|
@ -383,13 +383,13 @@ where the syntax appears to have been reversed (the `[]` and `()` are
|
||||||
reversed):
|
reversed):
|
||||||
|
|
||||||
```markdown
|
```markdown
|
||||||
(Incorrect link syntax)[http://www.example.com/]
|
(Incorrect link syntax)[https://www.example.com/]
|
||||||
```
|
```
|
||||||
|
|
||||||
To fix this, swap the `[]` and `()` around:
|
To fix this, swap the `[]` and `()` around:
|
||||||
|
|
||||||
```markdown
|
```markdown
|
||||||
[Correct link syntax](http://www.example.com/)
|
[Correct link syntax](https://www.example.com/)
|
||||||
```
|
```
|
||||||
|
|
||||||
Note: [Markdown Extra](https://en.wikipedia.org/wiki/Markdown_Extra)-style footnotes do not trigger this rule:
|
Note: [Markdown Extra](https://en.wikipedia.org/wiki/Markdown_Extra)-style footnotes do not trigger this rule:
|
||||||
|
@ -499,7 +499,7 @@ baz
|
||||||
|
|
||||||
Rationale: it is easier to copy and paste and less noisy if the dollar signs
|
Rationale: it is easier to copy and paste and less noisy if the dollar signs
|
||||||
are omitted when they are not needed. See
|
are omitted when they are not needed. See
|
||||||
<http://www.cirosantilli.com/markdown-styleguide/#dollar-signs-in-shell-code>
|
<https://www.cirosantilli.com/markdown-style-guide/#dollar-signs-in-shell-code>
|
||||||
for more information.
|
for more information.
|
||||||
|
|
||||||
<a name="md018"></a>
|
<a name="md018"></a>
|
||||||
|
@ -941,7 +941,7 @@ of every item in the list consists of a single paragraph, or multiple
|
||||||
paragraphs (including sub-lists and code blocks).
|
paragraphs (including sub-lists and code blocks).
|
||||||
|
|
||||||
For example, the style guide at
|
For example, the style guide at
|
||||||
<http://www.cirosantilli.com/markdown-styleguide/#spaces-after-marker>
|
<https://www.cirosantilli.com/markdown-style-guide/#spaces-after-list-marker>
|
||||||
specifies that 1 space after the list marker should be used if every item in
|
specifies that 1 space after the list marker should be used if every item in
|
||||||
the list fits within a single paragraph, but to use 2 or 3 spaces (for ordered
|
the list fits within a single paragraph, but to use 2 or 3 spaces (for ordered
|
||||||
and unordered lists respectively) if there are multiple paragraphs of content
|
and unordered lists respectively) if there are multiple paragraphs of content
|
||||||
|
@ -1109,13 +1109,13 @@ This rule is triggered whenever a URL is given that isn't surrounded by angle
|
||||||
brackets:
|
brackets:
|
||||||
|
|
||||||
```markdown
|
```markdown
|
||||||
For more information, see http://www.example.com/.
|
For more information, see https://www.example.com/.
|
||||||
```
|
```
|
||||||
|
|
||||||
To fix this, add angle brackets around the URL:
|
To fix this, add angle brackets around the URL:
|
||||||
|
|
||||||
```markdown
|
```markdown
|
||||||
For more information, see <http://www.example.com/>.
|
For more information, see <https://www.example.com/>.
|
||||||
```
|
```
|
||||||
|
|
||||||
Rationale: Without angle brackets, the URL isn't converted into a link in many
|
Rationale: Without angle brackets, the URL isn't converted into a link in many
|
||||||
|
@ -1126,7 +1126,7 @@ enclose it in a code block, otherwise in some markdown parsers it _will_ be
|
||||||
converted:
|
converted:
|
||||||
|
|
||||||
```markdown
|
```markdown
|
||||||
`http://www.example.com`
|
`https://www.example.com`
|
||||||
```
|
```
|
||||||
|
|
||||||
<a name="md035"></a>
|
<a name="md035"></a>
|
||||||
|
@ -1294,13 +1294,13 @@ Aliases: no-space-in-links
|
||||||
This rule is triggered on links that have spaces surrounding the link text:
|
This rule is triggered on links that have spaces surrounding the link text:
|
||||||
|
|
||||||
```markdown
|
```markdown
|
||||||
[ a link ](http://www.example.com/)
|
[ a link ](https://www.example.com/)
|
||||||
```
|
```
|
||||||
|
|
||||||
To fix this, remove the spaces surrounding the link text:
|
To fix this, remove the spaces surrounding the link text:
|
||||||
|
|
||||||
```markdown
|
```markdown
|
||||||
[a link](http://www.example.com/)
|
[a link](https://www.example.com/)
|
||||||
```
|
```
|
||||||
|
|
||||||
<a name="md040"></a>
|
<a name="md040"></a>
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
{
|
{
|
||||||
"comment": "Rules for the style guide at http://www.cirosantilli.com/markdown-style-guide/",
|
"comment": "Rules for the style guide at https://www.cirosantilli.com/markdown-style-guide/",
|
||||||
|
|
||||||
"default": true,
|
"default": true,
|
||||||
"MD003": {
|
"MD003": {
|
||||||
|
|
|
@ -54,7 +54,7 @@ Note: Can not break MD025 and MD002 in the same file
|
||||||
|
|
||||||
<br/> {MD033}
|
<br/> {MD033}
|
||||||
|
|
||||||
http://example.com/page {MD034}
|
https://example.com/page {MD034}
|
||||||
|
|
||||||
---
|
---
|
||||||
|
|
||||||
|
|
|
@ -5,7 +5,7 @@ debugger;
|
||||||
|
|
||||||
Inline<hr/>HTML
|
Inline<hr/>HTML
|
||||||
|
|
||||||
Bare http://example.com link
|
Bare https://example.com link
|
||||||
|
|
||||||
---
|
---
|
||||||
***
|
***
|
||||||
|
|
|
@ -41,8 +41,8 @@
|
||||||
"ruleDescription": "Bare URL used",
|
"ruleDescription": "Bare URL used",
|
||||||
"ruleInformation": "https://github.com/DavidAnson/markdownlint/blob/v0.0.0/doc/Rules.md#md034",
|
"ruleInformation": "https://github.com/DavidAnson/markdownlint/blob/v0.0.0/doc/Rules.md#md034",
|
||||||
"errorDetail": null,
|
"errorDetail": null,
|
||||||
"errorContext": "http://example.com",
|
"errorContext": "https://example.com",
|
||||||
"errorRange": [6, 18]
|
"errorRange": [6, 19]
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"lineNumber": 11,
|
"lineNumber": 11,
|
||||||
|
|
|
@ -6,7 +6,7 @@ tags:
|
||||||
- tag
|
- tag
|
||||||
- another tag
|
- another tag
|
||||||
- one more tag
|
- one more tag
|
||||||
url: http://example.com
|
url: https://example.com
|
||||||
excerpt: Hello World! Vestibulum imperdiet adipiscing arcu, quis aliquam dolor condimentum dapibus. Aliquam fermentum leo aliquet quam volutpat et molestie mauris mattis. Suspendisse semper consequat velit in suscipit.
|
excerpt: Hello World! Vestibulum imperdiet adipiscing arcu, quis aliquam dolor condimentum dapibus. Aliquam fermentum leo aliquet quam volutpat et molestie mauris mattis. Suspendisse semper consequat velit in suscipit.
|
||||||
---
|
---
|
||||||
# heading1
|
# heading1
|
||||||
|
|
|
@ -1,13 +1,13 @@
|
||||||
# Link test
|
# Link test
|
||||||
|
|
||||||
For more information, please see the
|
For more information, please see the
|
||||||
following page: http://www.example.com/ {MD034}
|
following page: https://www.example.com/ {MD034}
|
||||||
which will tell you all you want to know.
|
which will tell you all you want to know.
|
||||||
|
|
||||||
http://www.google.com/ {MD034}
|
https://www.google.com/ {MD034}
|
||||||
|
|
||||||
hTtPs://gOoGlE.cOm/ {MD034}
|
hTtPs://gOoGlE.cOm/ {MD034}
|
||||||
|
|
||||||
ftp://user:password@ftp-server.example.com/dir/file.txt {MD034}
|
ftp://user:password@ftp-server.example.com/dir/file.txt {MD034}
|
||||||
|
|
||||||
This link should be fine: <http://www.google.com/>
|
This link should be fine: <https://www.google.com/>
|
||||||
|
|
|
@ -2,44 +2,44 @@ This is a very very very very very very very very very very very very very very
|
||||||
|
|
||||||
This line however, while very long, doesn't have whitespace after the 80th columnwhichallowsforURLsandotherlongthings.
|
This line however, while very long, doesn't have whitespace after the 80th columnwhichallowsforURLsandotherlongthings.
|
||||||
|
|
||||||
[This long line is comprised entirely of a link](http://example.com "This is the long link's title")
|
[This long line is comprised entirely of a link](https://example.com "This is the long link's title")
|
||||||
|
|
||||||
> [This long line is comprised entirely of a link](http://example.com "This is the long link's title")
|
> [This long line is comprised entirely of a link](https://example.com "This is the long link's title")
|
||||||
|
|
||||||
[This long line is comprised entirely of a link](http://example.com "But is inside a code block") {MD013}
|
[This long line is comprised entirely of a link](https://example.com "But is inside a code block") {MD013}
|
||||||
|
|
||||||
```markdown
|
```markdown
|
||||||
[This long line is comprised entirely of a link](http://example.com "But is inside a code block") {MD013}
|
[This long line is comprised entirely of a link](https://example.com "But is inside a code block") {MD013}
|
||||||
```
|
```
|
||||||
|
|
||||||
This [long line is comprised mostly of a link](http://example.com "This is the long link's title") {MD013}
|
This [long line is comprised mostly of a link](https://example.com "This is the long link's title") {MD013}
|
||||||
|
|
||||||
[This long line is comprised mostly of a link](http://example.com "This is the long link's title") text {MD013}
|
[This long line is comprised mostly of a link](https://example.com "This is the long link's title") text {MD013}
|
||||||
|
|
||||||
This long line includes a simple [reference][label] link and is long enough to violate the rule. {MD013}
|
This long line includes a simple [reference][label] link and is long enough to violate the rule. {MD013}
|
||||||
|
|
||||||
[This long line is comprised entirely of a reference link and is long enough to violate the rule][label]
|
[This long line is comprised entirely of a reference link and is long enough to violate the rule][label]
|
||||||
|
|
||||||
[label]: http://example.org "Title for a link reference that is itself long enough to violate the rule"
|
[label]: https://example.org "Title for a link reference that is itself long enough to violate the rule"
|
||||||
|
|
||||||
[Link to broken label][notlabel]
|
[Link to broken label][notlabel]
|
||||||
|
|
||||||
[notlabel\]: notlink "Invalid syntax for a link label because the right bracket is backslash-escaped {MD013}"
|
[notlabel\]: notlink "Invalid syntax for a link label because the right bracket is backslash-escaped {MD013}"
|
||||||
|
|
||||||
[](http://example.com "This long line is comprised entirely of a link with empty text and a non-empty title")
|
[](https://example.com "This long line is comprised entirely of a link with empty text and a non-empty title")
|
||||||
|
|
||||||
*[This long line is comprised of an emphasized link](http://example.com "This is the long link's title")*
|
*[This long line is comprised of an emphasized link](https://example.com "This is the long link's title")*
|
||||||
|
|
||||||
_[This long line is comprised of an emphasized link](http://example.com "This is the long link's title")_
|
_[This long line is comprised of an emphasized link](https://example.com "This is the long link's title")_
|
||||||
|
|
||||||
**[This long line is comprised of a bolded link](http://example.com "This is the long link's title")**
|
**[This long line is comprised of a bolded link](https://example.com "This is the long link's title")**
|
||||||
|
|
||||||
__[This long line is comprised of a bolded link](http://example.com "This is the long link's title")__
|
__[This long line is comprised of a bolded link](https://example.com "This is the long link's title")__
|
||||||
|
|
||||||
_**[This long line is comprised of an emphasized and bolded link](http://example.com "This is the long link's title")**_
|
_**[This long line is comprised of an emphasized and bolded link](https://example.com "This is the long link's title")**_
|
||||||
|
|
||||||
**_[This long line is comprised of an emphasized and bolded link](http://example.com "This is the long link's title")_**
|
**_[This long line is comprised of an emphasized and bolded link](https://example.com "This is the long link's title")_**
|
||||||
|
|
||||||
*[](http://example.com "This long line is comprised of an emphasized link with empty text and a non-empty title")*
|
*[](https://example.com "This long line is comprised of an emphasized link with empty text and a non-empty title")*
|
||||||
|
|
||||||
**[](http://example.com "This long line is comprised of a bolded link with empty text and a non-empty title")**
|
**[](https://example.com "This long line is comprised of a bolded link with empty text and a non-empty title")**
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
Go to (this website)[http://www.example.com] {MD011} {MD034}
|
Go to (this website)[https://www.example.com] {MD011} {MD034}
|
||||||
|
|
||||||
However, this shouldn't trigger inside code blocks:
|
However, this shouldn't trigger inside code blocks:
|
||||||
|
|
||||||
|
|
|
@ -1,26 +1,26 @@
|
||||||
[foo](http://bar/)
|
[foo](https://bar/)
|
||||||
|
|
||||||
["foo"](http:/bar/)
|
["foo"](https://bar/)
|
||||||
|
|
||||||
[`foo`](http://bar/)
|
[`foo`](https://bar/)
|
||||||
|
|
||||||
[*foo*](http://bar/)
|
[*foo*](https://bar/)
|
||||||
|
|
||||||
[**foo**](http://bar/)
|
[**foo**](https://bar/)
|
||||||
|
|
||||||
[foo "bar"](http:/baz/)
|
[foo "bar"](https://baz/)
|
||||||
|
|
||||||
[foo ](http://bar/) {MD039}
|
[foo ](https://bar/) {MD039}
|
||||||
|
|
||||||
[ foo](http://bar/) {MD039}
|
[ foo](https://bar/) {MD039}
|
||||||
|
|
||||||
[ foo ](http://bar/) {MD039}
|
[ foo ](https://bar/) {MD039}
|
||||||
|
|
||||||
[ "foo" ](http://bar/) {MD039}
|
[ "foo" ](https://bar/) {MD039}
|
||||||
|
|
||||||
[ `foo` ](http://bar/) {MD039}
|
[ `foo` ](https://bar/) {MD039}
|
||||||
|
|
||||||
[ *foo* ](http://bar/) {MD039}
|
[ *foo* ](https://bar/) {MD039}
|
||||||
|
|
||||||
The following shouldn't break anything:
|
The following shouldn't break anything:
|
||||||
[](/images/Screenshot.png)
|
[](/images/Screenshot.png)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue