Skip to content

Commit cd9e595

Browse files
authored
Merge pull request #23047 from github/repo-sync
repo sync
2 parents cf7a9aa + 6dbe33b commit cd9e595

File tree

7 files changed

+11
-39
lines changed

7 files changed

+11
-39
lines changed

content/actions/hosting-your-own-runners/removing-self-hosted-runners.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
title: Removing self-hosted runners
3-
intro: 'You can permanently remove a self-hosted runner from a repository{% ifversion fpt %} or organization{% elsif ghec or ghes or gahe %}, an organization, or an enterprise{% endif %}.'
3+
intro: 'You can permanently remove a self-hosted runner from a repository{% ifversion fpt %} or organization{% elsif ghec or ghes or ghae %}, an organization, or an enterprise{% endif %}.'
44
redirect_from:
55
- /github/automating-your-workflow-with-github-actions/removing-self-hosted-runners
66
- /actions/automating-your-workflow-with-github-actions/removing-self-hosted-runners

content/admin/guides.md

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,8 @@ learningTracks:
1717
- adopting_github_actions_for_your_enterprise_ghes_and_ghae
1818
- '{% ifversion ghes %}increase_fault_tolerance{% endif %}'
1919
- '{% ifversion ghes %}improve_security_of_your_instance{% endif %}'
20-
- '{% ifversion ghes > 2.22 %}configure_github_actions{% endif %}'
21-
- '{% ifversion ghes > 2.22 %}configure_github_advanced_security{% endif %}'
20+
- '{% ifversion ghes %}configure_github_actions{% endif %}'
21+
- '{% ifversion ghes %}configure_github_advanced_security{% endif %}'
2222
includeGuides:
2323
- /admin/authentication/allowing-built-in-authentication-for-users-outside-your-identity-provider
2424
- /admin/authentication/changing-authentication-methods
@@ -148,4 +148,3 @@ includeGuides:
148148
- /admin/overview/creating-an-enterprise-account
149149
- /admin/user-management/managing-organizations-in-your-enterprise/restoring-a-deleted-organization
150150
---
151-

content/admin/index.md

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -80,9 +80,9 @@ featuredLinks:
8080
- '{% ifversion ghec %}/admin/user-management/managing-users-in-your-enterprise/roles-in-an-enterprise{% endif %}'
8181
- '{% ifversion ghec %}/admin/user-management/managing-organizations-in-your-enterprise/adding-organizations-to-your-enterprise{% endif %}'
8282
guideCards:
83-
- '{% ifversion ghes > 2.22 %} /admin/github-actions/getting-started-with-github-actions-for-github-enterprise-server {% elsif ghes < 3.0 %} /admin/enterprise-management/upgrading-github-enterprise-server {% endif %}'
84-
- '{% ifversion ghes > 2.22 %} /admin/packages/getting-started-with-github-packages-for-your-enterprise {% elsif ghes < 3.0 %} /admin/user-management/customizing-user-messages-for-your-enterprise {% endif %}'
85-
- '{% ifversion ghes > 2.22 %} /admin/configuration/configuring-advanced-security-features {% elsif ghes < 3.0 %} /admin/installation/setting-up-a-staging-instance {% endif %}'
83+
- '{% ifversion ghes %}/admin/github-actions/getting-started-with-github-actions-for-github-enterprise-server{% endif %}'
84+
- '{% ifversion ghes %}/admin/packages/getting-started-with-github-packages-for-your-enterprise{% endif %}'
85+
- '{% ifversion ghes %}/admin/configuration/configuring-advanced-security-features{% endif %}'
8686
- '{% ifversion ghae %}/admin/configuration/initializing-github-ae{% endif %}'
8787
- '{% ifversion ghae %}/admin/user-management/customizing-user-messages-for-your-enterprise{% endif %}'
8888
- '{% ifversion ghae %}/admin/github-actions/getting-started-with-github-actions-for-github-ae{% endif %}'
@@ -126,4 +126,3 @@ children:
126126
- /release-notes
127127
- /all-releases
128128
---
129-

