Skip to content

Commit

Permalink
docs: update
Browse files Browse the repository at this point in the history
  • Loading branch information
bluwy committed Aug 13, 2024
1 parent 9f9408a commit bafb639
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion site/rules.md
Original file line number Diff line number Diff line change
Expand Up @@ -244,6 +244,6 @@ The `"jsnext:main"` and `"jsnext"` fields are deprecated. The `"module"` field s
`publint` is able to detect some cases where the `"repository"` field is not a valid and may not properly display on https://npmjs.com. The sub-rules below are mostly based on the [`"repository"` field docs](https://docs.npmjs.com/cli/v10/configuring-npm/package-json#repository).

- If `"repository"` is a string, it must be one of the supported shorthand strings from the docs.
- If `"repository"` is an object with `"type": "git"`, the `"url"` must ba a valid [git URL](https://git-scm.com/docs/git-clone#_git_urls).
- If `"repository"` is an object with `"type": "git"`, the `"url"` must be a valid [git URL](https://git-scm.com/docs/git-clone#_git_urls) and can be [parsed by npm](https://github.com/npm/hosted-git-info).
- The `git://` protocol for GitHub repos should not be used due [security concerns](https://github.blog/security/application-security/improving-git-protocol-security-github/).
- GitHub or GitLab links should be prefixed with `git+` and postfixed with `.git`. (This is also warned by npm when publishing a package).

0 comments on commit bafb639

Please sign in to comment.