How can I remove all files in my git repo and update/push from my local git repo?

后端 未结 14 1936
猫巷女王i
猫巷女王i 2021-01-29 20:20

Is it possible to remove all files in a repository and update it with only the files I have in my local machine? The reason is that, there are certain files that is not necessar

14条回答
  •  感情败类
    2021-01-29 21:00

    This process is simple, and follows the same flow as any git commit.

    1. Make sure your repo is fully up to date. (ex: git pull)
    2. Navigate to your repo folder on your local disk.
    3. Delete the files you don't want anymore.
    4. Then git commit -m "nuke and start again"
    5. Then git push
    6. Profit.

提交回复
热议问题