middleware/index.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -267,10 +267,10 @@ export default function (app) {
267267
app.use(asyncMiddleware(instrument(ghaeReleaseNotes, './contextualizers/ghae-release-notes')))
268268
app.use(asyncMiddleware(instrument(whatsNewChangelog, './contextualizers/whats-new-changelog')))
269269
app.use(instrument(layout, './contextualizers/layout'))
270+
app.use(instrument(features, './contextualizers/features')) // needs to come before product tree
270271
app.use(asyncMiddleware(instrument(currentProductTree, './contextualizers/current-product-tree')))
271272
app.use(asyncMiddleware(instrument(genericToc, './contextualizers/generic-toc')))
272273
app.use(instrument(breadcrumbs, './contextualizers/breadcrumbs'))
273-
app.use(instrument(features, './contextualizers/features'))
274274
app.use(asyncMiddleware(instrument(productExamples, './contextualizers/product-examples')))
275275
app.use(asyncMiddleware(instrument(productGroups, './contextualizers/product-groups')))
276276
app.use(instrument(glossaries, './contextualizers/glossaries'))

script/helpers/get-liquid-conditionals.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ const tokenize = (str) => {
1111
// Return an array of just the conditional strings.
1212
function getLiquidConditionals(str, tagNames) {
1313
if (!tagNames) throw new Error(`Must provide a tag name!`)
14+
if (typeof str !== 'string') throw new Error('Must provide a string!')
1415
tagNames = Array.isArray(tagNames) ? tagNames : [tagNames]
1516

1617
return tokenize(str)

tests/content/featured-links.js

Lines changed: 1 addition & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -1,30 +1,11 @@
1-
import fs from 'fs/promises'
2-
import path from 'path'
3-
import { fileURLToPath } from 'url'
4-
5-
import { beforeAll, jest } from '@jest/globals'
6-
import nock from 'nock'
1+
import { jest } from '@jest/globals'
72

83
import { getDOM, getJSON } from '../helpers/e2etest.js'
94
import enterpriseServerReleases from '../../lib/enterprise-server-releases.js'
105

11-
const __dirname = path.dirname(fileURLToPath(import.meta.url))
12-
136
describe('featuredLinks', () => {
147
jest.setTimeout(3 * 60 * 1000)
158

16-
beforeAll(async () => {
17-
const packagesFeedFixturePayload = await fs.readFile(
18-
path.join(__dirname, '../fixtures/github-blog-feed-packages-2021.xml'),
19-
'utf-8'
20-
)
21-
nock('https://github.blog')
22-
.get('/changelog/label/packages/feed')
23-
.reply(200, packagesFeedFixturePayload)
24-
})
25-
26-
afterAll(() => nock.cleanAll())
27-
289
describe('rendering', () => {
2910
test('non-TOC pages do not have intro links', async () => {
3011
const $ = await getDOM('/en/get-started/quickstart/set-up-git')

tests/linting/lint-versioning.js

Lines changed: 2 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@ import { getLiquidConditionals } from '../../script/helpers/get-liquid-condition
88
import allowedVersionOperators from '../../lib/liquid-tags/ifversion-supported-operators.js'
99
import featureVersionsSchema from '../helpers/schemas/feature-versions-schema.js'
1010
import walkFiles from '../../script/helpers/walk-files'
11-
import frontmatter from '../../lib/frontmatter.js'
1211
import cleanUpDeprecatedGhaeFlagErrors from '../../lib/temporary-ghae-deprecated-flag-error-cleanup.js'
1312
import { getDeepDataByLanguage } from '../../lib/get-data.js'
1413

@@ -66,15 +65,8 @@ describe('lint Liquid versioning', () => {
6665

6766
beforeAll(async () => {
6867
fileContents = await fs.readFile(file, 'utf8')
69-
const { data, content: bodyContent } = frontmatter(fileContents)
70-
71-
ifversionConditionals = getLiquidConditionals(data, ['ifversion', 'elsif']).concat(
72-
getLiquidConditionals(bodyContent, ['ifversion', 'elsif'])
73-
)
74-
75-
ifConditionals = getLiquidConditionals(data, 'if').concat(
76-
getLiquidConditionals(bodyContent, 'if')
77-
)
68+
ifversionConditionals = getLiquidConditionals(fileContents, ['ifversion', 'elsif'])
69+
ifConditionals = getLiquidConditionals(fileContents, 'if')
7870
})
7971

8072
// `ifversion` supports both standard and feature-based versioning.

0 commit comments

Comments
 (0)