From 26b8623cd6583fa75223e0d4e0900c1e166f5531 Mon Sep 17 00:00:00 2001 From: Sarita Iyer <66540150+saritai@users.noreply.github.com> Date: Fri, 11 Jul 2025 14:25:38 -0400 Subject: [PATCH 1/3] MCP GA and org/enterprise policy (#56460) Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> Co-authored-by: Sophie <29382425+sophietheking@users.noreply.github.com> Co-authored-by: sunbrye Co-authored-by: Sunbrye Ly <56200261+sunbrye@users.noreply.github.com> Co-authored-by: Dimitrios Philliou --- ...features-for-copilot-in-your-enterprise.md | 17 ++++++++++++---- ...licies-for-copilot-in-your-organization.md | 20 ++++++++++++++++++- .../extending-copilot-chat-with-mcp.md | 20 ++++++++++--------- .../enhancing-copilot-agent-mode-with-mcp.md | 6 +++--- 4 files changed, 46 insertions(+), 17 deletions(-) diff --git a/content/copilot/how-tos/administer/enterprises/managing-policies-and-features-for-copilot-in-your-enterprise.md b/content/copilot/how-tos/administer/enterprises/managing-policies-and-features-for-copilot-in-your-enterprise.md index 9bd8202e77ba..e87204c5ceb9 100644 --- a/content/copilot/how-tos/administer/enterprises/managing-policies-and-features-for-copilot-in-your-enterprise.md +++ b/content/copilot/how-tos/administer/enterprises/managing-policies-and-features-for-copilot-in-your-enterprise.md @@ -40,7 +40,7 @@ You can configure policies for your enterprise. If no policy is chosen at the en | [{% data variables.product.prodname_copilot_short %} access to alternative AI models](#copilot-access-to-alternative-ai-models) | least restrictive | | [{% data variables.product.prodname_copilot_short %} Metrics API access](#copilot-metrics-api-access) | most restrictive | | [{% data variables.copilot.copilot_coding_agent %}](#copilot-coding-agent) | least restrictive | -| [MCP servers on {% data variables.product.prodname_dotcom_the_website %}](#mcp-servers-on-githubcom) | least restrictive | +| [MCP servers in {% data variables.product.prodname_copilot_short %}](#mcp-servers-in-copilot) | least restrictive | ### {% data variables.product.prodname_copilot_short %} in {% data variables.product.prodname_dotcom_the_website %} @@ -112,11 +112,20 @@ Alternatively, set to "No policy" to leave organization owners to make the decis > [!TIP] Enabling your license holders to use {% data variables.copilot.copilot_coding_agent %} is the first step in making {% data variables.copilot.copilot_coding_agent %} available for use in repositories in your organizations. For more information, see [AUTOTITLE](/copilot/managing-copilot/managing-github-copilot-in-your-organization/adding-copilot-coding-agent-to-organization). -### MCP servers on {% data variables.product.prodname_dotcom_the_website %} +### MCP servers in {% data variables.product.prodname_copilot_short %} -> [!NOTE] Use of MCP servers on {% data variables.product.prodname_dotcom_the_website %} is in public preview and subject to change. +{% data reusables.copilot.coding-agent.mcp-brief-intro %} -{% data reusables.copilot.coding-agent.mcp-brief-intro %} See [AUTOTITLE](/copilot/using-github-copilot/coding-agent/extending-copilot-coding-agent-with-mcp). +You can enable this policy to allow users to connect MCP servers to {% data variables.product.prodname_copilot %} in {% data variables.product.prodname_vscode %} and {% data variables.copilot.copilot_coding_agent_short %}. + +* By default, this policy is disabled. When disabled, users with a {% data variables.product.prodname_copilot_short %} seat assigned by the enterprise or any child organizations will not be able to access MCP servers (remote or local) in {% data variables.product.prodname_copilot_short %}. +* If the policy is set to **Disabled** or **Enabled** at the enterprise level, all child organizations will inherit the same policy configuration. +* This policy only applies to users with a {% data variables.copilot.copilot_enterprise_short %} or {% data variables.copilot.copilot_business_short %} seat assigned by the same enterprise (or any of its child organizations) configuring the policy. It does not govern MCP access for any users with a {% data variables.product.prodname_copilot_short %} Free, Pro or Pro+ license. + +> [!NOTE] +> This policy does not apply to {% data variables.product.prodname_copilot_short %} editors where MCP support is still in preview. Instead, you can use the **Editor preview features** policy to disable MCP access in these editors. + +For more information on using MCP, see [AUTOTITLE](/copilot/how-tos/context/model-context-protocol/extending-copilot-chat-with-mcp) and [AUTOTITLE](/copilot/using-github-copilot/coding-agent/extending-copilot-coding-agent-with-mcp). ## Configuring policies for {% data variables.product.prodname_copilot %} diff --git a/content/copilot/how-tos/administer/organizations/managing-policies-for-copilot-in-your-organization.md b/content/copilot/how-tos/administer/organizations/managing-policies-for-copilot-in-your-organization.md index 7859ae8bb4fb..7c599f2fc526 100644 --- a/content/copilot/how-tos/administer/organizations/managing-policies-for-copilot-in-your-organization.md +++ b/content/copilot/how-tos/administer/organizations/managing-policies-for-copilot-in-your-organization.md @@ -33,8 +33,9 @@ Organization owners can set policies to govern how {% data variables.product.pro * Image support in {% data variables.copilot.copilot_chat_short %} (available in {% data variables.product.prodname_vscode_shortname %} and {% data variables.product.prodname_vs %}) >[!NOTE] This setting only applies to preview features within {% data variables.product.prodname_copilot_short %} and does not control all preview-related settings in {% data variables.product.prodname_vscode_shortname %}. * {% data variables.copilot.copilot_coding_agent %} ({% data variables.release-phases.public_preview %}) +* {% data variables.copilot.copilot_spaces %} (public preview) +* MCP servers in {% data variables.product.prodname_copilot_short %} * {% data variables.copilot.copilot_spaces %} ({% data variables.release-phases.public_preview %}) -* MCP servers on {% data variables.product.prodname_dotcom_the_website %} ({% data variables.release-phases.public_preview %}) * {% data variables.copilot.copilot_mobile_short %} * {% data variables.copilot.copilot_cli_short %} and {% data variables.product.prodname_windows_terminal %} * {% data variables.copilot.copilot_desktop_short %} @@ -72,6 +73,23 @@ If an organization member is assigned a seat by multiple organizations with diff > [!TIP] > If you choose to enable {% data variables.copilot.copilot_coding_agent %} for users, you also need to define which repositories the agent is available in, see [AUTOTITLE](/copilot/managing-copilot/managing-github-copilot-in-your-organization/adding-copilot-coding-agent-to-organization). +## Setting a policy for MCP servers connecting to {% data variables.product.prodname_copilot_short %} in your organization + +{% data reusables.copilot.coding-agent.mcp-brief-intro %} + +You can enable this policy to allow users to connect MCP (Model Context Protocol) servers to {% data variables.product.prodname_copilot %} in {% data variables.product.prodname_vscode %} and {% data variables.copilot.copilot_coding_agent_short %}. + +* By default, this policy is disabled. When disabled, members with a {% data variables.product.prodname_copilot_short %} seat assigned by the organization will not be able to access MCP servers (remote or local) in {% data variables.product.prodname_copilot_short %}. +* If there is a parent enterprise with the policy set to **Enabled** or **Disabled**, the organizations will inherit (and cannot change) the configuration set by the parent enterprise. +* If **No policy** is selected at the enterprise level and multiple organizations within the enterprise assign seats to the same users, each with different policies, the least restrictive policy is applied. +* This policy only applies to members with a {% data variables.copilot.copilot_enterprise_short %} or {% data variables.copilot.copilot_business_short %} license assigned by the same organization configuring or inheriting the policy. It does not govern MCP access for any members with a {% data variables.product.prodname_copilot_short %} Free, Pro or Pro+ plan. +* For centralized governance across all organizations you can configure the policy at the enterprise level. + +> [!NOTE] +> This policy does not apply to {% data variables.product.prodname_copilot_short %} editors where MCP support is still in preview. Instead, you can use the **Editor preview features** policy to disable MCP access in these editors. + +For more information on using MCP, see [AUTOTITLE](/copilot/how-tos/context/model-context-protocol/extending-copilot-chat-with-mcp) and [AUTOTITLE](/copilot/using-github-copilot/coding-agent/extending-copilot-coding-agent-with-mcp). + ## Setting a policy for {% data variables.copilot.copilot_extensions %} in your organization {% data variables.copilot.copilot_extensions %} integrate external tools with {% data variables.copilot.copilot_chat %}. See [AUTOTITLE](/copilot/using-github-copilot/using-extensions-to-integrate-external-tools-with-copilot-chat). diff --git a/content/copilot/how-tos/context/model-context-protocol/extending-copilot-chat-with-mcp.md b/content/copilot/how-tos/context/model-context-protocol/extending-copilot-chat-with-mcp.md index 4e9f19490c51..95cb7888365c 100644 --- a/content/copilot/how-tos/context/model-context-protocol/extending-copilot-chat-with-mcp.md +++ b/content/copilot/how-tos/context/model-context-protocol/extending-copilot-chat-with-mcp.md @@ -14,8 +14,8 @@ redirect_from: --- >[!NOTE] -> * MCP support is currently in {% data variables.release-phases.public_preview %} and subject to change. -> * MCP support is available in {% data variables.copilot.copilot_chat_short %} for {% data variables.product.prodname_vscode %}, JetBrains, Eclipse, and Xcode. +> * MCP support is generally available (GA) in {% data variables.copilot.copilot_chat_short %} for {% data variables.product.prodname_vscode %}. +> * MCP support for Copilot in {% data variables.product.prodname_vs %}, JetBrains, Eclipse, and Xcode is in {% data variables.release-phases.public_preview %} and is subject to change. > * The [AUTOTITLE](/free-pro-team@latest/site-policy/github-terms/github-pre-release-license-terms) apply to your use of this product. {% vscode %} @@ -26,6 +26,8 @@ The Model Context Protocol (MCP) is an open standard that defines how applicatio You can use MCP to extend the capabilities of {% data variables.copilot.copilot_chat_short %} by integrating it with a wide range of existing tools and services. For example, the {% data variables.product.github %} MCP server allows you to use {% data variables.copilot.copilot_chat_short %} in {% data variables.product.prodname_vscode %} to perform tasks on {% data variables.product.github %}. You can also use MCP to create new tools and services that work with {% data variables.copilot.copilot_chat_short %}, allowing you to customize and enhance your experience. +Enterprises and organizations can choose to enable or disable use of MCP for members of their organization or enterprise. See [AUTOTITLE](/copilot/how-tos/administer/enterprises/managing-policies-and-features-for-copilot-in-your-enterprise#mcp-servers-on-githubcom). The MCP policy only applies to members with {% data variables.copilot.copilot_business_short %}, {% data variables.copilot.copilot_enterprise_short %}, or {% data variables.product.prodname_copilot_short %} licenses assigned by the organization or enterprise that configures the policy. {% data variables.copilot.copilot_free_short %}, {% data variables.copilot.copilot_pro_short %}, or {% data variables.copilot.copilot_pro_plus_short %} do not have their MCP access governed by this policy. + For more information on MCP, see [the official MCP documentation](https://modelcontextprotocol.io/introduction). For information on some of the other currently available MCP servers, see [the MCP servers repository](https://github.com/modelcontextprotocol/servers/tree/main). @@ -82,7 +84,7 @@ For information on configuring the {% data variables.product.github %} MCP serve 1. To view your list of available MCP servers, click the tools icon in the top left corner of the chat box. This will open the MCP server list, where you can see all the MCP servers and associated tools that are currently available in your {% data variables.product.prodname_vscode %} instance. * Optionally, you can define toolsets, groups of related tools that you can reference in chat. Toolsets make it easier to group related MCP tools together and quickly enable or disable them. For information on how to define and use a toolset, see the [{% data variables.product.prodname_vscode_shortname %} docs](https://code.visualstudio.com/docs/copilot/chat/chat-agent-mode#_define-tool-sets). -For more information on configuring MCP servers in {% data variables.product.prodname_vscode %}, see [Use MCP servers in {% data variables.product.prodname_vscode %} (Preview)](https://aka.ms/vscode-add-mcp) in the {% data variables.product.prodname_vscode %} documentation. +For more information on configuring MCP servers in {% data variables.product.prodname_vscode %}, see [Use MCP servers in {% data variables.product.prodname_vscode %}](https://aka.ms/vscode-add-mcp) in the {% data variables.product.prodname_vscode %} documentation. ## Using MCP servers in {% data variables.copilot.copilot_chat_short %} @@ -107,7 +109,7 @@ Optionally, you can use MCP prompts and resources in {% data variables.product.p * MCP servers can define preconfigured prompts for interacting with their tools. You can access these prompts in chat with slash commands, using the format `/mcp.servername.promptname`. * MCP servers provide resources, which are any kind of data that the server wants to make available. For example, the {% data variables.product.github %} MCP server provides repository content as a resource. To add resources from an MCP server to your chat context, click **Add Context...** in the chat box, then click **MCP Resources**. -For more information on using MCP servers in {% data variables.product.prodname_vscode %}, see [Use MCP servers in {% data variables.product.prodname_vscode %} (Preview)](https://aka.ms/vscode-add-mcp) in the {% data variables.product.prodname_vscode %} documentation. +For more information on using MCP servers in {% data variables.product.prodname_vscode %}, see [Use MCP servers in {% data variables.product.prodname_vscode %}](https://aka.ms/vscode-add-mcp) in the {% data variables.product.prodname_vscode %} documentation. ## Using existing MCP configurations @@ -140,13 +142,13 @@ For information on other currently available MCP servers, see [the MCP servers r ## Configuring MCP servers in JetBrains IDEs 1. In the lower right corner, click **{% octicon "copilot" aria-hidden="true" aria-label="copilot" %}**. -1. From the menu, select "Edit settings". -1. Under the MCP section, click "Edit in `mcp.json`". +1. From the menu, select "Edit settings." +1. Under the MCP section, click "Edit in `mcp.json`." 1. Define your MCP servers. You can use the following configuration as an example: {% data reusables.copilot.mcp-chat-json-snippet-for-other-ides %} -Alternatively, to access the MCP settings, once you're in "Agent Mode", click the tools icon, then click **Add more tools**. +Alternatively, to access the MCP settings, once you're in "Agent Mode," click the tools icon, then click **Add more tools**. {% endjetbrains %} @@ -167,7 +169,7 @@ For information on other currently available MCP servers, see [the MCP servers r 1. Open the {% data variables.product.prodname_copilot %} for Xcode extension. 1. In agent mode, click the tools icon. -1. Select "Edit config". +1. Select "Edit config." 1. Define your MCP servers, editing `mcp.json`. You can use the following configuration as an example: {% data reusables.copilot.mcp-chat-json-snippet-for-other-ides %} @@ -191,7 +193,7 @@ For information on other currently available MCP servers, see [the MCP servers r ## Configuring MCP servers in Eclipse 1. To open the {% data variables.copilot.copilot_chat_short %} panel, click the {% data variables.product.prodname_copilot_short %} icon ({% octicon "copilot" aria-hidden="true" aria-label="copilot" %}) in the status bar at the bottom of Eclipse. -1. From the menu, select "Edit preferences". +1. From the menu, select "Edit preferences." 1. In the left pane, expand {% data variables.copilot.copilot_chat_short %} and click **MCP**. 1. Define your MCP servers. You can use the following configuration as an example: diff --git a/content/copilot/tutorials/enhancing-copilot-agent-mode-with-mcp.md b/content/copilot/tutorials/enhancing-copilot-agent-mode-with-mcp.md index b686cf74c718..e799618fca39 100644 --- a/content/copilot/tutorials/enhancing-copilot-agent-mode-with-mcp.md +++ b/content/copilot/tutorials/enhancing-copilot-agent-mode-with-mcp.md @@ -11,15 +11,15 @@ type: how_to --- >[!NOTE] -> * MCP support is currently in {% data variables.release-phases.public_preview %} and subject to change. -> * MCP support is available in {% data variables.copilot.copilot_chat_short %} for {% data variables.product.prodname_vscode %}, {% data variables.product.prodname_vs %}, JetBrains, Eclipse, and Xcode. +> * MCP support is generally available (GA) in {% data variables.copilot.copilot_chat_short %} for {% data variables.product.prodname_vscode %}. +> * MCP support for Copilot in {% data variables.product.prodname_vs %}, JetBrains, Eclipse, and Xcode is in {% data variables.release-phases.public_preview %} and is subject to change. > * The [AUTOTITLE](/free-pro-team@latest/site-policy/github-terms/github-pre-release-license-terms) apply to your use of this product. ## About {% data variables.product.prodname_copilot_short %}'s agentic capabilities and MCP {% data variables.product.prodname_copilot_short %}'s agentic capabilities refer to the ability to **work independently** by executing multi-step workflows without constant guidance, **make decisions** by choosing appropriate tools and approaches based on context, and **iterate and adapt** by adjusting its approach according to feedback and results. You can access these capabilities by using agent mode. -When combined with Model Context Protocol (MCP) servers, agent mode becomes significantly more powerful, giving {% data variables.product.prodname_copilot_short %} access to external resources without switching context. This enables {% data variables.product.prodname_copilot_short %} to complete agentic "loops", where it can dynamically adapt its approach by autonomously finding relevant information, analyzing feedback, and making informed decisions. With MCP, {% data variables.product.prodname_copilot_short %} can complete a task with minimal human intervention, continuously adjusting its strategy based on what it discovers. +When combined with Model Context Protocol (MCP) servers, agent mode becomes significantly more powerful, giving {% data variables.product.prodname_copilot_short %} access to external resources without switching context. This enables {% data variables.product.prodname_copilot_short %} to complete agentic "loops," where it can dynamically adapt its approach by autonomously finding relevant information, analyzing feedback, and making informed decisions. With MCP, {% data variables.product.prodname_copilot_short %} can complete a task with minimal human intervention, continuously adjusting its strategy based on what it discovers. ### Benefits of combining MCP with agent mode From 8c973a674b46a933d918a575045e53f254fb780c Mon Sep 17 00:00:00 2001 From: Steve Ward Date: Fri, 11 Jul 2025 16:16:13 -0400 Subject: [PATCH 2/3] [EDI - Actions] Move "Building and testing" to underneath "Writing workflows" (#56593) --- content/actions/how-tos/use-cases-and-examples/index.md | 1 - .../building-and-testing/building-and-testing-go.md | 4 ++-- .../building-and-testing-java-with-ant.md | 3 +-- .../building-and-testing-java-with-gradle.md | 4 ++-- .../building-and-testing-java-with-maven.md | 4 ++-- .../building-and-testing/building-and-testing-net.md | 3 ++- .../building-and-testing/building-and-testing-nodejs.md | 4 ++-- .../building-and-testing/building-and-testing-powershell.md | 5 +++-- .../building-and-testing/building-and-testing-python.md | 4 ++-- .../building-and-testing/building-and-testing-ruby.md | 2 +- .../building-and-testing/building-and-testing-rust.md | 4 ++-- .../building-and-testing/building-and-testing-swift.md | 4 ++-- .../building-and-testing-xamarin-applications.md | 4 ++-- .../building-and-testing/index.md | 1 + content/actions/how-tos/writing-workflows/index.md | 1 + content/actions/index.md | 2 +- 16 files changed, 26 insertions(+), 24 deletions(-) rename content/actions/how-tos/{use-cases-and-examples => writing-workflows}/building-and-testing/building-and-testing-go.md (97%) rename content/actions/how-tos/{use-cases-and-examples => writing-workflows}/building-and-testing/building-and-testing-java-with-ant.md (97%) rename content/actions/how-tos/{use-cases-and-examples => writing-workflows}/building-and-testing/building-and-testing-java-with-gradle.md (96%) rename content/actions/how-tos/{use-cases-and-examples => writing-workflows}/building-and-testing/building-and-testing-java-with-maven.md (96%) rename content/actions/how-tos/{use-cases-and-examples => writing-workflows}/building-and-testing/building-and-testing-net.md (98%) rename content/actions/how-tos/{use-cases-and-examples => writing-workflows}/building-and-testing/building-and-testing-nodejs.md (98%) rename content/actions/how-tos/{use-cases-and-examples => writing-workflows}/building-and-testing/building-and-testing-powershell.md (98%) rename content/actions/how-tos/{use-cases-and-examples => writing-workflows}/building-and-testing/building-and-testing-python.md (99%) rename content/actions/how-tos/{use-cases-and-examples => writing-workflows}/building-and-testing/building-and-testing-ruby.md (99%) rename content/actions/how-tos/{use-cases-and-examples => writing-workflows}/building-and-testing/building-and-testing-rust.md (97%) rename content/actions/how-tos/{use-cases-and-examples => writing-workflows}/building-and-testing/building-and-testing-swift.md (96%) rename content/actions/how-tos/{use-cases-and-examples => writing-workflows}/building-and-testing/building-and-testing-xamarin-applications.md (94%) rename content/actions/how-tos/{use-cases-and-examples => writing-workflows}/building-and-testing/index.md (95%) diff --git a/content/actions/how-tos/use-cases-and-examples/index.md b/content/actions/how-tos/use-cases-and-examples/index.md index 31a6e86ab015..471c207e86b4 100644 --- a/content/actions/how-tos/use-cases-and-examples/index.md +++ b/content/actions/how-tos/use-cases-and-examples/index.md @@ -10,7 +10,6 @@ redirect_from: - /actions/examples - /actions/use-cases-and-examples children: - - building-and-testing - publishing-packages - project-management - using-containerized-services diff --git a/content/actions/how-tos/use-cases-and-examples/building-and-testing/building-and-testing-go.md b/content/actions/how-tos/writing-workflows/building-and-testing/building-and-testing-go.md similarity index 97% rename from content/actions/how-tos/use-cases-and-examples/building-and-testing/building-and-testing-go.md rename to content/actions/how-tos/writing-workflows/building-and-testing/building-and-testing-go.md index 910b8f48c3d7..e1d93a87135f 100644 --- a/content/actions/how-tos/use-cases-and-examples/building-and-testing/building-and-testing-go.md +++ b/content/actions/how-tos/writing-workflows/building-and-testing/building-and-testing-go.md @@ -1,17 +1,17 @@ --- title: Building and testing Go -intro: You can create a continuous integration (CI) workflow to build and test your Go project. +intro: Learn how to create a continuous integration (CI) workflow to build and test your Go project. versions: fpt: '*' ghes: '*' ghec: '*' -type: tutorial topics: - CI shortTitle: Build & test Go redirect_from: - /actions/automating-builds-and-tests/building-and-testing-go - /actions/use-cases-and-examples/building-and-testing/building-and-testing-go + - /actions/how-tos/use-cases-and-examples/building-and-testing/building-and-testing-go --- {% data reusables.actions.enterprise-github-hosted-runners %} diff --git a/content/actions/how-tos/use-cases-and-examples/building-and-testing/building-and-testing-java-with-ant.md b/content/actions/how-tos/writing-workflows/building-and-testing/building-and-testing-java-with-ant.md similarity index 97% rename from content/actions/how-tos/use-cases-and-examples/building-and-testing/building-and-testing-java-with-ant.md rename to content/actions/how-tos/writing-workflows/building-and-testing/building-and-testing-java-with-ant.md index fb0dd0ab6b9e..ff4afe15b20f 100644 --- a/content/actions/how-tos/use-cases-and-examples/building-and-testing/building-and-testing-java-with-ant.md +++ b/content/actions/how-tos/writing-workflows/building-and-testing/building-and-testing-java-with-ant.md @@ -1,6 +1,6 @@ --- title: Building and testing Java with Ant -intro: You can create a continuous integration (CI) workflow in GitHub Actions to build and test your Java project with Ant. +intro: Learn how to create a continuous integration (CI) workflow in GitHub Actions to build and test your Java project with Ant. redirect_from: - /actions/language-and-framework-guides/building-and-testing-java-with-ant - /actions/guides/building-and-testing-java-with-ant @@ -10,7 +10,6 @@ versions: fpt: '*' ghes: '*' ghec: '*' -type: tutorial topics: - CI - Java diff --git a/content/actions/how-tos/use-cases-and-examples/building-and-testing/building-and-testing-java-with-gradle.md b/content/actions/how-tos/writing-workflows/building-and-testing/building-and-testing-java-with-gradle.md similarity index 96% rename from content/actions/how-tos/use-cases-and-examples/building-and-testing/building-and-testing-java-with-gradle.md rename to content/actions/how-tos/writing-workflows/building-and-testing/building-and-testing-java-with-gradle.md index 7562345edcd4..ba00ebb39583 100644 --- a/content/actions/how-tos/use-cases-and-examples/building-and-testing/building-and-testing-java-with-gradle.md +++ b/content/actions/how-tos/writing-workflows/building-and-testing/building-and-testing-java-with-gradle.md @@ -1,16 +1,16 @@ --- title: Building and testing Java with Gradle -intro: You can create a continuous integration (CI) workflow in GitHub Actions to build and test your Java project with Gradle. +intro: Learn how to create a continuous integration (CI) workflow in GitHub Actions to build and test your Java project with Gradle. redirect_from: - /actions/language-and-framework-guides/building-and-testing-java-with-gradle - /actions/guides/building-and-testing-java-with-gradle - /actions/automating-builds-and-tests/building-and-testing-java-with-gradle - /actions/use-cases-and-examples/building-and-testing/building-and-testing-java-with-gradle + - /actions/how-tos/use-cases-and-examples/building-and-testing/building-and-testing-java-with-gradle versions: fpt: '*' ghes: '*' ghec: '*' -type: tutorial topics: - CI - Java diff --git a/content/actions/how-tos/use-cases-and-examples/building-and-testing/building-and-testing-java-with-maven.md b/content/actions/how-tos/writing-workflows/building-and-testing/building-and-testing-java-with-maven.md similarity index 96% rename from content/actions/how-tos/use-cases-and-examples/building-and-testing/building-and-testing-java-with-maven.md rename to content/actions/how-tos/writing-workflows/building-and-testing/building-and-testing-java-with-maven.md index 3fdfbdc91fbd..643fd5f11670 100644 --- a/content/actions/how-tos/use-cases-and-examples/building-and-testing/building-and-testing-java-with-maven.md +++ b/content/actions/how-tos/writing-workflows/building-and-testing/building-and-testing-java-with-maven.md @@ -1,16 +1,16 @@ --- title: Building and testing Java with Maven -intro: You can create a continuous integration (CI) workflow in GitHub Actions to build and test your Java project with Maven. +intro: Learn how to create a continuous integration (CI) workflow in GitHub Actions to build and test your Java project with Maven. redirect_from: - /actions/language-and-framework-guides/building-and-testing-java-with-maven - /actions/guides/building-and-testing-java-with-maven - /actions/automating-builds-and-tests/building-and-testing-java-with-maven - /actions/use-cases-and-examples/building-and-testing/building-and-testing-java-with-maven + - /actions/how-tos/use-cases-and-examples/building-and-testing/building-and-testing-java-with-maven versions: fpt: '*' ghes: '*' ghec: '*' -type: tutorial topics: - CI - Java diff --git a/content/actions/how-tos/use-cases-and-examples/building-and-testing/building-and-testing-net.md b/content/actions/how-tos/writing-workflows/building-and-testing/building-and-testing-net.md similarity index 98% rename from content/actions/how-tos/use-cases-and-examples/building-and-testing/building-and-testing-net.md rename to content/actions/how-tos/writing-workflows/building-and-testing/building-and-testing-net.md index 555916e8363b..399b1cdbc7d3 100644 --- a/content/actions/how-tos/use-cases-and-examples/building-and-testing/building-and-testing-net.md +++ b/content/actions/how-tos/writing-workflows/building-and-testing/building-and-testing-net.md @@ -1,10 +1,11 @@ --- title: Building and testing .NET -intro: You can create a continuous integration (CI) workflow to build and test your .NET project. +intro: Learn how to create a continuous integration (CI) workflow to build and test your .NET project. redirect_from: - /actions/guides/building-and-testing-net - /actions/automating-builds-and-tests/building-and-testing-net - /actions/use-cases-and-examples/building-and-testing/building-and-testing-net + - /actions/how-tos/use-cases-and-examples/building-and-testing/building-and-testing-net versions: fpt: '*' ghes: '*' diff --git a/content/actions/how-tos/use-cases-and-examples/building-and-testing/building-and-testing-nodejs.md b/content/actions/how-tos/writing-workflows/building-and-testing/building-and-testing-nodejs.md similarity index 98% rename from content/actions/how-tos/use-cases-and-examples/building-and-testing/building-and-testing-nodejs.md rename to content/actions/how-tos/writing-workflows/building-and-testing/building-and-testing-nodejs.md index 0c21401daa8b..b0ffeda07825 100644 --- a/content/actions/how-tos/use-cases-and-examples/building-and-testing/building-and-testing-nodejs.md +++ b/content/actions/how-tos/writing-workflows/building-and-testing/building-and-testing-nodejs.md @@ -1,17 +1,17 @@ --- title: Building and testing Node.js -intro: You can create a continuous integration (CI) workflow to build and test your Node.js project. +intro: Learn how to create a continuous integration (CI) workflow to build and test your Node.js project. redirect_from: - /actions/automating-your-workflow-with-github-actions/using-nodejs-with-github-actions - /actions/language-and-framework-guides/using-nodejs-with-github-actions - /actions/guides/building-and-testing-nodejs - /actions/automating-builds-and-tests/building-and-testing-nodejs - /actions/use-cases-and-examples/building-and-testing/building-and-testing-nodejs + - /actions/how-tos/use-cases-and-examples/building-and-testing/building-and-testing-nodejs versions: fpt: '*' ghes: '*' ghec: '*' -type: tutorial topics: - CI - Node diff --git a/content/actions/how-tos/use-cases-and-examples/building-and-testing/building-and-testing-powershell.md b/content/actions/how-tos/writing-workflows/building-and-testing/building-and-testing-powershell.md similarity index 98% rename from content/actions/how-tos/use-cases-and-examples/building-and-testing/building-and-testing-powershell.md rename to content/actions/how-tos/writing-workflows/building-and-testing/building-and-testing-powershell.md index 4f38d926ab53..d6167d91b5f1 100644 --- a/content/actions/how-tos/use-cases-and-examples/building-and-testing/building-and-testing-powershell.md +++ b/content/actions/how-tos/writing-workflows/building-and-testing/building-and-testing-powershell.md @@ -1,17 +1,18 @@ --- title: Building and testing PowerShell -intro: You can create a continuous integration (CI) workflow to build and test your PowerShell project. +intro: Learn how to create a continuous integration (CI) workflow to build and test your PowerShell project. redirect_from: - /actions/guides/building-and-testing-powershell - /actions/automating-builds-and-tests/building-and-testing-powershell - /actions/use-cases-and-examples/building-and-testing/building-and-testing-powershell + - /actions/how-tos/use-cases-and-examples/building-and-testing/building-and-testing-powershell versions: fpt: '*' ghes: '*' ghec: '*' authors: - potatoqualitee -type: tutorial + topics: - CI - PowerShell diff --git a/content/actions/how-tos/use-cases-and-examples/building-and-testing/building-and-testing-python.md b/content/actions/how-tos/writing-workflows/building-and-testing/building-and-testing-python.md similarity index 99% rename from content/actions/how-tos/use-cases-and-examples/building-and-testing/building-and-testing-python.md rename to content/actions/how-tos/writing-workflows/building-and-testing/building-and-testing-python.md index 272e4b9d5fb4..04d28054691c 100644 --- a/content/actions/how-tos/use-cases-and-examples/building-and-testing/building-and-testing-python.md +++ b/content/actions/how-tos/writing-workflows/building-and-testing/building-and-testing-python.md @@ -1,17 +1,17 @@ --- title: Building and testing Python -intro: You can create a continuous integration (CI) workflow to build and test your Python project. +intro: Learn how to create a continuous integration (CI) workflow to build and test your Python project. redirect_from: - /actions/automating-your-workflow-with-github-actions/using-python-with-github-actions - /actions/language-and-framework-guides/using-python-with-github-actions - /actions/guides/building-and-testing-python - /actions/automating-builds-and-tests/building-and-testing-python - /actions/use-cases-and-examples/building-and-testing/building-and-testing-python + - /actions/how-tos/use-cases-and-examples/building-and-testing/building-and-testing-python versions: fpt: '*' ghes: '*' ghec: '*' -type: tutorial topics: - CI - Python diff --git a/content/actions/how-tos/use-cases-and-examples/building-and-testing/building-and-testing-ruby.md b/content/actions/how-tos/writing-workflows/building-and-testing/building-and-testing-ruby.md similarity index 99% rename from content/actions/how-tos/use-cases-and-examples/building-and-testing/building-and-testing-ruby.md rename to content/actions/how-tos/writing-workflows/building-and-testing/building-and-testing-ruby.md index c730c74dc3f6..55edde99fc6e 100644 --- a/content/actions/how-tos/use-cases-and-examples/building-and-testing/building-and-testing-ruby.md +++ b/content/actions/how-tos/writing-workflows/building-and-testing/building-and-testing-ruby.md @@ -5,11 +5,11 @@ redirect_from: - /actions/guides/building-and-testing-ruby - /actions/automating-builds-and-tests/building-and-testing-ruby - /actions/use-cases-and-examples/building-and-testing/building-and-testing-ruby + - /actions/how-tos/use-cases-and-examples/building-and-testing/building-and-testing-ruby versions: fpt: '*' ghes: '*' ghec: '*' -type: tutorial topics: - CI - Ruby diff --git a/content/actions/how-tos/use-cases-and-examples/building-and-testing/building-and-testing-rust.md b/content/actions/how-tos/writing-workflows/building-and-testing/building-and-testing-rust.md similarity index 97% rename from content/actions/how-tos/use-cases-and-examples/building-and-testing/building-and-testing-rust.md rename to content/actions/how-tos/writing-workflows/building-and-testing/building-and-testing-rust.md index 7a770717423e..81dbe26335d8 100644 --- a/content/actions/how-tos/use-cases-and-examples/building-and-testing/building-and-testing-rust.md +++ b/content/actions/how-tos/writing-workflows/building-and-testing/building-and-testing-rust.md @@ -1,16 +1,16 @@ --- title: Building and testing Rust -intro: You can create a continuous integration (CI) workflow to build and test your Rust project. +intro: Learn how to create a continuous integration (CI) workflow to build and test your Rust project. versions: fpt: '*' ghec: '*' ghes: '*' -type: tutorial topics: - CI shortTitle: Build & test Rust redirect_from: - /actions/use-cases-and-examples/building-and-testing/building-and-testing-rust + - /actions/how-tos/use-cases-and-examples/building-and-testing/building-and-testing-rust --- {% data reusables.actions.enterprise-github-hosted-runners %} diff --git a/content/actions/how-tos/use-cases-and-examples/building-and-testing/building-and-testing-swift.md b/content/actions/how-tos/writing-workflows/building-and-testing/building-and-testing-swift.md similarity index 96% rename from content/actions/how-tos/use-cases-and-examples/building-and-testing/building-and-testing-swift.md rename to content/actions/how-tos/writing-workflows/building-and-testing/building-and-testing-swift.md index ada22c274137..480f72cb10ba 100644 --- a/content/actions/how-tos/use-cases-and-examples/building-and-testing/building-and-testing-swift.md +++ b/content/actions/how-tos/writing-workflows/building-and-testing/building-and-testing-swift.md @@ -1,15 +1,15 @@ --- title: Building and testing Swift -intro: You can create a continuous integration (CI) workflow to build and test your Swift project. +intro: Learn how to create a continuous integration (CI) workflow to build and test your Swift project. redirect_from: - /actions/guides/building-and-testing-swift - /actions/automating-builds-and-tests/building-and-testing-swift - /actions/use-cases-and-examples/building-and-testing/building-and-testing-swift + - /actions/how-tos/use-cases-and-examples/building-and-testing/building-and-testing-swift versions: fpt: '*' ghes: '*' ghec: '*' -type: tutorial topics: - CI - Swift diff --git a/content/actions/how-tos/use-cases-and-examples/building-and-testing/building-and-testing-xamarin-applications.md b/content/actions/how-tos/writing-workflows/building-and-testing/building-and-testing-xamarin-applications.md similarity index 94% rename from content/actions/how-tos/use-cases-and-examples/building-and-testing/building-and-testing-xamarin-applications.md rename to content/actions/how-tos/writing-workflows/building-and-testing/building-and-testing-xamarin-applications.md index 427cd67c6067..364ff4d9bb06 100644 --- a/content/actions/how-tos/use-cases-and-examples/building-and-testing/building-and-testing-xamarin-applications.md +++ b/content/actions/how-tos/writing-workflows/building-and-testing/building-and-testing-xamarin-applications.md @@ -1,15 +1,15 @@ --- title: Building and testing Xamarin applications -intro: You can create a continuous integration (CI) workflow in GitHub Actions to build and test your Xamarin application. +intro: Learn how to create a continuous integration (CI) workflow in GitHub Actions to build and test your Xamarin application. redirect_from: - /actions/guides/building-and-testing-xamarin-applications - /actions/automating-builds-and-tests/building-and-testing-xamarin-applications - /actions/use-cases-and-examples/building-and-testing/building-and-testing-xamarin-applications + - /actions/how-tos/use-cases-and-examples/building-and-testing/building-and-testing-xamarin-applications versions: fpt: '*' ghes: '*' ghec: '*' -type: tutorial topics: - CI - Xamarin diff --git a/content/actions/how-tos/use-cases-and-examples/building-and-testing/index.md b/content/actions/how-tos/writing-workflows/building-and-testing/index.md similarity index 95% rename from content/actions/how-tos/use-cases-and-examples/building-and-testing/index.md rename to content/actions/how-tos/writing-workflows/building-and-testing/index.md index 3267d65f91c8..7b6d1dabe6ec 100644 --- a/content/actions/how-tos/use-cases-and-examples/building-and-testing/index.md +++ b/content/actions/how-tos/writing-workflows/building-and-testing/index.md @@ -18,6 +18,7 @@ redirect_from: - /actions/automating-builds-and-tests - /actions/examples/using-scripts-to-test-your-code-on-a-runner - /actions/use-cases-and-examples/building-and-testing + - /actions/how-tos/use-cases-and-examples/building-and-testing children: - /building-and-testing-go - /building-and-testing-java-with-ant diff --git a/content/actions/how-tos/writing-workflows/index.md b/content/actions/how-tos/writing-workflows/index.md index a17caee31301..662a58771bd3 100644 --- a/content/actions/how-tos/writing-workflows/index.md +++ b/content/actions/how-tos/writing-workflows/index.md @@ -15,5 +15,6 @@ children: - /choosing-when-your-workflow-runs - /choosing-where-your-workflow-runs - /choosing-what-your-workflow-does + - /building-and-testing --- diff --git a/content/actions/index.md b/content/actions/index.md index 1e192f0233fe..b7975d9bcab9 100644 --- a/content/actions/index.md +++ b/content/actions/index.md @@ -16,7 +16,7 @@ featuredLinks: guideCards: - /actions/how-tos/writing-workflows/using-workflow-templates - /actions/how-tos/use-cases-and-examples/publishing-packages/publishing-nodejs-packages - - /actions/how-tos/use-cases-and-examples/building-and-testing/building-and-testing-powershell + - /actions/how-tos/writing-workflows/building-and-testing/building-and-testing-powershell popular: - /actions/reference/workflow-syntax-for-github-actions - /actions/how-tos/writing-workflows From 241843919aa92e7831a7996c72ecc07d305b3e81 Mon Sep 17 00:00:00 2001 From: Sam Browning <106113886+sabrowning1@users.noreply.github.com> Date: Fri, 11 Jul 2025 16:56:28 -0400 Subject: [PATCH 3/3] EDI-ify "Storing and sharing data from a workflow" (#56606) Co-authored-by: Joe Clark <31087804+jc-clark@users.noreply.github.com> --- .../concepts/workflows-and-actions/index.md | 1 + .../workflow-artifacts.md | 43 ++++++++ .../choosing-what-your-workflow-does/index.md | 1 - content/actions/tutorials/index.md | 2 +- .../store-and-share-data.md} | 98 ++++--------------- 5 files changed, 62 insertions(+), 83 deletions(-) create mode 100644 content/actions/concepts/workflows-and-actions/workflow-artifacts.md rename content/actions/{how-tos/writing-workflows/choosing-what-your-workflow-does/storing-and-sharing-data-from-a-workflow.md => tutorials/store-and-share-data.md} (68%) diff --git a/content/actions/concepts/workflows-and-actions/index.md b/content/actions/concepts/workflows-and-actions/index.md index 5047b9b11f97..866b1d0fd0ec 100644 --- a/content/actions/concepts/workflows-and-actions/index.md +++ b/content/actions/concepts/workflows-and-actions/index.md @@ -14,6 +14,7 @@ children: - /contexts - /expressions - /deployment-environments + - /workflow-artifacts - /dependency-caching - /about-monitoring-workflows - /notifications-for-workflow-runs diff --git a/content/actions/concepts/workflows-and-actions/workflow-artifacts.md b/content/actions/concepts/workflows-and-actions/workflow-artifacts.md new file mode 100644 index 000000000000..e37ef12dcaf9 --- /dev/null +++ b/content/actions/concepts/workflows-and-actions/workflow-artifacts.md @@ -0,0 +1,43 @@ +--- +title: Workflow artifacts +intro: 'Learn about storing and sharing data as artifacts of {% data variables.product.prodname_actions %} workflows.' +versions: + fpt: '*' + ghes: '*' + ghec: '*' +type: overview +topics: + - Actions + - Workflows +--- + +## About workflow artifacts + +An artifact is a file or collection of files produced during a workflow run. Artifacts allow you to persist data after a job has completed, and share that data with another job in the same workflow. For example, you can use artifacts to save your build and test output after a workflow run has ended. + +{% data variables.product.github %} provides two actions that you can use to upload and download build artifacts, {% ifversion fpt or ghec %}[upload-artifact](https://github.com/actions/upload-artifact) and [download-artifact](https://github.com/actions/download-artifact){% else %} `upload-artifact` and `download-artifact` on {% data variables.product.prodname_ghe_server %}{% endif %}. + +Common artifacts include: + +* Log files and core dumps +* Test results, failures, and screenshots +* Binary or compressed files +* Stress test performance output and code coverage results + +{% data reusables.actions.comparing-artifacts-caching %} + +For more information on dependency caching, see [AUTOTITLE](/actions/using-workflows/caching-dependencies-to-speed-up-workflows#comparing-artifacts-and-dependency-caching). + +{% ifversion artifact-attestations %} + +## Generating artifact attestations for builds + +{% data reusables.actions.about-artifact-attestations %} + +You can access attestations after a build run, underneath the list of the artifacts the build produced. + +For more information, see [AUTOTITLE](/actions/security-guides/using-artifact-attestations-to-establish-provenance-for-builds). + +{% endif %} + +{% data reusables.actions.artifacts.artifacts-from-deleted-workflow-runs %} diff --git a/content/actions/how-tos/writing-workflows/choosing-what-your-workflow-does/index.md b/content/actions/how-tos/writing-workflows/choosing-what-your-workflow-does/index.md index 0ef0ad1a2b33..cbf061dfc564 100644 --- a/content/actions/how-tos/writing-workflows/choosing-what-your-workflow-does/index.md +++ b/content/actions/how-tos/writing-workflows/choosing-what-your-workflow-does/index.md @@ -21,5 +21,4 @@ children: - /deploying-to-a-specific-environment - /control-the-concurrency-of-workflows-and-jobs - /running-variations-of-jobs-in-a-workflow - - /storing-and-sharing-data-from-a-workflow --- diff --git a/content/actions/tutorials/index.md b/content/actions/tutorials/index.md index ac43e10c40e8..9fd47be92f36 100644 --- a/content/actions/tutorials/index.md +++ b/content/actions/tutorials/index.md @@ -12,10 +12,10 @@ children: - /creating-a-docker-container-action - /creating-a-javascript-action - /creating-a-composite-action + - /store-and-share-data - /quickstart-for-actions-runner-controller - /deploying-with-github-actions - /communicating-with-docker-service-containers redirect_from: - /actions/guides --- - diff --git a/content/actions/how-tos/writing-workflows/choosing-what-your-workflow-does/storing-and-sharing-data-from-a-workflow.md b/content/actions/tutorials/store-and-share-data.md similarity index 68% rename from content/actions/how-tos/writing-workflows/choosing-what-your-workflow-does/storing-and-sharing-data-from-a-workflow.md rename to content/actions/tutorials/store-and-share-data.md index be2f2d48855f..507711561c2c 100644 --- a/content/actions/how-tos/writing-workflows/choosing-what-your-workflow-does/storing-and-sharing-data-from-a-workflow.md +++ b/content/actions/tutorials/store-and-share-data.md @@ -1,7 +1,7 @@ --- -title: Storing and sharing data from a workflow -shortTitle: Store artifacts -intro: Artifacts allow you to share data between jobs in a workflow and store data once that workflow has completed. +title: Store and share data with workflow artifacts +shortTitle: Store and share data +intro: Use artifacts to share data between jobs in a workflow and store data once that workflow has completed. redirect_from: - /articles/persisting-workflow-data-using-artifacts - /github/automating-your-workflow-with-github-actions/persisting-workflow-data-using-artifacts @@ -12,6 +12,7 @@ redirect_from: - /actions/using-workflows/storing-workflow-data-as-artifacts - /actions/writing-workflows/choosing-what-your-workflow-does/storing-workflow-data-as-artifacts - /actions/writing-workflows/choosing-what-your-workflow-does/storing-and-sharing-data-from-a-workflow + - /actions/how-tos/writing-workflows/choosing-what-your-workflow-does/storing-and-sharing-data-from-a-workflow versions: fpt: '*' ghes: '*' @@ -19,52 +20,15 @@ versions: type: tutorial topics: - Workflows +allowTitleToDifferFromFilename: true --- -{% data reusables.actions.enterprise-github-hosted-runners %} +## Prerequisites -## About workflow artifacts - -Artifacts allow you to persist data after a job has completed, and share that data with another job in the same workflow. An artifact is a file or collection of files produced during a workflow run. For example, you can use artifacts to save your build and test output after a workflow run has ended. {% data reusables.actions.reusable-workflow-artifacts %} - -{% data reusables.actions.artifact-log-retention-statement %} The retention period for a pull request restarts each time someone pushes a new commit to the pull request. - -These are some of the common artifacts that you can upload: - -* Log files and core dumps -* Test results, failures, and screenshots -* Binary or compressed files -* Stress test performance output and code coverage results - -{% ifversion fpt or ghec %} - -Storing artifacts uses storage space on {% data variables.product.github %}. {% data reusables.actions.actions-billing %} For more information, see [AUTOTITLE](/billing/managing-billing-for-github-actions). - -{% else %} - -Artifacts consume storage space on the external blob storage that is configured for {% data variables.product.prodname_actions %} on {% data variables.product.prodname_ghe_server %}. - -{% endif %} - -Artifacts are uploaded during a workflow run, and you can view an artifact's name and size in the UI. When an artifact is downloaded using the {% data variables.product.github %} UI, all files that were individually uploaded as part of the artifact get zipped together into a single file. This means that billing is calculated based on the size of the uploaded artifact and not the size of the zip file. - -{% data variables.product.github %} provides two actions that you can use to upload and download build artifacts. For more information, see the {% ifversion fpt or ghec %}[upload-artifact](https://github.com/actions/upload-artifact) and [download-artifact](https://github.com/actions/download-artifact) actions{% else %} `upload-artifact` and `download-artifact` actions on {% data variables.product.prodname_ghe_server %}{% endif %}. - -To share data between jobs: - -* **Uploading files:** Give the uploaded file a name and upload the data before the job ends. -* **Downloading files:** You can only download artifacts that were uploaded during the same workflow run. When you download a file, you can reference it by name. - -The steps of a job share the same environment on the runner machine, but run in their own individual processes. To pass data between steps in a job, you can use inputs and outputs. For more information about inputs and outputs, see [AUTOTITLE](/actions/creating-actions/metadata-syntax-for-github-actions). - -{% data reusables.actions.comparing-artifacts-caching %} - -For more information on dependency caching, see [AUTOTITLE](/actions/using-workflows/caching-dependencies-to-speed-up-workflows#comparing-artifacts-and-dependency-caching). +Before you can complete this tutorial, you need to understand workflow artifacts. See [AUTOTITLE](/actions/concepts/workflows-and-actions/workflow-artifacts). ## Uploading build and test artifacts -You can create a continuous integration (CI) workflow to build and test your code. For more information about using {% data variables.product.prodname_actions %} to perform CI, see [AUTOTITLE](/actions/automating-builds-and-tests/about-continuous-integration). - The output of building and testing your code often produces files you can use to debug test failures and production code that you can deploy. You can configure a workflow to build and test the code pushed to your repository and report a success or failure status. You can upload the build and test output to use for deployments, debugging failed tests or crashes, and viewing test suite coverage. You can use the `upload-artifact` action to upload artifacts. When uploading an artifact, you can specify a single file or directory, or multiple files or directories. You can also exclude certain files or directories, and use wildcard patterns. We recommend that you provide a name for an artifact, but if no name is provided then `artifact` will be used as the default name. For more information on syntax, see the {% ifversion fpt or ghec %}[actions/upload-artifact](https://github.com/actions/upload-artifact) action{% else %} `actions/upload-artifact` action on {% data variables.product.prodname_ghe_server %}{% endif %}. @@ -119,18 +83,6 @@ jobs: path: output/test/code-coverage.html ``` -{% ifversion artifact-attestations %} - -## Generating artifact attestations for builds - -{% data reusables.actions.about-artifact-attestations %} - -You can access attestations after a build run, underneath the list of the artifacts the build produced. - -For more information, see [AUTOTITLE](/actions/security-guides/using-artifact-attestations-to-establish-provenance-for-builds). - -{% endif %} - ## Configuring a custom artifact retention period You can define a custom retention period for individual artifacts created by a workflow. When using a workflow to create a new artifact, you can use `retention-days` with the `upload-artifact` action. This example demonstrates how to set a custom retention period of 5 days for the artifact named `my-artifact`: @@ -146,15 +98,9 @@ You can define a custom retention period for individual artifacts created by a w The `retention-days` value cannot exceed the retention limit set by the repository, organization, or enterprise. -## Downloading or deleting artifacts - -During a workflow run, you can use the [`download-artifact`](https://github.com/actions/download-artifact) action to download artifacts that were previously uploaded in the same workflow run. - -After a workflow run has been completed, you can download or delete artifacts on {% data variables.product.prodname_dotcom %} or using the REST API. For more information, see [AUTOTITLE](/actions/managing-workflow-runs/downloading-workflow-artifacts), [AUTOTITLE](/actions/managing-workflow-runs/removing-workflow-artifacts), and [AUTOTITLE](/rest/actions/artifacts). - -### Downloading artifacts during a workflow run +## Downloading artifacts during a workflow run -The [`actions/download-artifact`](https://github.com/actions/download-artifact) action can be used to download previously uploaded artifacts during a workflow run. +You can use the [`actions/download-artifact`](https://github.com/actions/download-artifact) action to download previously uploaded artifacts during a workflow run. > [!NOTE] > {% ifversion fpt or ghec %}If you want to download artifacts from a different workflow or workflow run, you need to supply a token and run identifier. See [Download Artifacts from other Workflow Runs or Repositories](https://github.com/actions/download-artifact?tab=readme-ov-file#download-artifacts-from-other-workflow-runs-or-repositories) in the documentation for the `download-artifact` action. @@ -180,20 +126,6 @@ If you download all workflow run's artifacts, a directory for each artifact is c For more information on syntax, see the {% ifversion fpt or ghec %}[actions/download-artifact](https://github.com/actions/download-artifact) action{% else %} `actions/download-artifact` action on {% data variables.product.prodname_ghe_server %}{% endif %}. -{% ifversion fpt or ghec %} - -## Validating artifacts - -Every time the upload-artifact action is used it returns an output called `digest`. This is a SHA256 digest of the Artifact you uploaded during a workflow run. - -When the download-artifact action is then used to download that artifact, it automatically calculates the digest for that downloaded artifact and validates that it matches the output from the upload-artifact step. - -If the digest does not match, the run will display a warning in the UI and in the job logs. - -To view the SHA256 digest you can open the logs for the upload-artifact job or check in the Artifact output that appears in the workflow run UI. - -{% endif %} - ## Passing data between jobs in a workflow You can use the `upload-artifact` and `download-artifact` actions to share data between jobs in a workflow. This example workflow illustrates how to pass data between jobs in the same workflow. For more information, see the {% ifversion fpt or ghec %}[actions/upload-artifact](https://github.com/actions/upload-artifact) and [download-artifact](https://github.com/actions/download-artifact) actions{% else %} `actions/upload-artifact` and `download-artifact` actions on {% data variables.product.prodname_ghe_server %}{% endif %}. @@ -271,12 +203,16 @@ jobs: The workflow run will archive any artifacts that it generated. For more information on downloading archived artifacts, see [AUTOTITLE](/actions/managing-workflow-runs/downloading-workflow-artifacts). -{% data reusables.actions.artifacts.artifacts-from-deleted-workflow-runs %} - {% ifversion fpt or ghec %} -## Further reading +## Validating artifacts + +Every time the upload-artifact action is used it returns an output called `digest`. This is a SHA256 digest of the Artifact you uploaded during a workflow run. + +When the download-artifact action is then used to download that artifact, it automatically calculates the digest for that downloaded artifact and validates that it matches the output from the upload-artifact step. + +If the digest does not match, the run will display a warning in the UI and in the job logs. -* [AUTOTITLE](/billing/managing-billing-for-github-actions). +To view the SHA256 digest, open the logs for the upload-artifact job or check in the Artifact output that appears in the workflow run UI. {% endif %}