From d22b3c8a15d6f100054ead971499f5f03c7a2ba8 Mon Sep 17 00:00:00 2001 From: "Jakub (james) K" Date: Tue, 22 Oct 2024 11:20:06 +0200 Subject: [PATCH] git tutorial --- Git (komendy).txt | 67 +++++++---------------------------------------- 1 file changed, 10 insertions(+), 57 deletions(-) diff --git a/Git (komendy).txt b/Git (komendy).txt index e9ab0ed..886bdb7 100644 --- a/Git (komendy).txt +++ b/Git (komendy).txt @@ -1,59 +1,12 @@ -git status -git add. +git init +git remote add priv https://token:token_name@qstack.pl:3000/c2024/projekt +git remote set-url priv https://token:token_name@qstack.pl:3000/c2024/projekt +git remote remove priv https://token:token_name@qstack.pl:3000/c2024/projekt +git remote -v +git add . git commit -git log -git remove -v -git remote remove file_name -git remote add vps -git remote add priv -git pull vps -git pull priv -git push vps git push priv -touch.gitignore - sudo nano gitignore - *.swp - *.out - - # Usefull: - docker volume create portainer_data (?) - sudo usermod -aG docker user (?) - sudo docker run --detach\ (?) - cd .. - ip r - touch .token (ukryty plik) - - - # Windows: - ipconfig - ssh mati@192.168.10.70 (-p 2233 [Port 2233]) (password: pass, passpass, passpasspass) (example of IP address) - - # Linux: - mkdir work - cd work/ - mkdir 3i - cd 3i/ - mkdir JakubK-proj - cd JakubK-proj/ - ls -l -a -R ( -a pozwala widzieć ukryte pliki, -R podkatalogi) - touch token - sudo nano token - echo $(cat token) - - # Github (priv): - git remote set-url priv https://token:$(cat token)@github.com/JJgg260/MIELSK-PASSO/lesson.git - git remote -v - git init (inicjacja) - git add . - git commit - git push priv - - # Gitlab (local): - git remote set-url local http://token:glpat-qAkxUwsR9yF2_UjVo1zK@localhost:8080/3i/test.git - git init - git remote -v - git status - git checkout -b jkukiela (zmiana branch-a) - git status - git push local - +git checkout -b nazwa_brancha +git switch nazwa_brancha +git pull priv +git log \ No newline at end of file