Follow

Keep Up to Date with the Most Important News

By pressing the Subscribe button, you confirm that you have read and are agreeing to our Privacy Policy and Terms of Use
Contact

Hello I am new and trying to learn to code, Issue with GitHub push and pull thing

I am very unfamiliar with Github and wanted to just upload a file I was going to change the next day. I understand this is the repository file is what it’s called.

I wanted to have when I do something in VS code to that same project it will update or request an update to go through.

So I tried testing this and I have just ran into issues.

MEDevel.com: Open-source for Healthcare and Education

Collecting and validating open-source software for healthcare, education, enterprise, development, medical imaging, medical records, and digital pathology.

Visit Medevel

Sorry if this is very nooby I watched a video and thought 5 mins this will be done then I can get back to adding my own things to the project.

I am trying to update something in the main branch and it will not let me and I have no understanding of what issues are going on in the output as it is foreign to me.

Please can I get some guidance on the issue?

The code so far:

git pull –tags
There is no tracking information for the current branch.
Please specify which branch you want to merge with.
See git-pull(1) for details.

git pull <remote> <branch>

If you wish to set tracking information for this branch you can do so with:

git branch --set-upstream-to=<remote>/<branch> main

I do not know how to even link them together to do push and pulls and have tried some git commands in the terminal and still nothing, it worked when I made a new branch but it did one file and not the one in the "main" folder branch

Error code 1
I just want to be able to update the main branch whenever I wanna add a new feature.

Also just tried git push -f orgin master and this shows
Error code after force push

>Solution :

  1. Create repository in github website. This is your remote copy
  2. Clone repository to your local machine.
  3. Open VS code in the directory of the repository.
  4. Create files, modify files.
  5. Commit changes in VS code UI.
  6. Push changes to remote.
  7. Pull or clone changes to other machine if necessary.
Add a comment

Leave a Reply

Keep Up to Date with the Most Important News

By pressing the Subscribe button, you confirm that you have read and are agreeing to our Privacy Policy and Terms of Use

Discover more from Dev solutions

Subscribe now to keep reading and get access to the full archive.

Continue reading