Menene Github, yadda ake amfani da shi, yadda ake ƙirƙirar aiki, sarrafawa da daidaitawa

Программирование

Menene GitHub, me yasa ake buƙata kuma yadda ake amfani da GitHub, yadda ake fara amfani da sabis – jagora ga masu farawa.
Menene Github, yadda ake amfani da shi, yadda ake ƙirƙirar aiki, sarrafawa da daidaitawa GitHub yana ɗaya daga cikin shahararrun sabis don ɗaukar ma’ajiyar buɗaɗɗen tushe. Gidan yanar gizon yana ba ku damar buga ayyukan al’ada da kuma bin diddigin canje-canjen da aka yi a kowane juzu’i. Sauran masu amfani da GitHub na iya duba lambar mai amfani kuma su ba da shawarar canje-canjen nasu. Wannan ma’anar tana ba da taƙaitaccen fahimta kawai. Koyaya, aikin sabis ɗin bai iyakance ga wannan ba. A cikin wannan labarin bita, za mu kalli Github dalla-dalla.

Menene GitHub da Yadda ake Farawa – Jagorar Mafari

GitHub tashar yanar gizo ce inda masu haɓakawa da masu shirye-shirye za su iya loda lambar da suka ƙirƙira kuma suyi aiki tare don inganta ta. Alamar GitHub ita ce tsarin sarrafa sigar sa mai ƙarfi. Ikon sigar tana ba masu shirye-shirye damar keɓance software ba tare da lalata software ɗin kanta ba. Canje-canjen da aka tsara za a iya haɗa su cikin sauƙi zuwa cikakkiyar fitarwa, amma sai bayan an duba duk canje-canje kuma an amince da su.
Menene Github, yadda ake amfani da shi, yadda ake ƙirƙirar aiki, sarrafawa da daidaitawa

Git da GitHub – menene bambanci, farkon sanin Git da GitHub

Menene Git?

Amsa: Tsarin sarrafa sigar sauri kuma mai ƙima . Git kyauta ce kuma buɗe tushen tsarin sarrafa bita da aka tsara don zama mai sauri da inganci ga kowane aiki, daga ƙarami zuwa babba.

Menene GitHub?

Amsa: sabis na girgije mai ƙarfi don sarrafa abubuwan haɓaka masu zaman kansu da ayyukan buɗaɗɗen tushe.

Menene babban bambanci?

Git cikakkiyar software ce a cikin nau’in tsarin sarrafa sigar, wanda aka shigar akan kwamfutar mai amfani. Git yana ba ku damar yin canje-canje ga lambar ta hanyar layin umarni (Microsoft PowerShell), kuma GitHub yana ba da damar adana ayyuka a cikin damar jama’a.

Bayanai masu ban sha’awa game da Github

  1. Matsakaicin adadin masu amfani da shafin a bara (bisa ga kididdigar ranar 24 ga Yuli, 2021) ya kasance mutane miliyan 45.
  2. A cikin 2018, Microsoft ya sayi GitHub akan dala biliyan 7.5.
  3. Akwai buɗaɗɗen ma’ajiyar git akan Github. Kowa na iya yin canje-canje gare shi. Ana samun aikin a hanyar haɗin yanar gizon – https://github.com/git/git?ref=stackshare

[taken magana id = “abin da aka makala_12723” align = “aligncenter” nisa = “751”]
Menene Github, yadda ake amfani da shi, yadda ake ƙirƙirar aiki, sarrafawa da daidaitawa GitHub misali ma’aji[/taken magana]

Github fasali

  1. Ability don haɗawa tare da shahararrun dandamali da ayyuka – Amazon, Google Cloud da Code Climate.
  2. Taimakawa fiye da harsunan shirye-shirye 200.
  3. Babban matakin ƙarfafawa da “haɗin kai”. Lokacin da mai amfani ya buga aikin su akan GitHub, sauran jama’ar shirye-shirye za su iya saukewa da kimanta aikin, ingancin lambar, da matakin haɓakarsa. Masu amfani da ɓangare na uku na iya gargaɗi mai aikin game da yiwuwar matsaloli, rikice-rikice masu canzawa, da sauransu.

Yadda GitHub ke Aiki, Fasaloli

