| title | Editing files | |||||||
|---|---|---|---|---|---|---|---|---|
| intro | You can edit files directly on {% data variables.product.github %} in any of your repositories using the file editor. | |||||||
| redirect_from |
|
|||||||
| versions |
|
|||||||
| shortTitle | Edit files | |||||||
| category |
|
Tip
{% data reusables.repositories.protected-branches-block-web-edits-uploads %}
Note
{% data variables.product.github %}'s file editor uses CodeMirror.
- In your repository, browse to the file you want to edit. {% data reusables.repositories.edit-file %}
- In the text box, make any changes you need to the file. {% data reusables.files.preview_change %} {% data reusables.files.write_commit_message %} {% data reusables.files.choose-commit-email %} {% data reusables.files.choose_commit_branch %} {% data reusables.files.propose_file_change %}
When you edit a file in another user's repository, we'll automatically fork the repository and open a pull request for you.
- In another user's repository, browse to the folder that contains the file you want to edit. Click the name of the file you want to edit.
- Above the file content, click {% octicon "pencil" aria-label="Edit file" %}. On the page that appears, click Fork this repository.
- In the text box, make any changes you need to the file. {% data reusables.files.preview_change %} {% data reusables.files.write_commit_message %} {% data reusables.files.choose-commit-email %}
- Click Propose changes.
- Type a title and description for your pull request.
- Click Create pull request.