Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Repo sync #35418

Merged
merged 1 commit into from
Nov 25, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Original file line number Diff line number Diff line change
Expand Up @@ -18,13 +18,13 @@ redirect_from:

## About forking

If you want to contribute to someone else's project but don't have write access to the repository, you can use a "fork and pull request" workflow.
If you want to contribute to someone else's project but dont have permission to make changes directly, you can create your own copy of the project, make updates, and then suggest those updates for inclusion in the main project. This process is often called a "fork and pull request" workflow.

{% data reusables.repositories.fork-definition-long %}
When you create your own copy (or "fork") of a project, it’s like making a new workspace that shares code with the original project. This is useful for open-source projects or anytime you don’t have write access to the original project.

You can contribute by submitting pull requests from your fork to the upstream repository. For more information, see "[AUTOTITLE](/pull-requests/collaborating-with-pull-requests/working-with-forks/fork-a-repo)."
Once you’ve made your changes in your copy, you can submit them as a pull request, which is a way to propose changes back to the main project. For more information, see "[AUTOTITLE](/pull-requests/collaborating-with-pull-requests/working-with-forks/fork-a-repo)."

## Forking a repository
## Creating your own copy of a project

This tutorial uses [the Spoon-Knife project](https://github.com/octocat/Spoon-Knife), a test repository that's hosted on {% data variables.product.prodname_dotcom %} that lets you test the fork and pull request workflow.

Expand All @@ -44,7 +44,7 @@ This tutorial uses [the Spoon-Knife project](https://github.com/octocat/Spoon-Kn
> [!NOTE]
> If you want to copy additional branches from the upstream repository, you can do so from the **Branches** page. For more information, see "[AUTOTITLE](/pull-requests/collaborating-with-pull-requests/proposing-changes-to-your-work-with-pull-requests/creating-and-deleting-branches-within-your-repository)."

## Cloning a fork
## Cloning a fork to your computer

You've successfully forked the Spoon-Knife repository, but so far, it only exists on {% data variables.product.product_name %}. To be able to work on the project, you will need to clone it to your computer.

Expand Down Expand Up @@ -99,7 +99,7 @@ gh repo fork REPOSITORY --clone=true

## Creating a branch to work on

Before making changes to the project, you should create a new branch and check it out. By keeping changes in their own branch, you follow GitHub Flow and ensure that it will be easier to contribute to the same project again in the future. For more information, see "[AUTOTITLE](/get-started/using-github/github-flow#following-github-flow)."
Before making changes to the project, you should create a new branch and check it out. By keeping changes in their own branch, you follow {% data variables.product.github %} flow and ensure that it will be easier to contribute to the same project again in the future. See "[AUTOTITLE](/get-started/using-github/github-flow#following-github-flow)."

{% webui %}

Expand Down Expand Up @@ -127,7 +127,7 @@ For more information about how to create and manage branches in {% data variable

## Making and pushing changes

Go ahead and make a few changes to the project using your favorite text editor, like [{% data variables.product.prodname_vscode %}](https://code.visualstudio.com). You could, for example, change the text in `index.html` to add your GitHub username.
Go ahead and make a few changes to the project using your favorite text editor, like [{% data variables.product.prodname_vscode %}](https://code.visualstudio.com). You could, for example, change the text in `index.html` to add your {% data variables.product.github %} username.

When you're ready to submit your changes, stage and commit your changes. `git add .` tells Git that you want to include all of your changes in the next commit. `git commit` takes a snapshot of those changes.

Expand Down Expand Up @@ -199,3 +199,9 @@ Pull requests are an area for discussion. Don't be offended if the project owner

You've successfully forked and contributed back to a repository. Go forth, and
contribute some more!{% ifversion fpt %} For more information, see "[AUTOTITLE](/get-started/exploring-projects-on-github/finding-ways-to-contribute-to-open-source-on-github)."{% endif %}

{% ifversion copilot %}

## Familiarizing yourself with a project

If you're new to a project, you can use {% data variables.product.prodname_copilot_short %} to help you understand the purpose of the repository, examine files, and dive into specific lines of code. See "[AUTOTITLE](/get-started/exploring-projects-on-github/using-github-copilot-to-explore-projects)."{% endif %}
1 change: 1 addition & 0 deletions content/get-started/exploring-projects-on-github/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ topics:
- Projects
children:
- /finding-ways-to-contribute-to-open-source-on-github
- /using-github-copilot-to-explore-projects
- /contributing-to-a-project
- /saving-repositories-with-stars
- /following-people
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
---
title: Using GitHub Copilot to explore projects
intro: 'This guide will help you use {% data variables.product.prodname_copilot_short %} to explore projects on {% data variables.product.prodname_dotcom %}.'
versions:
feature: copilot
topics:
- Copilot
- Repositories
shortTitle: Use Copilot to explore projects
---

> [!NOTE] {% data variables.product.prodname_copilot_chat_dotcom %} is currently in {% data variables.release-phases.public_preview %} and is subject to change.

In this guide, you’ll learn how to use {% data variables.product.prodname_copilot_chat_dotcom_short %} to understand a repository’s purpose, examine files, and dive into specific lines of code. By following these steps, you’ll gain insights into any project faster—making onboarding, code review, and project exploration easier and more efficient.

## Prerequisites

{% data reusables.copilot.copilot-requires-subscription %}

## Understanding a repository

When you’re new to a project, it can be challenging to understand the purpose of a repository and its files. {% data variables.product.prodname_copilot_short %} can help you quickly understand the purpose of a repository, for example, by providing a summary of the repository’s README file.

1. On the {% data variables.product.prodname_dotcom %} website, go to the repository you want to chat about.

1. Click the **{% octicon "copilot" aria-hidden="true" %}** {% data variables.product.prodname_copilot %} icon at the top right of the page.
1. The heading at the top of the chat panel should read "Chatting about" followed by the name of the current repository.

If the wrong repository name is displayed, because you were previously chatting about another repository, click **All repositories** then choose the repository you want to chat about.

![Screenshot of the {% data variables.product.prodname_copilot_short %} chat panel page with "All repositories" highlighted with a dark orange outline.](/assets/images/help/copilot/copilot-chat-all-repositories.png)

1. In the "Ask {% data variables.product.prodname_copilot_short %}" box, at the bottom of the chat panel, type "Summarize the purpose of this repository based on the README" and press <kbd>Enter</kbd>. {% data variables.product.prodname_copilot_short %} replies in the chat panel.

You can also use {% data variables.product.prodname_copilot_short %} to understand the roles of different folders and files within the repository. For example, you can ask {% data variables.product.prodname_copilot_short %} to summarize the contents of a specific file, or to explain the purpose of a specific folder.

## Exploring files and code

When you’re exploring a project, you might want to understand the contents of a specific file. {% data variables.product.prodname_copilot_short %} can help you quickly understand the purpose of a file, for example, by providing a summary of the file’s contents. You can also ask {% data variables.product.prodname_copilot_short %} to explain specific lines of code within a file.

{% data reusables.copilot.chat-about-specific-lines %}

## Next steps

Now that you know how to use {% data variables.product.prodname_copilot_short %} to explore projects, you can use it to help you understand any repository, file, or line of code on {% data variables.product.prodname_dotcom %}.
38 changes: 33 additions & 5 deletions content/get-started/using-github/communicating-on-github.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@

{% data variables.product.product_name %} provides built-in collaborative communication tools allowing you to interact closely with your community. This quickstart guide will show you how to pick the right tool for your needs.

{% ifversion discussions %}

Check warning on line 25 in content/get-started/using-github/communicating-on-github.md

View workflow job for this annotation

GitHub Actions / lint-content

Liquid `ifversion` (and `elsif`) should not always be true

The Liquid ifversion condition 'discussions' includes all possible versions and will always be true.
{% ifversion team-discussions %}
You can create and participate in issues, pull requests, {% data variables.product.prodname_discussions %}, and team discussions, depending on the type of conversation you'd like to have.
{% else %}
Expand Down Expand Up @@ -59,11 +59,11 @@

### Team discussions

* can be started on your team's page for conversations that span across projects and don't belong in a specific issue or pull request. Instead of opening an issue in a repository to discuss an idea, you can include the entire team by having a conversation in a team discussion.
* allow you to hold discussions with your team about planning, analysis, design, user research and general project decision making in one place.{% ifversion ghes %}
* provide a collaborative experience outside the codebase, allowing the brainstorming of ideas.
* often don’t have a clear owner.
* often do not result in an actionable task.{% endif %}
* Can be started on your team's page for conversations that span across projects and don't belong in a specific issue or pull request. Instead of opening an issue in a repository to discuss an idea, you can include the entire team by having a conversation in a team discussion.
* Allow you to hold discussions with your team about planning, analysis, design, user research and general project decision making in one place.{% ifversion ghes %}
* Provide a collaborative experience outside the codebase, allowing the brainstorming of ideas.
* Often don’t have a clear owner.
* Often do not result in an actionable task.{% endif %}
{% endif %}

## Which discussion tool should I use?
Expand Down Expand Up @@ -109,7 +109,7 @@
* The user creates a pull request with the fix.
* A repository maintainer reviews the pull request, comments on it, and merges it.

{% ifversion discussions %}

Check warning on line 112 in content/get-started/using-github/communicating-on-github.md

View workflow job for this annotation

GitHub Actions / lint-content

Liquid `ifversion` (and `elsif`) should not always be true

The Liquid ifversion condition 'discussions' includes all possible versions and will always be true.

### Scenarios for {% data variables.product.prodname_discussions %}

Expand Down Expand Up @@ -140,7 +140,7 @@

This example shows a team post for the `octo-team` team.

![Example of team discussion.](/assets/images/help/projects/team-discussions-example.png)

Check warning on line 143 in content/get-started/using-github/communicating-on-github.md

View workflow job for this annotation

GitHub Actions / lint-content

Images alternate text should be between 40-150 characters

Image alternate text is 27 characters long.

The `octocat` team member posted a team discussion, informing the team of various things:
* A team member called Mona started remote game events.
Expand All @@ -148,6 +148,34 @@
* Material about the April All Hands is now available for all team members to view.
{% endif %}

{% ifversion copilot %}

## Using {% data variables.product.prodname_copilot_short %} to gain context

> [!NOTE] {% data reusables.copilot.copilot-requires-subscription %}

If you need more context or clarity on a specific issue or discussion, you can use {% data variables.product.prodname_copilot %} to help answer your questions. This enables you to quickly gain insights, understand complex threads, and stay aligned with the project’s goals, fostering collaboration and knowledge sharing within the community.

To ask a question about an issue or discussion:

1. From anywhere on {% data variables.product.github %}, click the **{% octicon "copilot" aria-hidden="true" %}** {% data variables.product.prodname_copilot %} icon next to the search bar in the top right of the page.

![Screenshot of the new conversation button, highlighted with a dark orange outline.](/assets/images/help/copilot/copilot-icon-top-right.png)

1. In the "Ask {% data variables.product.prodname_copilot_short %}" box, type a question and include the relevant URL in your message. For example, you could ask:

* `Explain https://github.com/monalisa/octokit/issues/1`
* `Summarize https://github.com/monalisa/octokit/discussions/4`
* `Recommend next steps for https://github.com/monalisa/octokit/issues/2`
* `What are the acceptance criteria for ISSUE URL?`
* `What are the main points made by PERSON in DISCUSSION URL?`

If you chat with {% data variables.product.prodname_copilot %} from a specific issue or discussion, you don't need to include the URL in your question.

{% data reusables.copilot.stop-response-generation %}

{% endif %}

## Next steps

These examples showed you how to decide which is the best tool for your conversations on {% data variables.product.product_name %}. But this is only the beginning; there is so much more you can do to tailor these tools to your needs.
Expand All @@ -156,7 +184,7 @@

For pull requests, you can create draft pull requests if your proposed changes are still a work in progress. Draft pull requests cannot be merged until they're marked as ready for review. For more information, see "[AUTOTITLE](/pull-requests/collaborating-with-pull-requests/proposing-changes-to-your-work-with-pull-requests/about-pull-requests#draft-pull-requests)."

{% ifversion discussions %}

Check warning on line 187 in content/get-started/using-github/communicating-on-github.md

View workflow job for this annotation

GitHub Actions / lint-content

Liquid `ifversion` (and `elsif`) should not always be true

The Liquid ifversion condition 'discussions' includes all possible versions and will always be true.
For {% data variables.product.prodname_discussions %}, you can{% ifversion fpt or ghec %} set up a code of conduct and{% endif %} pin discussions that contain important information for your community. For more information, see "[AUTOTITLE](/discussions/collaborating-with-your-community-using-discussions/about-discussions)."
{% endif %}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@

You can use {% data variables.product.prodname_dotcom %} repositories, issues, projects, and other tools to plan and track your work, whether working on an individual project or cross-functional team.

In this guide, you will learn how to create and set up a repository for collaborating with a group of people, create issue templates{% ifversion issue-forms %} and forms{% endif %}, open issues and use task lists to break down work, and establish a {% data variables.projects.projects_v1_board %} for organizing and tracking issues.

Check warning on line 19 in content/issues/tracking-your-work-with-issues/configuring-issues/planning-and-tracking-work-for-your-team-or-project.md

View workflow job for this annotation

GitHub Actions / lint-content

Liquid `ifversion` (and `elsif`) should not always be true

The Liquid ifversion condition 'issue-forms' includes all possible versions and will always be true.

## Creating a repository

Expand Down Expand Up @@ -54,7 +54,7 @@
* Feature requests: Your team or users can create issues to request an improvement to your product or project.
* Bugs: Your team or users can create issues to report a bug.

Depending on the type of repository and project you are working on, you may prioritize certain types of issues over others. Once you have identified the most common issue types for your team, you can create issue templates {% ifversion issue-forms %}and forms{% endif %} for your repository. Issue templates {% ifversion issue-forms %}and forms{% endif %} allow you to create a standardized list of templates that a contributor can choose from when they open an issue in your repository. For more information, see "[AUTOTITLE](/communities/using-templates-to-encourage-useful-issues-and-pull-requests/configuring-issue-templates-for-your-repository)."

Check warning on line 57 in content/issues/tracking-your-work-with-issues/configuring-issues/planning-and-tracking-work-for-your-team-or-project.md

View workflow job for this annotation

GitHub Actions / lint-content

Liquid `ifversion` (and `elsif`) should not always be true

The Liquid ifversion condition 'issue-forms' includes all possible versions and will always be true.

Check warning on line 57 in content/issues/tracking-your-work-with-issues/configuring-issues/planning-and-tracking-work-for-your-team-or-project.md

View workflow job for this annotation

GitHub Actions / lint-content

Liquid `ifversion` (and `elsif`) should not always be true

The Liquid ifversion condition 'issue-forms' includes all possible versions and will always be true.

### Issue template example

Expand Down Expand Up @@ -94,6 +94,41 @@

{% endif %}

{% ifversion copilot %}

## Understanding new issues

> [!NOTE] {% data reusables.copilot.copilot-requires-subscription %}

When working on an unfamiliar or complex issue, {% data variables.product.prodname_copilot %} can help you quickly understand the context, history, and key information, so you can get started faster and with more confidence.

### Reviewing the issue

1. Navigate to an issue on {% data variables.product.github %}.

{% data reusables.copilot.open-copilot %}

1. At the bottom of the {% data variables.product.prodname_copilot_short %} chat panel, in the "Ask {% data variables.product.prodname_copilot_short %}" box, type a question and press <kbd>Enter</kbd>. For example, you could enter:

* `Summarize the main points of this issue`
* `What’s the goal of this issue?`

{% data variables.product.prodname_copilot_short %}'s summary will help you capture the purpose and scope of the work.

### Understanding the history and comments

Issues often contain a history of discussions and decisions that can provide important context. You can use {% data variables.product.prodname_copilot_short %} to summarize these conversations to identify key points, such as proposed solutions or unanswered questions. For example, you might ask {% data variables.product.prodname_copilot_short %} to summarize recent comments or highlight decisions that have already been made. This helps you focus on what’s most relevant and ensures your contributions are aligned with the team’s priorities.

### Clarifying technical terms

Issues often mention technical terms, code, or files that might not be immediately clear. You can use {% data variables.product.prodname_copilot_short %} to get explanations or context for these references. For example, you can ask about the purpose of a file or function, or the meaning of a specific term mentioned in the issue. This helps you understand the details without spending extra time searching through documentation or code.

### Getting suggestions for next steps

Once you understand the context of an issue, {% data variables.product.prodname_copilot_short %} can help you figure out how to move forward. You can ask for suggestions on how to approach the work, like fixing a bug or implementing a new feature. For example, you might ask, “What’s the best way to resolve this issue?” or “How can I start addressing this problem?” {% data variables.product.prodname_copilot_short %}'s suggestions can provide useful starting points, helping you plan your work more effectively.

{% endif %}

## Making decisions as a team

You can use issues and discussions to communicate and make decisions as a team on planned improvements or priorities for your project. Issues are useful when you create them for discussion of specific details, such as bug or performance reports, planning for the next quarter, or design for a new initiative. Discussions are useful for open-ended brainstorming or feedback, outside the codebase and across repositories. For more information, see "[AUTOTITLE](/get-started/using-github/communicating-on-github#which-discussion-tool-should-i-use)."
Expand Down Expand Up @@ -130,7 +165,7 @@

Here is the table layout of an example project, populated with the Project Octocat issues we have created.

![Screenshot of the table view of the "Project Octocat" project, containing a list of issues, with columns for "Title," "Assignees," "Status," "Labels," and "Notes."](/assets/images/help/issues/quickstart-projects-table-view.png)

Check warning on line 168 in content/issues/tracking-your-work-with-issues/configuring-issues/planning-and-tracking-work-for-your-team-or-project.md

View workflow job for this annotation

GitHub Actions / lint-content

Images alternate text should be between 40-150 characters

Image alternate text is 163 characters long.

We can also view the same project as a board.

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@
![Screenshot of the "Files changed" tab for a pull request. The "Diff view" menu is outlined in dark orange.](/assets/images/help/pull_requests/diff-settings-menu.png)

You can also choose to hide whitespace differences. The choice you make only applies to this pull request and will be remembered the next time you visit this page.
1. Optionally, filter the files to show only the files you want to review{% ifversion pr-tree-view %} or use the file tree to navigate to a specific file{% endif %}. For more information, see "[AUTOTITLE](/pull-requests/collaborating-with-pull-requests/reviewing-changes-in-pull-requests/filtering-files-in-a-pull-request)."

Check warning on line 35 in content/pull-requests/collaborating-with-pull-requests/reviewing-changes-in-pull-requests/reviewing-proposed-changes-in-a-pull-request.md

View workflow job for this annotation

GitHub Actions / lint-content

Liquid `ifversion` (and `elsif`) should not always be true

The Liquid ifversion condition 'pr-tree-view' includes all possible versions and will always be true.
{%- ifversion ghec %}
1. Optionally, if you have access to {% data variables.product.prodname_copilot_enterprise %}, you can ask {% data variables.product.prodname_copilot_short %} about the changes in a file in a pull request by clicking {% octicon "kebab-horizontal" aria-label="Show options" %} at the top right of the file, clicking **Ask {% data variables.product.prodname_copilot_short %} about this diff**, then typing a request such as "Explain these changes." For more information, see "[AUTOTITLE](/enterprise-cloud@latest/copilot/github-copilot-chat/copilot-chat-in-github/using-github-copilot-chat-in-githubcom#asking-questions-about-a-specific-pull-request)."
{%- endif %}
Expand All @@ -40,7 +40,7 @@
{% data reusables.repositories.multiple-lines-comment %}
{% data reusables.repositories.type-line-comment %}
{% data reusables.repositories.suggest-changes %}
{% ifversion pull-request-comment-on-file %}

Check warning on line 43 in content/pull-requests/collaborating-with-pull-requests/reviewing-changes-in-pull-requests/reviewing-proposed-changes-in-a-pull-request.md

View workflow job for this annotation

GitHub Actions / lint-content

Liquid `ifversion` (and `elsif`) should not always be true

The Liquid ifversion condition 'pull-request-comment-on-file' includes all possible versions and will always be true.
{% data reusables.repositories.start-file-comment %}{% endif %}
1. When you're done, click **Start a review**. If you have already started a review, you can click **Add review comment**.

Expand All @@ -56,7 +56,7 @@
You can use [{% data variables.product.prodname_github_codespaces %}](/codespaces/overview) to test, run, and review pull requests.

1. Open the pull request in a codespace, as described in "[AUTOTITLE](/codespaces/developing-in-codespaces/using-github-codespaces-for-pull-requests#opening-a-pull-request-in-codespaces)."
1. In the Activity Bar, click the **GitHub Pull Request** view. This view only appears when you open a pull request in a codespace.
1. In the Activity Bar, click the **{% data variables.product.github %} Pull Request** view. This view only appears when you open a pull request in a codespace.

![Screenshot of the {% data variables.product.prodname_vscode_shortname %} Activity Bar. The mouse pointer is hovering over an icon displaying the tooltip "{% data variables.product.prodname_dotcom %} Pull Request."](/assets/images/help/codespaces/github-pr-view.png)

Expand All @@ -79,6 +79,33 @@
{% endcodespaces %}
{% endif %}

{% webui %}
{% ifversion copilot %}

## Understanding changes in a pull request

> [!NOTE] {% data reusables.copilot.copilot-requires-subscription %}

{% data variables.product.prodname_copilot %} can help you quickly understand the changes in a pull request by providing context and explanations for specific commits. If you’re unsure about the purpose of a particular change or need more details about how it fits into the broader codebase, you can ask {% data variables.product.prodname_copilot_short %} questions about individual commits.

1. Navigate to a commit on {% data variables.product.github %}.

{% data reusables.copilot.open-copilot %}

1. At the bottom of the {% data variables.product.prodname_copilot_short %} chat panel, in the "Ask {% data variables.product.prodname_copilot_short %}" box, type a question and press <kbd>Enter</kbd>. For example, you could enter:

* `Summarize the changes in this commit`
* `Who committed these changes?`
* `When was this commit made?`

> [!TIP]
> If you know the SHA for a commit, instead of navigating to the commit, you can ask {% data variables.product.prodname_copilot_short %} about the commit from any page in the repository on {% data variables.product.github %} by including the SHA in your message. For example, `What changed in commit a778e0eab?`

{% data reusables.copilot.stop-response-generation %}

{% endif %}
{% endwebui %}

## Reviewing dependency changes

If the pull request contains changes to dependencies you can use the dependency review for a manifest or lock file to see what has changed and check whether the changes introduce security vulnerabilities. For more information, see "[AUTOTITLE](/pull-requests/collaborating-with-pull-requests/reviewing-changes-in-pull-requests/reviewing-dependency-changes-in-a-pull-request)."
Expand Down
3 changes: 1 addition & 2 deletions content/repositories/working-with-files/using-files/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,8 @@ versions:
ghec: '*'
children:
- /navigating-code-on-github
- /viewing-a-file
- /viewing-and-understanding-files
- /getting-permanent-links-to-files
- /downloading-source-code-archives
- /working-with-non-code-files
---

Loading
Loading