diff --git a/services/amo/amo-downloads.service.js b/services/amo/amo-downloads.service.js index 795deecd4d3fc..ae61a534e0106 100644 --- a/services/amo/amo-downloads.service.js +++ b/services/amo/amo-downloads.service.js @@ -3,11 +3,9 @@ import { redirector } from '../index.js' import { BaseAmoService, keywords } from './amo-base.js' const documentation = ` -
- Previously amo/d
provided a “total downloads” badge. However,
- updates to the v3 API only
- give us weekly downloads. The route amo/d
redirects to amo/dw
.
-
- A badge requires three pieces of information: ORGANIZATION
,
- PROJECT_ID
and DEFINITION_ID
.
-
- To start, edit your build definition and look at the url: -
+A badge requires three pieces of information: +\`ORGANIZATION\`, \`PROJECT_ID\` and \`DEFINITION_ID\`. + +To start, edit your build definition and look at the url: +
- Then use the Azure DevOps REST API to translate the
- PROJECT_NAME
to a PROJECT_ID
.
-
- Navigate to https://dev.azure.com/ORGANIZATION/_apis/projects/PROJECT_NAME
-
- To obtain your own badge, you need to get 3 pieces of information:
- ORGANIZATION
, PROJECT
and DEFINITION_ID
.
-
- First, you need to select your build definition and look at the url: -
+To obtain your own badge, you need to get 3 pieces of information: +\`ORGANIZATION\`, \`PROJECT_ID\` and \`DEFINITION_ID\`. + +First, you need to select your build definition and look at the url: +
- Your badge will then have the form:
- https://img.shields.io/azure-devops/coverage/ORGANIZATION/PROJECT/DEFINITION_ID.svg
.
-
- Optionally, you can specify a named branch:
- https://img.shields.io/azure-devops/coverage/ORGANIZATION/PROJECT/DEFINITION_ID/NAMED_BRANCH.svg
.
-
- To obtain your own badge, you need to get 4 pieces of information:
- ORGANIZATION
, PROJECT_ID
, DEFINITION_ID
and ENVIRONMENT_ID
.
-
- First, you need to enable badges for each required environments in the options of your release definition. - Once you have save the change, look at badge url: -
+To obtain your own badge, you need to get 4 pieces of information: +\`ORGANIZATION\`, \`PROJECT_ID\`, \`DEFINITION_ID\` and \`ENVIRONMENT_ID\`. + +First, you need to enable badges for each required environments in the options of your release definition. +Once you have save the change, look at badge url: +
- Your badge will then have the form:
- https://img.shields.io/vso/release/ORGANIZATION/PROJECT_ID/DEFINITION_ID/ENVIRONMENT_ID.svg
.
-
- To obtain your own badge, you need to get 3 pieces of information:
- ORGANIZATION
, PROJECT
and DEFINITION_ID
.
-
- First, you need to select your build definition and look at the url: -
+To obtain your own badge, you need to get 3 pieces of information: +\`ORGANIZATION\`, \`PROJECT_ID\`, \`DEFINITION_ID\`. + +First, you need to select your build definition and look at the url: +
- Your badge will then have the form:
- https://img.shields.io/azure-devops/tests/ORGANIZATION/PROJECT/DEFINITION_ID.svg
.
-
- Optionally, you can specify a named branch:
- https://img.shields.io/azure-devops/tests/ORGANIZATION/PROJECT/DEFINITION_ID/NAMED_BRANCH.svg
.
-
namedLogo
- The All Contributors service allows you to recognize all your project - contributors, including those that don't push code. See - https://allcontributors.org - for more information. -
+The All Contributors service allows you to recognize all your project +contributors, including those that don't push code. See +[https://allcontributors.org](https://allcontributors.org) +for more information. + ${commonDocumentation} ` diff --git a/services/github/github-hacktoberfest.service.js b/services/github/github-hacktoberfest.service.js index f75b20507c7f5..cb8139b69a19b 100644 --- a/services/github/github-hacktoberfest.service.js +++ b/services/github/github-hacktoberfest.service.js @@ -10,31 +10,24 @@ import { } from './github-helpers.js' const documentation = ` -- This badge is designed for projects hosted on GitHub which are - participating in - Hacktoberfest, - an initiative to encourage participating in open-source projects. The - badge can be added to the project readme to encourage potential - contributors to review the suggested issues and to celebrate the - contributions that have already been made. - The badge displays three pieces of information: -
?suggestion_label=good%20first%20issue
).
- - If your GitHub badge errors, it might be because you hit GitHub's rate limits. - You can increase Shields.io's rate limit by - adding the Shields GitHub - application using your GitHub account. -
+If your GitHub badge errors, it might be because you hit GitHub's rate limits. +You can increase Shields.io's rate limit by +[adding the Shields GitHub application](https://img.shields.io/github-auth) +using your GitHub account. ` function issueStateColor(s) { diff --git a/services/github/github-pipenv.service.js b/services/github/github-pipenv.service.js index bb8ad5039bbe8..aa403be38938f 100644 --- a/services/github/github-pipenv.service.js +++ b/services/github/github-pipenv.service.js @@ -10,33 +10,25 @@ import { documentation as githubDocumentation } from './github-helpers.js' const keywords = ['pipfile'] const documentation = ` -
- Pipenv is a dependency
- manager for Python which manages a
- virtualenv for
- projects. It adds/removes packages from your Pipfile
as
- you install/uninstall packages and generates the ever-important
- Pipfile.lock
, which can be checked in to source control
- in order to produce deterministic builds.
-
- The GitHub Pipenv badges are intended for applications using Pipenv - which are hosted on GitHub. -
- -
- When Pipfile.lock
is checked in, the GitHub Pipenv
- locked dependency version badge displays the locked version of
- a dependency listed in [packages]
or
- [dev-packages]
(or any of their transitive dependencies).
-
- Usually a Python version is specified in the Pipfile
, which
- pipenv lock
then places in Pipfile.lock
. The
- GitHub Pipenv Python version badge displays that version.
-
- You may use your GitLab Project Id (e.g. 278964) or your Project Path (e.g. gitlab-org/gitlab ). - Note that only internet-accessible GitLab instances are supported, for example https://jihulab.com, https://gitlab.gnome.org, or https://gitlab.com/. -
-` - export default class GitlabForks extends GitLabBase { static category = 'social' diff --git a/services/gitlab/gitlab-helper.js b/services/gitlab/gitlab-helper.js index 0580ea5840dcc..1f2a5947aafc5 100644 --- a/services/gitlab/gitlab-helper.js +++ b/services/gitlab/gitlab-helper.js @@ -1,12 +1,10 @@ const documentation = ` -- You may use your GitLab Project Id (e.g. 278964) or your Project Path (e.g. - gitlab-org/gitlab ). - Note that only internet-accessible GitLab instances are supported, for example - https://jihulab.com, - https://gitlab.gnome.org, or - https://gitlab.com. -
+You may use your GitLab Project Id (e.g. 278964) or your Project Path (e.g. +[gitlab-org/gitlab](https://gitlab.com/gitlab-org/gitlab) ). +Note that only internet-accessible GitLab instances are supported, for example +[https://jihulab.com](https://jihulab.com), +[https://gitlab.gnome.org](https://gitlab.gnome.org), or +[https://gitlab.com](https://gitlab.com). ` function httpErrorsFor(notFoundMessage = 'project not found') { diff --git a/services/gitlab/gitlab-stars.service.js b/services/gitlab/gitlab-stars.service.js index 695c0db3916fa..280f9fdbd95e0 100644 --- a/services/gitlab/gitlab-stars.service.js +++ b/services/gitlab/gitlab-stars.service.js @@ -2,6 +2,7 @@ import Joi from 'joi' import { optionalUrl, nonNegativeInteger } from '../validators.js' import { metric } from '../text-formatters.js' import GitLabBase from './gitlab-base.js' +import { documentation } from './gitlab-helper.js' const schema = Joi.object({ star_count: nonNegativeInteger, @@ -11,13 +12,6 @@ const queryParamSchema = Joi.object({ gitlab_url: optionalUrl, }).required() -const documentation = ` -- You may use your GitLab Project Id (e.g. 278964) or your Project Path (e.g. gitlab-org/gitlab ). - Note that only internet-accessible GitLab instances are supported, for example https://jihulab.com, https://gitlab.gnome.org, or https://gitlab.com/. -
-` - export default class GitlabStars extends GitLabBase { static category = 'social' diff --git a/services/hsts/hsts.service.js b/services/hsts/hsts.service.js index e0700cbdb8195..5ea7760520e01 100644 --- a/services/hsts/hsts.service.js +++ b/services/hsts/hsts.service.js @@ -6,17 +6,14 @@ const schema = Joi.object({ }).required() const documentation = ` -
-
- Strict-Transport-Security
is an HTTP response header that signals that browsers should
- only access the site using HTTPS.
-
- For a higher level of security, it's possible for a domain owner to - preload - this behavior into participating web browsers. Chromium maintains the HSTS preload list, which - is the de facto standard that has been adopted by several browsers. This service checks a domain's status in that list. -
+[\`Strict-Transport-Security\` is an HTTP response header](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Strict-Transport-Security) +that signals that browsers should only access the site using HTTPS. + +For a higher level of security, it's possible for a domain owner to +[preload this behavior into participating web browsers](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Strict-Transport-Security#Preloading_Strict_Transport_Security). +Chromium maintains the [HSTS preload list](https://www.chromium.org/hsts), which +is the de facto standard that has been adopted by several browsers. +This service checks a domain's status in that list. ` export default class HSTS extends BaseJsonService { diff --git a/services/jira/jira-sprint.service.js b/services/jira/jira-sprint.service.js index 2ab4d31a673ac..40a6bc85f69c9 100644 --- a/services/jira/jira-sprint.service.js +++ b/services/jira/jira-sprint.service.js @@ -23,11 +23,9 @@ const schema = Joi.object({ }).required() const documentation = ` -
- To get the Sprint ID
, go to your Backlog view in your project,
- right click on your sprint name and get the value of
- data-sprint-id
.
-
To find your user id, you can use this tool.
Alternatively you can make a request to https://your.mastodon.server/.well-known/webfinger?resource=acct:{user}@{domain}
Failing that, you can also visit your profile page, where your user ID will be in the header in a tag like this: <link href='https://your.mastodon.server/api/salmon/{your-user-id}' rel='salmon'>
- The Mozilla HTTP Observatory - is a set of tools to analyze your website - and inform you if you are utilizing the many available methods to secure it. -
-
- By default the scan result is hidden from the public result list.
- You can activate the publication of the scan result
- by setting the publish
parameter.
-
- The badge returns a cached site result if the site has been scanned anytime in the previous 24 hours. - If you need to force invalidating the cache, - you can to do it manually through the Mozilla Observatory Website -
+The [Mozilla HTTP Observatory](https://observatory.mozilla.org) +is a set of tools to analyze your website +and inform you if you are utilizing the many available methods to secure it. + +By default the scan result is hidden from the public result list. +You can activate the publication of the scan result +by setting the \`publish\` parameter. + +The badge returns a cached site result if the site has been scanned anytime in the previous 24 hours. +If you need to force invalidating the cache, +you can to do it manually through the [Mozilla Observatory Website](https://observatory.mozilla.org) ` export default class MozillaObservatory extends BaseJsonService { diff --git a/services/nycrc/nycrc.service.js b/services/nycrc/nycrc.service.js index 631f3c0378fb2..7afafc428fa17 100644 --- a/services/nycrc/nycrc.service.js +++ b/services/nycrc/nycrc.service.js @@ -23,11 +23,11 @@ const pkgJSONSchema = Joi.object({ }).optional(), }).required() -const documentation = `- Create a code coverage badge, based on thresholds stored in a - .nycrc config file - on GitHub. -
` +const documentation = ` +Create a code coverage badge, based on thresholds stored in a +[.nycrc config file](https://github.com/istanbuljs/nyc#common-configuration-options) +on GitHub. +` const validThresholds = ['branches', 'lines', 'functions'] diff --git a/services/osslifecycle/osslifecycle.service.js b/services/osslifecycle/osslifecycle.service.js index 114e0e09d75df..3766b7c8d42d3 100644 --- a/services/osslifecycle/osslifecycle.service.js +++ b/services/osslifecycle/osslifecycle.service.js @@ -1,14 +1,12 @@ import { BaseService, InvalidResponse } from '../index.js' const documentation = ` -
- OSS Lifecycle is an initiative started by Netflix to classify open-source projects into lifecycles
- and clearly identify which projects are active and which ones are retired. To enable this badge,
- simply create an OSSMETADATA tagging file at the root of your GitHub repository containing a
- single line similar to the following: osslifecycle=active
. Other suggested values are
- osslifecycle=maintenance
and osslifecycle=archived
. A working example
- can be viewed on the OSS Tracker repository.
-
- To see more details about this badge and obtain your api key, visit - https://my.pingpong.one/integrations/badge-status/ -
+To see more details about this badge and obtain your api key, visit +[https://my.pingpong.one/integrations/badge-status/](https://my.pingpong.one/integrations/badge-status/) ` export default class PingPongStatus extends BaseJsonService { diff --git a/services/pingpong/pingpong-uptime.service.js b/services/pingpong/pingpong-uptime.service.js index eb58d7e456b43..1cc4755b9a518 100644 --- a/services/pingpong/pingpong-uptime.service.js +++ b/services/pingpong/pingpong-uptime.service.js @@ -7,10 +7,8 @@ const schema = Joi.object({ }).required() const pingpongDocumentation = ` -- To see more details about this badge and obtain your api key, visit - https://my.pingpong.one/integrations/badge-uptime/ -
+To see more details about this badge and obtain your api key, visit +[https://my.pingpong.one/integrations/badge-status/](https://my.pingpong.one/integrations/badge-status/) ` export default class PingPongUptime extends BaseJsonService { diff --git a/services/poeditor/poeditor.service.js b/services/poeditor/poeditor.service.js index 806d9bfcfca28..0576becd5ff04 100644 --- a/services/poeditor/poeditor.service.js +++ b/services/poeditor/poeditor.service.js @@ -4,14 +4,13 @@ import { coveragePercentage } from '../color-formatters.js' import { BaseJsonService, InvalidResponse } from '../index.js' const documentation = ` -- You must specify the read-only API token from the POEditor account to which the project belongs. -
-
- As per the POEditor API documentation,
- all requests to the API must contain the parameter api_token. You can get a read-only key from your POEditor account.
- You'll find it in My Account > API Access.
-
This service currently support the following Frameworks:
- ${Object.values(frameworkNameMap).map(obj => `${obj.name}`)}
+ ${Object.values(frameworkNameMap).map(obj => ` ${obj.name}`)}
- The Security Headers - provide an easy mechanism to analyze HTTP response headers and - give information on how to deploy missing headers. -
-- The scan result will be hidden from the public result list and follow redirects will be on too. -
+The [Security Headers](https://securityheaders.com/) +provide an easy mechanism to analyze HTTP response headers and +give information on how to deploy missing headers. + +The scan result will be hidden from the public result list and follow redirects will be on too. ` export default class SecurityHeaders extends BaseService { diff --git a/services/tokei/tokei.service.js b/services/tokei/tokei.service.js index 2a6baeb8c5a29..de3a4c56ab576 100644 --- a/services/tokei/tokei.service.js +++ b/services/tokei/tokei.service.js @@ -8,20 +8,17 @@ const schema = Joi.object({ }).required() const documentation = ` -
- The provider
is the domain name of git host.
- If no TLD is provided, .com
will be added.
- For example, setting gitlab
or bitbucket.org
as the
- provider also works.
-
- Tokei will automatically count all files with a recognized extension. It will
- automatically ignore files and folders in .ignore
files. If you
- want to ignore files or folders specifically for tokei, add them to the
- .tokeignore
in the root of your repository.
- See
- https://github.com/XAMPPRocky/tokei#excluding-folders
- for more info.
-
- The badge is of the form
- https://img.shields.io/website/PROTOCOL/URLREST.svg
.
-
- The whole URL is obtained by concatenating the PROTOCOL
- (http
or https
, for example) with the
- URLREST
(separating them with ://
).
-
- The existence of a specific path on the server can be checked by appending
- a path after the domain name, e.g.
- https://img.shields.io/website/http/www.website.com/path/to/page.html.svg
.
-
- The messages and colors for the up and down states can also be customized. -
+The badge is of the form +\`https://img.shields.io/website/PROTOCOL/URLREST.svg\`. + +The whole URL is obtained by concatenating the \`PROTOCOL\` +(\`http\` or \`https\`, for example) with the +\`URLREST\` (separating them with \`://\`). + +The existence of a specific path on the server can be checked by appending +a path after the domain name, e.g. +\`https://img.shields.io/website/http/www.website.com/path/to/page.html.svg\`. + +The messages and colors for the up and down states can also be customized. ` const urlQueryParamSchema = Joi.object({ diff --git a/services/youtube/youtube-base.js b/services/youtube/youtube-base.js index e69aa5ad06610..e1c70d19b3d45 100644 --- a/services/youtube/youtube-base.js +++ b/services/youtube/youtube-base.js @@ -4,8 +4,8 @@ import { metric } from '../text-formatters.js' import { nonNegativeInteger } from '../validators.js' const documentation = ` -By using the YouTube badges provided by Shields.io, you are agreeing to be bound by the YouTube Terms of Service. These can be found here: -https://www.youtube.com/t/terms
` +By using the YouTube badges provided by Shields.io, you are agreeing to be bound by the YouTube Terms of Service. +These can be found here: [https://www.youtube.com/t/terms](https://www.youtube.com/t/terms)` const schema = Joi.object({ pageInfo: Joi.object({