This repository has been archived by the owner on Nov 21, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
/
instruction.htm
395 lines (215 loc) · 7.64 KB
/
instruction.htm
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
<!DOCTYPE html>
<html>
<head>
<title>Python - instrukcja</title>
<meta charset="utf-8">
<link rel="stylesheet" href="../style.css">
</head>
<body>
<textarea id="source">
class: center, middle
# Python
### Instrukcja
### 12/04/2019
Paweł Suder
https://pasuder.github.io/labs/doc/lab04/instruction.htm
---
# Ćwiczenie
- pobranie [repozytorium](https://github.com/happy-pare/task-forces) do edytora
- wybierz zadanie z [listy zgłoszeń](https://github.com/happy-pare/task-forces/issues?utf8=%E2%9C%93&q=is%3Aissue+is%3Aopen+no%3Aassignee), które nie jest przypisane
- utwórz _gałąź_ w repozytorium przez edytor
- wykonaj implementacje zgodnie z zadaniem
- uruchom testy przez [terminal](https://pasuder.github.io/labs/doc/getting-started/#17) w edytorze
- opublikuj zmianę do przeglądu kodu przez innych
Dokładne opisy na następnych slajdach.
---
# Pobranie repozytorium
- pobierz [projekt](https://github.com/happy-pare/task-forces) do [edytora](https://editor.suder.dev) wykorzystując SSH URL, wykonując polecenie w [terminalu](https://pasuder.github.io/labs/doc/getting-started/#17):
```bash
git clone [email protected]:happy-pare/task-forces.git
```
- jeśli wykonałeś ćwiczenie z tworzeniem repozytorium, upewnij się, że masz wybrany projekt `task-forces` w edytorze (zrzuty ekranu na następnych slajdach)
---
class: center, middle
![](pic01.png)
_Pobranie repozytorium przez terminal_
---
class: center, middle
<img src="pic02.png" style="width: 45%"></img>
_Wybranie repozytorium, który ma być używany do wersjonowania w edytorze_
---
class: center, middle
<img src="pic03.png" style="width: 50%"></img>
_Właściwe repozytorium wybrane_
---
# Wybór zadania
- wybierz zadanie z [listy zgłoszeń](https://github.com/happy-pare/task-forces/issues?utf8=%E2%9C%93&q=is%3Aissue+is%3Aopen+no%3Aassignee), które nie jest przypisane
- jeśli nie ma zadania, zgłoś to prowadzącemu
---
class: center, middle
![](pic07.png)
_Lista zgłoszeń bez przypisanego **assignee**_
---
class: center, middle
![](pic08.png)
_Przypisanie się do zadania przez **assign yourself**_
---
class: center, middle
![](pic09.png)
_Przypisanie się do zadania przez **assign yourself**_
---
# Utworzenie gałęzi
- utwórz _gałąź_ w repozytorium przez edytor
- w ramach nowej gałęzi będzie zapisana i opublikowana zmiana z zadania
---
class: center, middle
<img src="pic04.png" style="width: 65%"></img>
_Utworzenie gałęzi o nazwie_ `feature_NUMER_ZADANIA`
---
class: center, middle
<img src="pic05.png" style="width: 85%"></img>
_Utworzenie gałęzi o nazwie_ `feature_NUMER_ZADANIA`
`NUMER_ZADANIA` to numer zgłoszenia na GitHub: `#1`, `#2`, `#3`, ..
---
class: center, middle
<img src="pic06.png" style="width: 40%"></img>
_Utworzenie gałęzi o nazwie_ `feature_NUMER_ZADANIA`
---
# Wykonanie implementacji
- wykonaj implementacje zgodnie z zadaniem
- jeśli zadanie jest niejasne, zadaj pytanie przez dodanie komentarza, w ramach zgłoszenia na GitHub (po angielsku lub polsku)
---
class: center, middle
<img src="pic10.png" style="width: 90%"></img>
_Nowa implementacja_
**Uwaga**: implementacja zadania może być inna niż powyżej widoczna.
---
class: center, middle
<img src="pic11.png" style="width: 85%"></img>
_Nowe testy_
---
# Uruchomienie testów
- otwórz terminal w edytorze
- wykonaj polecenie `pip install tox`, jeśli tego nie robiłeś/aś
- wykonaj polecenie `cd /home/project/task-forces`
- wykonaj polecenie `tox`
**Uwaga**: możliwe, że edytor nie będzie reagował przez chwilę. Poczekaj chwilę, do czasu, gdy będzie reagował. Jeśli problem się utrzymuje, daj proszę znać prowadzącemu.
---
class: center, middle
<img src="pic12.png" style="width: 85%"></img>
_Wynik testów uruchomionych przez terminal edytora_
---
# Udostępnienie zmian
- zatwierdź zmianę przez edytor
- udostępnij zmiany po tym, jak testy wykonają się poprawnie
- wykonaj [_Pull Request_](https://github.com/happy-pare/task-forces/compare) na GitHub
- daj znać prowadzącemu - możesz to zrobić bezpośrednio przez GitHub ;)
---
class: center, middle
<img src="pic13.png" style="width: 85%"></img>
_Oznacz pliki zmienione, aby zostały zatwierdzone_
---
class: center, middle
<img src="pic14.png" style="width: 85%"></img>
_Oznacz wszystkie pliki zmienione, aby zostały zatwierdzone_
---
class: center, middle
<img src="pic15.png" style="width: 85%"></img>
_Zatwierdź zmianę_
---
class: center, middle
<img src="pic16.png" style="width: 85%"></img>
Jeśli wystąpił taki błąd, wykonaj proszę polecenia z [instrukcji](https://pasuder.github.io/labs/doc/getting-started/#25)
```bash
git config --global user.email "[email protected]"
git config --global user.name "TWOJ LOGIN LUB IMIE"
```
---
class: center, middle
<img src="pic17.png" style="width: 85%"></img>
_Opublikuj zatwierdzone zmiany_
---
class: center, middle
<img src="pic18.png" style="width: 85%"></img>
_Opublikuj zatwierdzone zmiany_
---
class: center, middle
<img src="pic19.png" style="width: 85%"></img>
_W zgłoszeniu zadania pojawiła się dodatkowa informacja. Sprawdź swoje zgłoszenie._
---
class: center, middle
<img src="pic20.png" style="width: 85%"></img>
_W **Details** można sprawdzić, jak wykonują się automatycznie uruchomione testy_
---
class: center, middle
<img src="pic21.png" style="width: 85%"></img>
_Na głównej stronie projektu, pojawiła się informacja o Twojej gałęzi. Sprawdź nazwę i wykonaj **Compare & pull request**_.
---
class: center, middle
<img src="pic22.png" style="width: 85%"></img>
_Możesz też manualnie wybrać gałąź przez [stronę](https://github.com/happy-pare/task-forces/compare)_
---
class: center, middle
<img src="pic23.png" style="width: 85%"></img>
_Wykonaj **Create pull request**_
---
class: center, middle
<img src="pic24.png" style="width: 85%"></img>
_Wykonaj **Create pull request**_
---
class: center, middle
<img src="pic25.png" style="width: 85%"></img>
_Oto jak wygląda pull request_
**Poproś o review**
---
class: center, middle
<img src="pic27.png" style="width: 85%"></img>
_Dopóki nie będzie review, nie będzie można scalić zmiany_
---
class: center, middle
<img src="pic28.png" style="width: 85%"></img>
_Możesz zrobić komuś review_
---
class: center, middle
<img src="pic29.png" style="width: 85%"></img>
_Wykonaj **Add your review**_
---
class: center, middle
<img src="pic30.png" style="width: 85%"></img>
_Przejrzyj kod, skomentuj, jeśli potrzebne, a następnie wykonaj **Finish your review**_
---
class: center, middle
<img src="pic31.png" style="width: 85%"></img>
_Oto jak wygląda review_
---
class: center, middle
<img src="pic32.png" style="width: 85%"></img>
_Kiedy zmiana będzie zatwierdzona, można zrobić **Merge pull request**_
---
class: center, middle
<img src="pic33.png" style="width: 85%"></img>
_Następnie **Delete branch**_
---
class: center, middle
<img src="pic34.png" style="width: 85%"></img>
_W [historii zmian](https://github.com/happy-pare/task-forces/commits/master) można zobaczyć swoją zmianę_
---
class: center, middle
<img src="pic35.png" style="width: 85%"></img>
_Przypisane do Ciebie zgłoszenie zostało automatycznie zamknięte po scaleniu zmiany_
---
class: center, middle
<img src="pic36.png" style="width: 85%"></img>
_W [historii testowania](https://travis-ci.org/happy-pare/task-forces/builds) można zobaczyć testy pozostałych osób_
---
class: center, middle
# Dziękuję!
</textarea>
<script src="https://remarkjs.com/downloads/remark-latest.min.js">
</script>
<script>
var slideshow = remark.create();
</script>
</body>
</html>