Actions
Example Git session - First steps using Git » History » Revision 2
« Previous |
Revision 2/3
(diff)
| Next »
Redmine Admin, 02/23/2016 02:00 PM
Example Git session - First steps using Git¶
Here's an example on using Git. The very first steps in using Git.
Please note that you need to adapt the Git repository URL!
In this example the repository is called "itisdb".¶
NOTE: Steps 1-4 needs to be done only once.¶
In order to use the itisdb git repository you need to follow the steps described here.
https://scm.in.tu-clausthal.de/projects/redmine-git-svn-help/wiki/Resolve_SSL_certificate_error_with_Git
- <cd> into your homedirectory
- Download the certificate chains
*wget "https://pki.pca.dfn.de/tu-clausthal-ca/pub/cacert/chain.txt"* --2016-02-23 11:35:35-- https://pki.pca.dfn.de/tu-clausthal-ca/pub/cacert/chain.txt Resolving pki.pca.dfn.de (pki.pca.dfn.de)... Connecting to pki.pca.dfn.de (pki.pca.dfn.de):443... connected. HTTP request sent, awaiting response... 200 OK Length: 5330 (5.2K) [text/plain] Saving to: 'chain.txt' chain.txt 100%[======================================================>] 5.21K --.-KB/s in 0s 2016-02-23 11:35:35 (49.0 MB/s) - 'chain.txt' saved [5330/5330]
wget "http://curl.haxx.se/ca/cacert.pem" --2016-02-23 11:35:51-- http://curl.haxx.se/ca/cacert.pem Resolving curl.haxx.se (curl.haxx.se)... Connecting to curl.haxx.se (curl.haxx.se):80... connected. HTTP request sent, awaiting response... 301 Moved Permanently Location: https://curl.haxx.se/ca/cacert.pem [following] --2016-02-23 11:35:51-- https://curl.haxx.se/ca/cacert.pem Connecting to curl.haxx.se (curl.haxx.se):443... connected. HTTP request sent, awaiting response... 200 OK Length: 252451 (247K) Saving to: 'cacert.pem' cacert.pem 100%[======================================================>] 246.53K 1.54MB/s in 0.2s 2016-02-23 11:35:52 (1.54 MB/s) - 'cacert.pem' saved [252451/252451]
- Append the TU-Clausthal-DFN chain to curls cacerts
cat cacert.pem chain.txt > TUC-DFN-chain.pem
- Create (or edit) a new file in your home directory called '.gitconfig' and insert
[http] sslCAInfo = /home/USERNAME/TUC-DFN-chain.pem
- Now that git knows the TU-Clausthal-DFN certificate chain you need to clone the itisdb repository on before you can add own files or chagesets.
git clone https://scm.in.tu-clausthal.de/git/itisdb
- Change into the <itisdb> directory to use the following commands.
Now that you've cloned your working copy you can add files or changes to your local repository (just copy the new files into the freshly cloned itisdb directroy).
Tell the itisdb repository that you've added/changed something with these commands
For single files or directories you changed usegit add <filename>
To add all files/changes you made usegit add *
- Now commit your changes to the HEAD of your local repository
git commit -m "Insert a meaningful commit message right here!"
- Finally push everything into the itisdb repository with
git push origin master
- Please update your local repository before start working on it with
git pull
For further documentation use these links:
http://gitref.org/
http://git-scm.com/docs
Updated by Redmine Admin almost 9 years ago · 2 revisions