Uku daga cikin mahimman fasalulluka na Github sune reshe, buƙatun ja, da haɗawa. Yana da daraja la’akari da kowane aiki daban.

Yin cokali mai yatsa

Ƙirƙirar aikin yana ƙirƙirar kwafi (cokali mai yatsa) wanda ke ba mai amfani damar yin gwaji kyauta ba tare da ya shafi ainihin aikin ba. Ƙirƙiri cokali mai yatsu ka ja buƙatun: https://youtu.be/nT8KGYVurIU

Ja buƙatun

Mai haɓakawa ne ke buga buƙatun ja bayan ya gama aiki akan gyara/canza lambar. A lokaci guda kuma, mai aikin da kansa zai iya sake duba canje-canjen da aka yi kuma ya yi wasu ƙarin tambayoyi.
Menene Github, yadda ake amfani da shi, yadda ake ƙirƙirar aiki, sarrafawa da daidaitawa

Haɗawa

Bayan mai shi ya amince da buƙatar ja, suna haɗa buƙatun ja kuma suyi amfani da canje-canje daga aikin cokali mai yatsu zuwa lambar tushe.

Jagora – yadda ake farawa a Github daga karce

Wannan jagorar cikakke ne ga duk masu farawa waɗanda ke fara koyon Git da Github. Matakan da ke biyowa zasu taimaka maka gina ingantaccen tsarin aiki tare da wannan software. Za ku koyi yadda ake yin canje-canje ga codebase, buɗe buƙatar ja (ƙirƙiri buƙatun ja), da haɗa lamba zuwa babban reshe. Don haka mu fara. [taken magana id = “abin da aka makala_12726” align = “aligncenter” nisa = “740”]
Menene Github, yadda ake amfani da shi, yadda ake ƙirƙirar aiki, sarrafawa da daidaitawa Dashboard lissafi na GitHub[/ taken magana]

Mataki 0 ​​Shigar Git kuma Ƙirƙiri Asusun GitHub

  1. Jeka gidan yanar gizon Git na hukuma: https://git-scm.com/downloads
  2. Danna hanyar haɗin don zazzage sigar tebur na Git don Windows kuma jira zazzagewar ta ƙare.
  3. Cire kuma gudanar da mai saka Git ta danna sau biyu fayil ɗin Git.exe. Menene Github, yadda ake amfani da shi, yadda ake ƙirƙirar aiki, sarrafawa da daidaitawa
  4. Bada izinin aikace-aikacen don yin canje-canje ga PC ta danna maɓallin “Ee” a cikin akwatin maganganu na “User Account Control” wanda ke buɗewa.
  5. Fara tsarin shigarwa Git. Karanta babban takardar lasisin Jama’a na GNU kuma danna Na gaba. Menene Github, yadda ake amfani da shi, yadda ake ƙirƙirar aiki, sarrafawa da daidaitawa
  6. Ƙayyade wurin da za a shigar da shirin, ko barin tsoffin dabi’u. Shirin zai sa ka ƙirƙiri babban fayil na Fara menu. Tsallake wannan abun.
  7. Zaɓi editan rubutu da kake son amfani da shi tare da Git. A cikin taga da aka saukar, zaɓi Notepad ++ (ko duk wani editan rubutu da kuka yi aiki da shi a baya) sannan danna “Next”. Menene Github, yadda ake amfani da shi, yadda ake ƙirƙirar aiki, sarrafawa da daidaitawa
  8. Ƙayyade suna don sabon reshen aikin. Tsohuwar ƙimar ita ce “master”. Ana ba da shawarar ku bar wannan saitin a tsoho.
  9. A cikin zaɓuɓɓuka don zaɓar PATH, abokin ciniki na SSH, takaddun sabar uwar garken, ƙarshen layi da tasha, bar komai yadda yake kuma danna maɓallin “Na gaba”.
  10. Bar duk tsoffin saitunan kuma fara shigar da shirin.
  11. Da zarar an gama shigarwa, duba akwatunan don duba bayanin kula kuma fara Git Bash. Rufe taga mai sakawa.

Kuna iya yin rajistar asusu akan Github ta amfani da hanyar haɗin yanar gizo: https://github.com/join. Don yin wannan, dole ne ku shigar da ainihin bayanan rajista da ake buƙata nan gaba don tabbatar da asusun.
Menene Github, yadda ake amfani da shi, yadda ake ƙirƙirar aiki, sarrafawa da daidaitawa

