Created
December 9, 2024 11:16
-
-
Save prashantdsala/58efb9eb79f1ff35d0f66ec3c33838b9 to your computer and use it in GitHub Desktop.
Push non-git project to git repo
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
cd /path/to/your/project | |
git init | |
git add . | |
git commit -m "Initial commit" | |
git remote add origin https://github.com/username/repo-name.git | |
git branch -M main | |
git push -u origin main | |
git config pull.rebase true // For rebase to reconcile the branch |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment