How to upload a new project to gitblib
This article mainly shows you "how to upload a new project to gitblib". The content is simple and clear. I hope it can help you solve your doubts. Let the editor lead you to study and learn the article "how to upload a new project to gitblib".
1. Set up gitblib
1) download gitblib to http://gitblit.github.io/gitblit/
2) find gitblit.cmd in the home folder (I am using the windows version) to start
3) http://localhost:1000/ username and password are all admin
4) Click version Library-"create version Library" after logging in. For example, the address created is ssh://admin@localhost:29418/adms.git
Use the above four steps to build the gitblib and create an empty version library. Find your local code below
For example, my local code directory is E:\ adms\ adms-manage
1) git init # build git repository, cmd enter command line mode, and then cd to your local project root directory
2) git add. # add all the files of the project to the warehouse. If you want to add a specific file, just change it to a specific file name.
3) git commit-m "first commit" # add commit content once
4) git remote add origin ssh://admin@localhost:29418/adms.git # associates the local warehouse to the gitblit. Change the following link address to your own gitblit project repository url address.
5) git pull origin master # pull before uploading gitblit
6) git push-u origin master # pushes the project to the server corresponding to the master branch of the target location
The above is all the contents of the article "how to upload a new project to gitblib". Thank you for reading! I believe we all have a certain understanding, hope to share the content to help you, if you want to learn more knowledge, welcome to follow the industry information channel!