https://github.com/chmodshubham/github-cheat-codes
Github Cheat Codes
https://github.com/chmodshubham/github-cheat-codes
cheatsheet github
Last synced: 9 months ago
JSON representation
Github Cheat Codes
- Host: GitHub
- URL: https://github.com/chmodshubham/github-cheat-codes
- Owner: chmodshubham
- Created: 2023-06-21T14:22:40.000Z (about 3 years ago)
- Default Branch: main
- Last Pushed: 2023-07-25T06:47:51.000Z (almost 3 years ago)
- Last Synced: 2024-04-16T04:13:10.704Z (about 2 years ago)
- Topics: cheatsheet, github
- Homepage:
- Size: 2.93 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Github Cheat Codes
1. To List all branches:
```bash
git branch -a
```
2. To create a link to another file in the same repository, use the following syntax in your README file:
```bash
[Link Text](relative/path/to/file)
```
3. To restore all files in your project to their state at the last commit.
```bash
git restore --source=HEAD :/
```
4. To view all releases of a repository:
```bash
git tag
```