Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/abdulshaikh55/local-file-git
https://github.com/abdulshaikh55/local-file-git
Last synced: 24 days ago
JSON representation
- Host: GitHub
- URL: https://github.com/abdulshaikh55/local-file-git
- Owner: abdulshaikh55
- Created: 2023-12-22T11:28:17.000Z (about 1 year ago)
- Default Branch: master
- Last Pushed: 2024-03-26T05:40:06.000Z (10 months ago)
- Last Synced: 2024-11-09T02:55:49.959Z (3 months ago)
- Size: 4.88 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
to make this a git file use the term `git init`.
then track them using `git add .`.
then see the status using `git status`.
then commit using `git commit -m "create README.md`.
then create a repo in git hub with the name local-file-git
since, local file is `master` and remote branch is `main` by default, change branch name of local file
change branch name: `git branch -M main`
check the branch name: `git branch`
then copy the ssh and paste it at : `git remote add origin `
then push the file using `git push orign main` || `git push origin `
or `git push -u orign main` || `git push -u origin `
## Branches in git
1. To create a new branch use, `git checkout -b `
2. To check which branch you are on, use `git branch`
3. To switch brances, use `git checkout `
4. After adding, committing the new branch, push it using `git push origin `
5. create pull request on github an merge it.
6. You will notice after switching to master branch in your local file, that the changes do not appear.
7. To resolve that, use `git pull`
8. to delete the side branch, use `git branch -d `