Mataki 1: Kaddamar da Git kuma ƙirƙirar ma’ajiyar gida ta farko

Git yana da nau’ikan amfani guda biyu – bash (Git Bash) da ƙirar mai amfani da hoto (Git GUI). Don fara Git Bash, buɗe menu na Fara – Windows, rubuta git bash kuma danna Shigar (ko danna hagu sau biyu akan gajeriyar hanyar shirin). Don ƙaddamar da Git GUI, buɗe menu na Fara – Windows, rubuta git gui kuma danna Shigar. A cikin yanayinmu, za mu yi amfani da Git Bash.
Menene Github, yadda ake amfani da shi, yadda ake ƙirƙirar aiki, sarrafawa da daidaitawa Ƙirƙirar sabon aiki a Git Bash ya ƙunshi amfani da umarni na musamman don fara sabon wurin ajiya. Da farko kuna buƙatar buɗe tashar Bash ta danna-dama akan tebur sannan a cikin menu mai saukarwa Git Bash Anan. A cikin taga tasha akan injin ɗin ku, ƙirƙiri sabon kundin gwaji (fayil) ta hanyar buga waɗannan abubuwa:
getrekt: Desktop getrekt $ cd ~/ Desktop
getrekt: Desktop getrekt $ mkdir myproject
getrekt: Desktop getrekt $ cd myproject/
Umurnin mkdir yana ƙirƙirar sabon babban fayil ɗin aikin gida. Ƙirƙiri wurin ajiyar Github na farko: https://youtu.be/yHCUc6cmhcc

Mataki 2. Ƙirƙiri sabon fayil a cikin ma’ajin

A cikin babban fayil ɗin aikin, ƙara sabon fayil ɗin rubutu ta amfani da umarnin taɓawa. A daidaitaccen hanya, umarnin zai ƙirƙiri fayil ɗin rubutu mara komai wanda zai sami tsawo na .txt.

Hankali! Git yana adanawa/ sarrafa canje-canje zuwa fayilolin da yake waƙa kawai. Bayan ƙirƙirar sabon fayil, mai amfani zai iya bin matsayinsa ta amfani da umarnin matsayin git. Na’urar wasan bidiyo za ta ba da jerin fayilolin da ke cikin ma’ajiyar.

Da zaran ka ƙara fayil zuwa babban fayil ɗin da ke ɗauke da ma’ajiyar git, shirin zai lura da canjin cikin aikin. Koyaya, ba za a kunna sa ido ta atomatik ba, dole ne ku yi amfani da umarni na musamman don wannan – git add.
getrekt: myproject samun $ touch getrekt.txt
samun: aikina samun $ ls
getrekt.txt

Mataki na 3: Ƙara fayil ɗin zuwa yanayin sa ido

Ƙara fayil ɗin zuwa wurin tsarawa tare da git ƙara umarni.
getrekt: myproject git ƙara . Tare da wannan umarni, shirin zai fara bin diddigin duk fayilolin da za a ƙirƙira a cikin babban fayil ɗin aikin. Kuna iya bincika idan umarnin yana aiki tare da matsayin git. Wannan shine abin da rajistan ayyukan suke yi akan layin umarni na Git Bash bayan buga matsayi na git:
getrekt: getrekt getrekt$ git status
A kan babban reshe na
farko da za a yi
Canje-canje da za a yi:
(amfani da “git rm –cached …” don cire mataki)
Sabon fayil da aka ƙara
Sabon sunan fayil: getrekt.txt
sabon fayil: getrekt.txt Shiga sharhi: Har yanzu ba a ƙaddamar da fayil ɗin ba, amma yana gab da ƙarawa.

Mataki na 4 Ƙirƙiri alkawari

Ƙaddamarwa shine wurin bincike na kowane ma’aji. A sauƙaƙe, fakitin canji wanda ke adana bayanai game da ƙara, gyara ko share fayiloli waɗanda ke adana takamaiman lamba.
getrekt:myproject getrekt $ git aikata -m “YAN UWA NA FARKO COMMIT!”
[Maigida (tushen-kwarewa) b345d9a] SANARWA NA FARKO!
1 fayil ya canza, 1 shigarwa (+)
ƙirƙirar yanayin 100644 getrekt.txt

