1
0
mirror of https://github.com/tiimgreen/github-cheat-sheet.git synced 2025-08-08 00:46:36 +02:00

Added Repository templates section

New feature that allows a repository to be used as a template
This commit is contained in:
Shahbaz Khan
2019-06-18 19:09:15 +01:00
committed by GitHub
parent 27749b9eae
commit ad15b718f2

View File

@@ -76,6 +76,7 @@ A collection of cool hidden and not so hidden features of Git and GitHub. This c
- [Git Books](#git-books)
- [Git Videos](#git-videos)
- [Git Articles](#git-articles)
-[Repository Templates](#repository-templates)
## GitHub
### Ignore Whitespace
@@ -669,6 +670,19 @@ e.g. [https://github.com/tiimgreen.keys](https://github.com/tiimgreen.keys)
[*Read more about accessing public ssh keys.*](https://changelog.com/github-exposes-public-ssh-keys-for-its-users/)
### Repository Templates
You can set your repository to template which allows anyone to copy the files and structure and allowing them to instantly use the files (e.g. for a tutorial or if writing boilerplate code).
This is done by going into settings for your repository and changing it to a template one
![Convert](https://i.postimg.cc/hGCrVm9F/Template.gif)
Changing to a template repository will give a new URL endpoint which can be shared and instantly allows users to use your repository as a template. Alternatively, they can go to your repository and click the 'Use as template' button.
![Template](https://i.postimg.cc/L8PKCHx0/New-Template.gif)
[*Read more about using repositories as templates*](https://github.blog/2019-06-06-generate-new-repositories-with-repository-templates/)
## Git
### Remove All Deleted Files from the Working Tree
When you delete a lot of files using `/bin/rm` you can use the following command to remove them from the working tree and from the index, eliminating the need to remove each one individually: