diff --git a/.github/workflows/orphaned-files-check.yml b/.github/workflows/orphaned-files-check.yml index 117e57445367..0aa347f33ec7 100644 --- a/.github/workflows/orphaned-files-check.yml +++ b/.github/workflows/orphaned-files-check.yml @@ -24,7 +24,7 @@ permissions: contents: read jobs: - orphaned-assets-check: + orphaned-files-check: if: ${{ github.repository == 'github/docs-internal' }} runs-on: ubuntu-latest steps: diff --git a/content/README.md b/content/README.md index 1e4e6fe8ba4b..19e57200b888 100644 --- a/content/README.md +++ b/content/README.md @@ -50,13 +50,13 @@ It is a block of key-value content that lives at the top of every Markdown file. The following frontmatter values have special meanings and requirements for this site. There's also a schema that's used by the test suite to validate every page's frontmatter. -See [`lib/frontmatter.js`](../lib/frontmatter.js). +See [`lib/frontmatter.js`](/src/frame/lib/frontmatter.js). ### `versions` -- Purpose: Indicates the [versions](#src/versions/lib/all-versions.js) to which a page applies. +- Purpose: Indicates the [versions](/src/versions/lib/all-versions.js) to which a page applies. See [Versioning](#versioning) for more info. -- Type: `Object`. Allowable keys map to product names and can be found in the `versions` object in [`lib/frontmatter.js`](../lib/frontmatter.js). +- Type: `Object`. Allowable keys map to product names and can be found in the `versions` object in [`lib/frontmatter.js`](/src/frame/lib/frontmatter.js). - This frontmatter value is currently **required** for all pages. - The `*` is used to denote all releases for the version. @@ -258,7 +258,7 @@ includeGuides: - Optional. ### `topics` -- Purpose: Indicate the topics covered by the article. Refer to the content models for more details about adding topics. A full list of existing topics is located in the [allowed topics file](/data/allowed-topics.js). If topics in article frontmatter and the allow-topics list become out of sync, the [topics CI test](/tests/unit/search/topics.js) will fail. +- Purpose: Indicate the topics covered by the article. Refer to the content models for more details about adding topics. A full list of existing topics is located in the [allowed topics file](/data/allowed-topics.js). If topics in article frontmatter and the allow-topics list become out of sync, the [topics CI test](/src/search/tests/topics.js) will fail. - Type: Array of `String`s - Optional: Topics are preferred for each article, but, there may be cases where existing articles don't yet have topics, or adding a topic to a new article may not add value. @@ -297,7 +297,7 @@ A content file can have **two** types of versioning: - Liquid statements in content (**optional**) - Conditionally render content depending on the current version being viewed. See "[Versioning documentation](https://docs.github.com/en/contributing/writing-for-github-docs/versioning-documentation#versioning-with-liquid-conditional-operators)" for more info. Note Liquid conditionals can also appear in `data` and `include` files. -**Note**: As of early 2021, the `free-pro-team@latest` version is not included URLs. A helper function called `lib/remove-fpt-from-path.js` removes the version from URLs. +**Note**: As of early 2021, the `free-pro-team@latest` version is not included URLs. A helper function called `src/versions/lib/remove-fpt-from-path.js` removes the version from URLs. ## Filenames @@ -345,7 +345,7 @@ Links to docs in the `docs-internal` repository must start with a product ID (li Image paths must start with `/assets` and contain the entire filepath including the file extension. For example, `/assets/images/help/settings/settings-account-delete.png`. -The links to Markdown pages undergo some transformations on the server side to match the current page's language and version. The handling for these transformations lives in [`lib/render-content/plugins/rewrite-local-links`](/lib/render-content/plugins/rewrite-local-links.js). +The links to Markdown pages undergo some transformations on the server side to match the current page's language and version. The handling for these transformations lives in [`src/content-render/unified/rewrite-local-links.js`](/src/content-render/unified/rewrite-local-links.js). For example, if you include the following link in a content file: diff --git a/content/actions/writing-workflows/choosing-what-your-workflow-does/accessing-contextual-information-about-workflow-runs.md b/content/actions/writing-workflows/choosing-what-your-workflow-does/accessing-contextual-information-about-workflow-runs.md index a9855f035f2d..57e2ee1d9ff5 100644 --- a/content/actions/writing-workflows/choosing-what-your-workflow-does/accessing-contextual-information-about-workflow-runs.md +++ b/content/actions/writing-workflows/choosing-what-your-workflow-does/accessing-contextual-information-about-workflow-runs.md @@ -88,7 +88,7 @@ Different contexts are available throughout a workflow run. For example, the `se In addition, some functions may only be used in certain places. For example, the `hashFiles` function is not available everywhere. -The following table indicates where each context and special function can be used within a workflow. Unless listed below, a function can be used anywhere. +The following table lists the restrictions on where each context and special function can be used within a workflow. The listed contexts are only available for the given workflow key, and may not be used anywhere else. Unless listed below, a function can be used anywhere. | Workflow key | Context | Special functions | | ---- | ------- | ----------------- | diff --git a/content/codespaces/developing-in-a-codespace/getting-started-with-github-codespaces-for-machine-learning.md b/content/codespaces/developing-in-a-codespace/getting-started-with-github-codespaces-for-machine-learning.md index 4973894367b7..bb31d23f79ea 100644 --- a/content/codespaces/developing-in-a-codespace/getting-started-with-github-codespaces-for-machine-learning.md +++ b/content/codespaces/developing-in-a-codespace/getting-started-with-github-codespaces-for-machine-learning.md @@ -34,7 +34,7 @@ A codespace for this template will open in a web-based version of {% data variab ### Opening the image classifier notebook -The default container image that's used by {% data variables.product.prodname_github_codespaces %} includes a set of machine learning libraries that are preinstalled in your codespace. For example, Numpy, pandas, SciPy, Matplotlib, seaborn, scikit-learn, Keras, PyTorch, Requests, and Plotly. For more information about the default image, see "[AUTOTITLE](/codespaces/setting-up-your-project-for-codespaces/adding-a-dev-container-configuration/introduction-to-dev-containers#using-the-default-dev-container-configuration)" and the [devcontainers/images](https://github.com/devcontainers/images/tree/main/src/universal) repository]. +The default container image that's used by {% data variables.product.prodname_github_codespaces %} includes a set of machine learning libraries that are preinstalled in your codespace. For example, Numpy, pandas, SciPy, Matplotlib, seaborn, scikit-learn, Keras, PyTorch, Requests, and Plotly. For more information about the default image, see "[AUTOTITLE](/codespaces/setting-up-your-project-for-codespaces/adding-a-dev-container-configuration/introduction-to-dev-containers#using-the-default-dev-container-configuration)" and the [devcontainers/images](https://github.com/devcontainers/images/tree/main/src/universal) repository. 1. In the {% data variables.product.prodname_vscode_shortname %} editor, close any "Get Started" tabs that are displayed. 1. Open the `notebooks/image-classifier.ipynb` notebook file. diff --git a/content/copilot/building-copilot-extensions/copilot-extensions-glossary.md b/content/copilot/building-copilot-extensions/copilot-extensions-glossary.md index 9054c991ee63..684f61648734 100644 --- a/content/copilot/building-copilot-extensions/copilot-extensions-glossary.md +++ b/content/copilot/building-copilot-extensions/copilot-extensions-glossary.md @@ -37,7 +37,7 @@ Also known as {% data variables.product.prodname_vscode %} Chat extensions, {% d The foundation for a {% data variables.product.prodname_copilot_extension_short %} that provides the necessary infrastructure, permissions, and context from {% data variables.product.company_short %}, such as user, repo and organization metadata. -##### {% data variables.product.prodname_marketplace %} +#### {% data variables.product.prodname_marketplace %} The platform where {% data variables.product.company_short %} approved {% data variables.product.prodname_copilot_extensions %} can be listed publicly and discovered by users. @@ -49,7 +49,7 @@ An extension that appears on the {% data variables.product.prodname_marketplace An extension that is only visible and usable by the organization or individual user that created it. -##### Public Extension +#### Public Extension An extension that is visible and installable by any {% data variables.product.company_short %} user or organization. diff --git a/data/reusables/actions/reusable-workflow-calling-syntax.md b/data/reusables/actions/reusable-workflow-calling-syntax.md index 3b3312822818..ddda9da4e2f7 100644 --- a/data/reusables/actions/reusable-workflow-calling-syntax.md +++ b/data/reusables/actions/reusable-workflow-calling-syntax.md @@ -3,4 +3,4 @@ In the first option, `{ref}` can be a SHA, a release tag, or a branch name. If a release tag and a branch have the same name, the release tag takes precedence over the branch name. Using the commit SHA is the safest option for stability and security. For more information, see "[AUTOTITLE](/actions/security-guides/security-hardening-for-github-actions#reusing-third-party-workflows)." -If you use the second syntax option (without `{owner}/{repo}` and `@{ref}`) the called workflow is from the same commit as the caller workflow. Ref prefixes such as `refs/heads` and `refs/tags` are not allowed. +If you use the second syntax option (without `{owner}/{repo}` and `@{ref}`) the called workflow is from the same commit as the caller workflow. Ref prefixes such as `refs/heads` and `refs/tags` are not allowed. You cannot use contexts or expressions in this keyword. diff --git a/src/content-render/scripts/reusables-cli/find/unused.ts b/src/content-render/scripts/reusables-cli/find/unused.ts index 7d2dc342f500..70e6d54574e2 100644 --- a/src/content-render/scripts/reusables-cli/find/unused.ts +++ b/src/content-render/scripts/reusables-cli/find/unused.ts @@ -24,10 +24,17 @@ export function findUnused({ absolute }: { absolute: boolean }) { const liquidTokens = getLiquidTokens(fileContents) for (const token of liquidTokens) { const { args, name } = token - if (name === 'data' && args.startsWith('reusables.')) { - const reusableName = path.join('data', ...args.split('.')) + '.md' + if ( + (name === 'data' || name === 'indented_data_reference') && + args.startsWith('reusables.') + ) { + const reusableName = path.join('data', ...args.split(' ')[0].split('.')) + '.md' // Special cases where we don't want them to count as reusables. It's an example in a how-to doc - if (reusableName.includes('foo/bar.md') || reusableName.includes('your-reusable-name.md')) { + if ( + reusableName.includes('foo/bar.md') || + reusableName.includes('foo/par.md') || + reusableName.includes('your-reusable-name.md') + ) { continue } const reusablePath = resolveReusablePath(reusableName) diff --git a/src/content-render/scripts/reusables-cli/shared.ts b/src/content-render/scripts/reusables-cli/shared.ts index e42dc25de6fc..0c12288d4388 100644 --- a/src/content-render/scripts/reusables-cli/shared.ts +++ b/src/content-render/scripts/reusables-cli/shared.ts @@ -105,6 +105,7 @@ export function getAllReusablesFilePaths(): string[] { walk(reusablesDirectory, { includeBasePath: true, directories: false, + ignore: ['**/README.md', 'enterprise_deprecation/**'], }), ) }