Umarnin don ƙirƙirar ƙaddamar shine git commit -m “Commit Name”.

Hankali! Sakon da ke ƙarshen umarnin yakamata ya zama mai ma’ana kuma mai fahimta ga sauran masu haɓaka aikin. Kar a sanya sunayen ayyukanku kamar “asdfadsf” ko “foobar”. In ba haka ba, babu wanda zai fahimci wani abu, kuma za ku yi amfani da lokaci mai yawa don share su.

Mataki 5. Ƙirƙiri sabon reshe sabon reshe

Sabon reshe ne cikakken reshe na aikin, wanda ya ƙunshi duka jerin ayyukan. Yana wakiltar keɓantaccen sakin samfurin, amma a cikin tsarin sarrafa sigar. rassan suna ba mai amfani damar matsawa tsakanin “jihohin” aikin.

A cikin takaddun git na hukuma, bayanin rassan shine: “Reshe a Git kuma Github mai nuni ne mai motsi zuwa ɗayan abubuwan da aka yi ma’ajiyar.”

Misali, idan mai amfani yana son ƙara sabon shafi zuwa gidan yanar gizon su, za su iya ƙirƙirar sabon reshe don wannan shafin kawai ba tare da ya shafi babban aikin ba. Da zaran ya gama da shi, zai iya haɗa sauye-sauye daga reshensa zuwa babba. Game da sabon reshe, Git yana lura da wanda ya yi reshe daga.
Menene Github, yadda ake amfani da shi, yadda ake ƙirƙirar aiki, sarrafawa da daidaitawa Bayan aiwatar da umarnin, zaku iya buga reshen git a cikin na’ura wasan bidiyo don tabbatar da ƙirƙirar reshe:
getrekt:myproject getrekt $ git reshen
master
* sabon reshe Sunan sabon reshe tare da alamar alama yana nuna reshe na mai amfani. a halin yanzu yana kunne.

Lura: Ta hanyar tsoho, reshe na farko na kowane git repo ana kiransa “master” (kuma yawanci ana amfani dashi azaman maigidan a cikin aiki). A matsayin wani ɓangare na yaƙi da wariyar launin fata, wasu masu haɓakawa sun fara amfani da madadin sunaye don reshe na baya, kamar “primary”. Koyaya, sau da yawa fiye da a’a, masu amfani na iya ganin “master” ko makamantan sunaye da ake amfani da su don komawa gare shi.

Yana da kyau a tuna cewa kusan kowane ma’adana yana da babban reshe wanda za’a iya la’akari da sigar aikin a hukumance. Idan gidan yanar gizo ne, to reshe shine sigar da masu amfani ke gani. Idan aikace-aikace ne, to babban reshe shine sakin da masu amfani ke sanyawa a kwamfutarsu ko na’urar hannu. Wannan shine yadda sigar gargajiya ta samfuran Git da Github ke aiki. Gidan yanar gizon yana da ƙarin cikakkun bayanai game da amfani da tsoffin sunayen reshe daban-daban. Ana samun bayanin akan Github a https://github.com/github/renaming
Menene Github, yadda ake amfani da shi, yadda ake ƙirƙirar aiki, sarrafawa da daidaitawa Game da komawa zuwa reshen aikin da ƙirƙirar ayyuka da yawa, sabon reshe ba zai iya bin tsarin tsarin sarrafa sigar ba har sai mai amfani ya rubuta sa ido ta atomatik. .

Mataki 6 Ƙirƙiri Sabon Ma’ajiyar GitHub

Ba a buƙatar wannan matakin idan kawai kuna son bin lambar ku a gida. Amma idan kun yi aiki a cikin ƙungiya kuma ku karɓi canje-canje daga wasu masu shirye-shirye, to zaku iya amfani da damar GitHub na yanzu don canza lambar aikin tare. Don ƙirƙirar sabon ma’aji akan GitHub, kuna buƙatar shiga cikin tsarin kuma je zuwa babban shafin yanar gizon. Daga babban menu, danna maballin “Sabuwar Ma’ajiyar Wuta”, wanda ke ƙarƙashin alamar “+” kusa da hoton bayanin martaba a kusurwar dama ta dama na mashaya kewayawa: Bayan danna maɓallin, GitHub zai tambayi mai aikin. don suna ma’ajiyar bayanai da bayar da taƙaitaccen bayanin:
Menene Github, yadda ake amfani da shi, yadda ake ƙirƙirar aiki, sarrafawa da daidaitawa Na gaba, danna maɓallin “Ƙirƙiri wurin ajiya” don tabbatar da ƙirƙirar sabon aikin. Akwatin maganganu zai bayyana yana tambayar mai amfani idan suna so su ƙirƙiri ma’aji daga karce ko ƙara wani data kasance da aka ƙirƙira a gida. A cikin akwati na biyu, kuna buƙatar loda babban fayil ɗin aikin zuwa Github.

Hankali! Zazzage ma’ajiyar gida kuma na iya faruwa ta amfani da layin umarni, kuma musamman umarnin git remote add asalin github_url (yana ƙirƙira rikodin sabon haɗi zuwa wurin ajiyar nesa), git push -u asalin master (yana kafa haɗi tsakanin reshe a ciki). wanda mai haɓakawa yake da kuma babban reshe akan sabar nesa).

Wannan shine abin da rajistan ayyukan suke yi akan layin umarni na Git Bash:
getrekt: myproject getrekt $ git m add asalin https://github.com/cubeton/mynewrepository.git
getrekt:myproject getrekt $ git push -u asalin master
Counting abubuwa: 3, a yi.
Abubuwan rubutu: 100% (3/3), 263 bytes | 0 bytes/s, yi.
Jimlar 3 (delta 0), wanda aka sake amfani da shi 0 (delta 0)
Zuwa https://github.com/cubeton/mynewrepository.git
* [sabon reshe] master -> Babban
Babban Reshe wanda aka kafa don bin diddigin babban reshe mai nisa daga asali.

Mataki 7: Tura Reshen Aikin zuwa GitHub

An ƙirƙiri sabon reshe na aikin da ma’ajiya. Ya rage don “turawa” reshe da canja shi zuwa sabon wurin ajiyar Github. Ta wannan hanyar, membobin al’umma na ɓangare na uku za su iya ganin lambar kuma su yi canje-canje gare ta. Idan an amince da bitar, mai aikin zai iya haɗa canje-canje zuwa babban sigar aikin. Don tura canje-canje zuwa sabon reshe akan GitHub, kuna buƙatar shigar da umarnin tura git a layin umarni. GitHub zai ƙirƙiri reshe ta atomatik a cikin ma’ajiya mai nisa:
getrekt:myproject getrekt$ git push asalin sabon reshe na
ƙidaya abubuwa: 3, yi.
Matsawar Delta ta amfani da zaren har zuwa 8.
Matsawa abubuwa: 100% (2/2), yi.
Abubuwan rubutu: 100% (3/3), 313 bytes | 0 bytes/s, yi.
Jimlar 3 (delta 0), sake amfani da 0 (delta 0)
Zuwa https://github.com/cubeton/mynewrepository.git
* [sabon reshe] my-new-reshe -> my-new-reshe Bayan an sabunta shafin GitHub, mai amfani zai ga sabon reshe da aka tura cikin wurin ajiya.
Menene Github, yadda ake amfani da shi, yadda ake ƙirƙirar aiki, sarrafawa da daidaitawa

Bugu da kari

Menene ma’anar kalmar asali a cikin git tura asalin umurnin? Lokacin da mai amfani ya rufe wurin ajiya mai nisa akan injin ɗinsu na gida, git yana ƙirƙirar madaidaicin laƙabi don shi a kusan dukkan lokuta, “asalin”, wanda shine ainihin gajeriyar hanyar URL na ma’ajiyar nesa. Miƙa aiki ga GitHub: https://youtu.be/zM6z57OtR2Q

Mataki 8. Ƙirƙiri buƙatun ja na farko

Buƙatun ja (ko buƙatun ja) hanya ce ta faɗakar da masu ma’ajiyar ajiya cewa mai haɓakawa yana son yin wasu canje-canje ga lambar. Wannan shine yadda shafin da aka ƙara buƙatun ja ya yi kama da:
Menene Github, yadda ake amfani da shi, yadda ake ƙirƙirar aiki, sarrafawa da daidaitawa Wannan shine yadda ɓangaren keɓaɓɓen ke kama bayan ƙirƙirar buƙatar ja:
Menene Github, yadda ake amfani da shi, yadda ake ƙirƙirar aiki, sarrafawa da daidaitawa

