M
M
ma4t2019-03-29 16:50:18
GitHub
ma4t, 2019-03-29 16:50:18

How to transfer a local rap to a remote one?

Hello.
I did the project locally. Indexed the changes, committed them, but everything is LOCAL.
Can I now link it to the remote repository so that the commits and everything are preserved. Or will it not work?
It's just that if I do a git clone and commit the files to the project, it will be one single commit completely completed, right? So not an option
Thank you

Answer the question

In order to leave comments, you need to log in

2 answer(s)
A
Alexander, 2019-03-29
@ma4t

You just need to specify a remote empty rep and fill it with git push - all local commits will be transferred.

A
Alexey Rogachev, 2019-04-04
@DrumBotanik

1. make an empty rep on github, take its url, for example
https://github.com/.../rep
2. add this link in the console as a remote rep
git remote add rep https://github.com/.. ./rep
3. push to this remote rep
git push rep master

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question