Details | Last modification | View Log | RSS feed
Rev | Author | Line No. | Line |
---|---|---|---|
5564 | serge | 1 | |
2 | |||
3 | |||
4 | |||
5 |
|
||
6 | |||
7 | |||
8 | |||
9 | |||
10 | |||
11 |
|
||
12 | |||
13 | |||
14 | |||
15 | |||
16 | |||
17 |
|
||
18 | |||
19 | |||
20 | Mesa uses git |
||
21 | as its source code management system. |
||
22 | |||
23 | |||
24 | |||
25 | The master git repository is hosted on |
||
26 | freedesktop.org. |
||
27 | |||
28 | |||
29 | |||
30 | You may access the repository either as an |
||
31 | anonymous user (read-only) or as a |
||
32 | developer |
||
33 | (read/write). |
||
34 | |||
35 | |||
36 | |||
37 | You may also |
||
38 | |||
39 | >browse the main Mesa git repository and the |
||
40 | |||
41 | >Mesa demos and tests git repository. |
||
42 | |||
43 | |||
44 | |||
45 |
|
||
46 | |||
47 | |||
48 | To get the Mesa sources anonymously (read-only): |
||
49 | |||
50 | |||
51 | |||
52 | |||
53 | |||
54 | |||
55 | git clone git://anongit.freedesktop.org/git/mesa/mesa |
||
56 | |||
57 | |||
58 | |||
59 | git pull origin |
||
60 | |||
61 | |||
62 | |||
63 | git clone git://anongit.freedesktop.org/git/mesa/demos |
||
64 | |||
65 | |||
66 | |||
67 | |||
68 |
|
||
69 | |||
70 | |||
71 | Mesa developers need to first have an account on |
||
72 | freedesktop.org. |
||
73 | To get an account, please ask Brian or the other Mesa developers for |
||
74 | permission. |
||
75 | Then, if there are no objections, follow this |
||
76 | |||
77 | procedure. |
||
78 | |||
79 | |||
80 | |||
81 | Once your account is established: |
||
82 | |||
83 | |||
84 | |||
85 | |||
86 | |||
87 | |||
88 | git clone git+ssh://username@git.freedesktop.org/git/mesa/mesa |
||
89 | |||
90 | Replace username with your actual login name. |
||
91 | |||
92 | |||
93 | git pull origin |
||
94 | |||
95 | |||
96 | |||
97 | git clone git+ssh://username@git.freedesktop.org/git/mesa/demos |
||
98 | |||
99 | |||
100 | |||
101 | |||
102 |
|
||
103 | |||
104 | |||
105 | If you're |
||
106 | using git on Windows you'll want to enable automatic CR/LF conversion in |
||
107 | your local copy of the repository: |
||
108 | |||
109 | |||
110 | git config --global core.autocrlf true |
||
111 | |||
112 | |||
113 | |||
114 | This will cause git to convert all text files to CR+LF on checkout, |
||
115 | and to LF on commit. |
||
116 | |||
117 | |||
118 | Unix users don't need to set this option. |
||
119 | |||
120 | |||
121 | |||
122 | |||
123 |
|
||
124 | |||
125 | |||
126 | At any given time, there may be several active branches in Mesa's |
||
127 | repository. |
||
128 | Generally, the trunk contains the latest development (unstable) |
||
129 | code while a branch has the latest stable code. |
||
130 | |||
131 | |||
132 | |||
133 | The command |
||
134 | |||
135 | |||
136 | |||
137 | Questions about branch status/activity should be posted to the |
||
138 | mesa3d-dev mailing list. |
||
139 | |||
140 | |||
141 |
|
||
142 | |||
143 | |||
144 | |||
145 | |||
146 | If you try to do a pull by just saying |
||
147 | and git complains that you have not specified a |
||
148 | branch, try: |
||
149 | |||
150 | git config branch.master.remote origin |
||
151 | git config branch.master.merge master |
||
152 | |||
153 | |||
154 | Otherwise, you have to say |
||
155 | each time you do a pull. |
||
156 | |||
157 | |||
158 | |||
159 | If you are an experienced git user working on substantial modifications, |
||
160 | you are probably |
||
161 | working on a separate branch and would rebase your branch prior to |
||
162 | merging with master. |
||
163 | But for small changes to the master branch itself, |
||
164 | you also need to use the rebase feature in order to avoid an |
||
165 | unnecessary and distracting branch in master. |
||
166 | |||
167 | |||
168 | If it has been awhile since you've done the initial clone, try |
||
169 | |||
170 | git pull |
||
171 | |||
172 | |||
173 | to get the latest files before you start working. |
||
174 | |||
175 | |||
176 | Make your changes and use |
||
177 | |||
178 | git add <files to commit> |
||
179 | git commit |
||
180 | |||
181 | |||
182 | to get your changes ready to push back into the fd.o repository. |
||
183 | |||
184 | |||
185 | It is possible (and likely) that someone has changed master since |
||
186 | you did your last pull. Even if your changes do not conflict with |
||
187 | their changes, git will make a fast-forward |
||
188 | merge branch, branching from the point in time |
||
189 | where you did your last pull and merging it to a point after the other changes. |
||
190 | |||
191 | |||
192 | To avoid this, |
||
193 | |||
194 | git pull --rebase |
||
195 | git push |
||
196 | |||
197 | |||
198 | If you are familiar with CVS or similar system, this is similar to doing a |
||
199 |
|
||
200 | the current repository state, instead of the time you did the last update. |
||
201 | (CVS doesn't work like git in this respect, but this is easiest way |
||
202 | to explain it.) |
||
203 | |||
204 | In any case, your repository now looks like you made your changes after |
||
205 | all the other changes. |
||
206 | |||
207 | |||
208 | If the rebase resulted in conflicts or changes that could affect |
||
209 | the proper operation of your changes, you'll need to investigate |
||
210 | those before doing the push. |
||
211 | |||
212 | |||
213 | If you want the rebase action to be the default action, then |
||
214 | |||
215 | git config branch.master.rebase true |
||
216 | git config --global branch.autosetuprebase=always |
||
217 | |||
218 | |||
219 | See Understanding Git Conceptually for a fairly clear explanation about all of this. |
||
220 | |||
221 | |||
222 | |||
223 | |||
224 | |||
225 | !DOCTYPE> |