Mataki 9 Haɗa buƙatar ja

Maballin “Haɗin Buƙatar Buƙatun” kore a ƙasa yana ƙirƙirar buƙatar ja. Bayan danna shi, ana ƙara canje-canjen da aka yi zuwa babban reshe na aikin.

Hankali! Share reshe bayan haɗuwa. Yawancin su na iya haifar da rudani a cikin aikin. Don share reshe, danna maɓallin “Share reshe” launin toka a cikin ƙananan kusurwar dama.

Menene Github, yadda ake amfani da shi, yadda ake ƙirƙirar aiki, sarrafawa da daidaitawa Don duba halin da ake ciki a halin yanzu, danna mahaɗin “Ƙaddamar” akan ainihin shafin farko na ma’ajiyar. Dannawa zai nuna duk jerin ayyukan da aka yi a wannan reshe. Hoton hoton yana nuna ainihin wanda aka halicce shi.
Menene Github, yadda ake amfani da shi, yadda ake ƙirƙirar aiki, sarrafawa da daidaitawa
Menene Github, yadda ake amfani da shi, yadda ake ƙirƙirar aiki, sarrafawa da daidaitawa A gefen dama akwai lambar zanta na kowane aikatawa. Lambar zanta ita ce ta musamman mai ganowa wacce za a iya amfani da ita lokacin haɗa APIs da sabis na ɓangare na uku. Hakanan zaka iya komawa zuwa takamaiman ƙaddamarwa ta lambar ID akan sigar tebur na Git Bash akan layin umarni.

Mataki 10 Mayar da Canje-canjen Github akan Injin Gida

A halin yanzu, ma’ajin da ke cikin tsarin Github ya ɗan bambanta da mai amfani da kwamfutar gida. Misali, alƙawarin da mai amfani ya yi a nasu reshen kuma ya haɗa shi zuwa babban reshen ba ya wanzu akan injin gida. Don daidaita nau’ikan ayyuka daban-daban ta atomatik, dole ne ku yi amfani da umarnin jagoran asalin git (lokacin aiki akan babban reshe) ko git pull.
getrekt:myproject getrekt $ git cire asalin master
remote: Ƙididdiga abubuwa: 1, yi.
nesa: Total 1 (delta 0), sake amfani da 0 (delta 0), sake amfani da fakitin 0
Daga https://github.com/cubeton/mynewrepository
* reshe master -> FETCH_HEAD  
23242..232433berer3444 master -> asalin/master
getrekt. txt | An canza fayil 1 +
1, saka 1 (+)Don duba halin yanzu na umarni, rubuta git log akan layin umarni. Za a lissafta duk ayyukan da aka yi.
getrekt:myproject getrekt $ git log
commit 32dgt472hf74yh7734hf747fh373hde7r3heduer73hfhf
Merge: 3fg4dd 34fg3u7j7
Author: Mtdes Ethan < getrekt@yandex.ru>
Date: Fri Sep 11 17:48:11 2015 -0400
Merge /cubeton/mynewrepository commit
44hgfh7f74hdu9jt93hf9ifejffe
Author: Mtdes Ethan < getrekt @yandex.ru>
Kwanan wata: Jumma’a 07 17: 48: 00 2021 -02356
aikata 46thf9496hf9485hkf857tg9hfj8rh4j
Haɗa: 33fh5d 3689gfh
Mawallafi: Frides @than: 06 Jan. 5: 0857 1:
33fh5d
commit 46thf9496hf9485hkf857tg9hfj8rh4j
Merge: 33fh5d 3689gfh
Author: Mtdes Ethan < getrekt@yandex.ru>
Date: Fri Jan 07 17:55:00 2021 -02356
Added some more text to my file
commit 355904-43hg940fg959hfg0g95jjgdgdfgf57i86f
Merge: 343fggdd 53efhgffddg
Author: Mtdes Ethan < getrekt@yandex.ru>
Kwanan wata: Jumma’a Jan 07 17:58:00 2021 -02356
Wannan shine alƙawarin farko na! Shirya! Yanzu mai amfani ya saba da kowane nau’in aiki a cikin tsarin sarrafa sigar. Git da GitHub koyawa don farawa kan yadda ake shigar da Git kuma farawa tare da Github, rassa, ma’ajiyar ajiya, aikatawa da sauran ra’ayoyi a cikin aikin GitHub: https://youtu.be/zZBiln_2FhM

