Merge branch 'main' into workflow-should-run-on-label-events
This commit is contained in:
@@ -220,7 +220,7 @@ end
|
||||
|
||||
#### Define a route handler
|
||||
|
||||
An empty route is included in the template code. This code handles all `POST` requests to the `/event_handler` route. You'll won't write this event handler in this quickstart, but see the other [quickstart guides](/apps/quickstart-guides/) for examples of how to extend this template app.
|
||||
An empty route is included in the template code. This code handles all `POST` requests to the `/event_handler` route. You won't write this event handler in this quickstart, but see the other [quickstart guides](/apps/quickstart-guides/) for examples of how to extend this template app.
|
||||
|
||||
``` ruby
|
||||
post '/event_handler' do
|
||||
|
||||
@@ -428,9 +428,9 @@ For more information, see "[Restricting publication of {% data variables.product
|
||||
| Action | Description
|
||||
|------------------|-------------------
|
||||
| `close` | Triggered when someone closes a security advisory. For more information, see "[About {% data variables.product.prodname_dotcom %} Security Advisories](/github/managing-security-vulnerabilities/about-github-security-advisories)."
|
||||
| `cve_request` | Triggered when someone requests a CVE (Common Vulnerabilities and Exposures) number from {% data.variables.product.prodname_dotcom %} for a draft security advisory.
|
||||
| `github_broadcast` | Triggered when {% data.variables.product.prodname_dotcom %} makes a security advisory public in the {% data variables.product.prodname_advisory_database %}.
|
||||
| `github_withdraw` | Triggered when {% data.variables.product.prodname_dotcom %} withdraws a security advisory that was published in error.
|
||||
| `cve_request` | Triggered when someone requests a CVE (Common Vulnerabilities and Exposures) number from {% data variables.product.prodname_dotcom %} for a draft security advisory.
|
||||
| `github_broadcast` | Triggered when {% data variables.product.prodname_dotcom %} makes a security advisory public in the {% data variables.product.prodname_advisory_database %}.
|
||||
| `github_withdraw` | Triggered when {% data variables.product.prodname_dotcom %} withdraws a security advisory that was published in error.
|
||||
| `open` | Triggered when someone opens a draft security advisory.
|
||||
| `publish` | Triggered when someone publishes a security advisory.
|
||||
| `reopen` | Triggered when someone reopens as draft security advisory.
|
||||
|
||||
@@ -11,7 +11,7 @@ versions:
|
||||
{% data reusables.user_settings.access_settings %}
|
||||
{% data reusables.user_settings.developer_settings %}
|
||||
3. In the left sidebar, click **{% data variables.product.prodname_oauth_app %}s**.
|
||||

|
||||

|
||||
3. Click **Register a new application**.
|
||||
4. Under **Application name**, type "Jira".
|
||||
5. Under **Homepage URL**, type the full URL to your Jira instance.
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
---
|
||||
title: Enabling a link between GitHub Insights and GitHub Enterprise
|
||||
intro: 'You can enable a link that will allow users to navigate from {% data variables.product.prodname_ghe_server %} to {{ site.data.variables.product.prodname_insights }}.'
|
||||
intro: 'You can enable a link that will allow users to navigate from {% data variables.product.prodname_ghe_server %} to {% data variables.product.prodname_insights %}.'
|
||||
product: '{% data reusables.gated-features.github-insights %}'
|
||||
permissions: 'Site administrators for {% data variables.product.prodname_ghe_server %} can enable a link between {% data variables.product.prodname_ghe_server %} and {% data variables.product.prodname_insights %}.'
|
||||
redirect_from:
|
||||
|
||||
@@ -2,7 +2,6 @@ const path = require('path')
|
||||
const slash = require('slash')
|
||||
const fs = require('fs')
|
||||
const walk = require('walk-sync')
|
||||
const matter = require('@github-docs/frontmatter')
|
||||
const { zip } = require('lodash')
|
||||
const yaml = require('js-yaml')
|
||||
const languages = require('../../lib/languages')
|
||||
@@ -81,19 +80,19 @@ const versionLinkRegEx = /(?=^|[^\]]\s*)\[[^\]]+\](?::\n?[ \t]+|\s*\()(?:(?:http
|
||||
const domainLinkRegex = /(?=^|[^\]]\s*)\[[^\]]+\](?::\n?[ \t]+|\s*\()(?:https?:)?\/\/(?:help|docs|developer)\.github\.com(?!\/changes\/)[^)\s]*(?:\)|\s+|$)/gm
|
||||
|
||||
// {{ site.data.example.pizza }}
|
||||
const oldVariableRegex = /{{\s?site\.data\..*}}/g
|
||||
const oldVariableRegex = /{{\s*?site\.data\..*?}}/g
|
||||
|
||||
// - {{ octicon-plus }}
|
||||
// - {{ octicon-plus An example label }}
|
||||
//
|
||||
const oldOcticonRegex = /{{\s?octicon-([a-z-]+)(\s[\w\s\d-]+)?\s?}}/g
|
||||
const oldOcticonRegex = /{{\s*?octicon-([a-z-]+)(\s[\w\s\d-]+)?\s*?}}/g
|
||||
|
||||
// - {{#note}}
|
||||
// - {{/note}}
|
||||
// - {{ #warning }}
|
||||
// - {{ /pizza }}
|
||||
//
|
||||
const oldExtendedMarkdownRegex = /{{\s?[#/][a-z-]+\s?}}/g
|
||||
const oldExtendedMarkdownRegex = /{{\s*?[#/][a-z-]+\s*?}}/g
|
||||
|
||||
const relativeArticleLinkErrorText = 'Found unexpected relative article links:'
|
||||
const languageLinkErrorText = 'Found article links with hard-coded language codes:'
|
||||
@@ -125,10 +124,7 @@ describe('lint-files', () => {
|
||||
let content
|
||||
|
||||
beforeAll(async () => {
|
||||
const fileContents = await fs.promises.readFile(markdownAbsPath, 'utf8')
|
||||
const { content: bodyContent } = matter(fileContents)
|
||||
|
||||
content = bodyContent
|
||||
content = await fs.promises.readFile(markdownAbsPath, 'utf8')
|
||||
})
|
||||
|
||||
test('relative URLs must start with "/"', async () => {
|
||||
@@ -214,7 +210,7 @@ describe('lint-files', () => {
|
||||
const matches = (content.match(oldVariableRegex) || [])
|
||||
const matchesWithExample = matches.map(match => {
|
||||
const example = match
|
||||
.replace(/{{\s?site\.data\.([a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]+)+)\s*}}/g, '{% data $1 %}')
|
||||
.replace(/{{\s*?site\.data\.([a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]+)+)\s*?}}/g, '{% data $1 %}')
|
||||
return `${match} => ${example}`
|
||||
})
|
||||
const errorMessage = formatLinkError(oldVariableErrorText, matchesWithExample)
|
||||
@@ -229,7 +225,7 @@ describe('lint-files', () => {
|
||||
|
||||
test('does not use old extended markdown syntax', async () => {
|
||||
Object.keys(tags).forEach(tag => {
|
||||
const reg = new RegExp(`{{\\s?[#|/]${tag}`, 'g')
|
||||
const reg = new RegExp(`{{\\s*?[#|/]${tag}`, 'g')
|
||||
if (reg.test(content)) {
|
||||
const matches = (content.match(oldExtendedMarkdownRegex)) || []
|
||||
const tagMessage = oldExtendedMarkdownErrorText
|
||||
@@ -334,7 +330,7 @@ describe('lint-files', () => {
|
||||
if (valMatches.length > 0) {
|
||||
matches.push(...valMatches.map((match) => {
|
||||
const example = match
|
||||
.replace(/{{\s?site\.data\.([a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]+)+)\s*}}/g, '{% data $1 %}')
|
||||
.replace(/{{\s*?site\.data\.([a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]+)+)\s*?}}/g, '{% data $1 %}')
|
||||
return `Key "${key}": ${match} => ${example}`
|
||||
}))
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user