Ƙarin fasalulluka na Github da Git

Bari mu dubi wasu “kwakwalwa” masu amfani waɗanda za su ba masu haɓaka damar sauƙaƙe aikin akan sarrafa sigar.

Rufe wurin ajiya zuwa na’ura ta gida

Jeka ma’ajiyar GitHub ku. A cikin kusurwar dama na sama sama da jerin fayiloli, buɗe menu mai buɗewa “Clone ko zazzagewa”. Kwafi URL ɗin clone HTTPS.
Menene Github, yadda ake amfani da shi, yadda ake ƙirƙirar aiki, sarrafawa da daidaitawa Komawa taga Git Bash kuma shigar da umarni:
git clone repository_url

repository_url – URL na aikin yanzu da za a rufe shi. Madadin haka, an saka url na ma’ajiyar.

A cikin misalin da ke sama, umarnin yana rufe wurin ajiya akan HTTPS. Wani zaɓi shine cloning tare da URLs akan maɓallan SSH. Don yin wannan, kuna buƙatar ƙirƙirar maɓallin SSH biyu akan Windows kuma sanya maɓallin jama’a zuwa asusun GitHub.

Nemo ma’ajiyar nisa

Bayan cloning, kwafin ma’ajin daga GitHub yakamata ya bayyana a cikin kundin aiki akan kwamfutar. Ya kamata aikin ya ƙunshi kundin adireshi mai suna da manyan fayiloli. Don canzawa zuwa gare ta, kuna buƙatar rubuta umarni mai zuwa:
cd git_project

Lura: Sauya git_project tare da ainihin sunan wurin ajiyar da aka zazzage, ko saka abubuwan da ke cikin kundin adireshi na yanzu tare da umarnin ls. Ana amfani da hanya ta biyu a lokuta inda mai amfani ba zai iya tunawa da sunan aikin ba.

Sigar tebur na GitHub – menene GitHub Desktop, babban aiki, fasali da tsarin shigarwa

GitHub Desktop aikace-aikacen tebur ne wanda ke ba da haɗin gwiwar tushen GUI tare da GitHub. Ba kamar Git ba, nau’in tebur na GitHub yana ba ku damar aiwatar da umarni iri ɗaya ta amfani da ƙirar mai amfani ta danna maballin, wanda ke sauƙaƙa aiki tare da ma’aji.

Yadda ake girka

  1. Bi hanyar haɗin yanar gizon – https://desktop.github.com/ Menene Github, yadda ake amfani da shi, yadda ake ƙirƙirar aiki, sarrafawa da daidaitawa
  2. Fara zazzage kunshin shigarwa na shirin.
  3. Danna sau biyu akan gunkin fayil ɗin da aka sauke kuma ci gaba tare da shigar da Github Desktop.
  4. Kaddamar da shirin ta cikin Fara menu.
  5. Shiga GitHub ta amfani da bayanan asusun mai amfani.

Babban ayyuka

  • Ƙirƙirar, ƙarawa da cloning ma’ajin.
  • Yin amfani da shirin don sarrafa shafukan ayyukan.
  • Yin canje-canje zuwa reshe.
  • Ƙirƙirar al’amurra, ja buƙatun da ƙaddamarwa.
  • Ability don samun dama ga farkon juzu’in sabbin samfura.

Github API

Github REST API shine keɓancewa wanda ke ba masu haɓaka damar samun damar yin amfani da bayanan Github, ayyuka, da ma’ajiyar ajiya, da kuma aika buƙatun sabar. Hanyar haɗin yanar gizon https://api.github.com/ ta ƙunshi duk URLs waɗanda za ku iya aika mafi saukin buƙatun GET:
Menene Github, yadda ake amfani da shi, yadda ake ƙirƙirar aiki, sarrafawa da daidaitawa Mafi sau da yawa, masu haɓakawa suna ƙirƙirar buƙatun a cikin yaren shirye-shiryen Python a tsarin JSON. Da farko kuna buƙatar samun mahimman bayanai game da ma’ajin daga hanyar haɗin yanar gizo – https://api.github.com/user/repos Ana shigar da ainihin bayanan cikin fayil ɗin sanyi a tsarin JSON. Ya ƙunshi manyan sigogi game da mai amfani – avatar, masu karatu, adadin ma’ajiyar ajiya, zazzagewa, da sauransu. Ana isar da wannan bayanan zuwa uwar garken.

Sarrafa da daidaita ayyukan Github Desktop

Bayan shigarwa, yin rijistar asusu, da kuma saita aikace-aikacen, mai amfani zai iya fara amfani da shirin GitHub.

Ƙirƙirar, ƙarawa da kuma rufe wurin ajiya

Don ƙirƙirar sabon ma’ajiyar, zaɓi “Fayil” kuma danna maɓallin “Ƙirƙiri wurin ajiya”. Don ƙara aikin gida, zaɓi menu na “Fayil” kuma danna maɓallin “Ƙara Ma’ajiyar Gida”. Don cloning, dole ne ka zaɓi menu “Fayil” – “majigin cloning”.
Menene Github, yadda ake amfani da shi, yadda ake ƙirƙirar aiki, sarrafawa da daidaitawa

Ƙirƙirar Sabon Reshe

Don ƙirƙirar reshen aikin daban, buɗe sashin Reshe na Yanzu kuma danna maɓallin Sabon Reshe. Mai amfani zai iya ganin reshe a cikin GitHub dubawa kuma ya yi buƙatar ja don bin canje-canje.
Menene Github, yadda ake amfani da shi, yadda ake ƙirƙirar aiki, sarrafawa da daidaitawa

Tsaro

Sigar Github na tebur da gidan yanar gizo suna ba ku damar daidaitawa da haɓaka matakin tsaro na asusun mai amfani. Ana samun duk ayyuka a sashin “tsaro saitin ajiya”. Yana da daraja la’akari da ƙarin daki-daki.

Saitin manufofin tsaro

A babban shafin ma’ajiyar ku, danna:

  • “Tsaro” – “Manufar Tsaro” – “Fara Saita”.
  • Ƙara bayani game da nau’ikan aikin ku da aka goyan baya da kuma yadda ake ba da rahoton yiwuwar lahani.

Menene Github, yadda ake amfani da shi, yadda ake ƙirƙirar aiki, sarrafawa da daidaitawa

Gudanar da Dogara

Ana samar da jadawali ta atomatik don duk ma’ajiyar jama’a, amma babu irin wannan fasalin don ma’ajiyar sirri. Jadawalin yana gano duk abubuwan dogaro mai fita kuma yana ba ku damar gano lahani a cikin aikin. Don saita jadawalin dogara, danna kan “Settings” – “Tsaro da Bincike”. Kishiyar jadawali, danna “Enable” ko “A kashe”.

Menene Github, yadda ake amfani da shi, yadda ake ƙirƙirar aiki, sarrafawa da daidaitawa

Lasisi

Github lasisi yana ba da amfani da manyan nau’ikan
lasisi guda biyu :

  1. GPL nau’in lasisi ne wanda ke ba wa sauran masu amfani damar amfani da aikin wani a wasu ayyukan buɗaɗɗen tushe. Koyaya, kamfanonin kasuwanci ba za su iya yin hakan ba.
  2. LGPL/Commons/MIT/Apache , da sauransu – mai amfani yana ba da lambar sa don amfani kyauta. Wasu za su iya samun kuɗi daga gare ta.

[taken magana id = “abin da aka makala_12364” align = “aligncenter” nisa = “698”]
Menene Github, yadda ake amfani da shi, yadda ake ƙirƙirar aiki, sarrafawa da daidaitawa Inda aka ƙayyade nau’in lasisin GitHub[/ taken] Mun sake nazarin babban aikin sabis na girgije na Github da shirin don aiki tare da wuraren ajiyar Git Bash . Mataki zuwa mataki mun yi magana game da yadda ake ƙirƙirar cikakken aiki a cikin tsarin sarrafa sigar.

info
Rate author
Add a comment