published on 17.08.2018
edited on 03.03.2022

I’ve prepared a cheap tutorial for newbies.
Git Simple Guide is so far the best git guide I’ve seen. Go, check it out.
Don’t waste your time here.
There is nothing useful here.


Well, looks like you are still here…
Start configuring git then, assuming you have already installed it.

git config --global user.name "..."
git config --global user.email "user@mail.com"

Open a dummy folder and start git bash to try it out. Create dummy files, add them, try the syntax. Check what’s going on by “git status”.

  1. First you need to initialize git.
git init
  1. Check status when you are bored.
git status

This will show you changes, e.g. deleted, renamed, modified files and the environment for those changes, working environment and staging environment.

  1. Modify a file and check the status again.

  2. Add a file

git add filename.ofcyouneedtotypetheextensionhaveyounoteverusedcommandlinebefore
  1. Check the status again

You’ll see the modified file is colored green, that’s because you moved the changes from Working Directory to the Staging Area by using git add. Congratulations! Files in staging area will be committed when you run git commit.

  1. Add all changes to the staging area

Use dot to add all changes in the current working directory instead of one specific file.

git add .

ofc, not in the whole repo. please leave this blog now, if you don’t know what dot means.
yes, leave. no one wants you here.

  1. Commit the changes
git commit -m "type-something-short-and-meaningful.please."
  1. See the commits you made
git log

wanna see something cooler? git log --all --decorate --oneline --graph


You can also add by file type. Check the example is below and notice the quotes.

git add '*.txt'

The quotes mean, look for whole working directory including sub-directories. Without the quotes git will not look for the files in sub-directories.

You can also add more than one file by using the syntax below.

git add file0 file1 file2

To all files (including sub-directories), all commands below are equivalent.

git add .
git add -A
git add *
Published on 17.08.2018 by Mert Bakır. Last update on 03.03.2022 with commit c00881b.
random
published on 17.04.2022
edited on 02.05.2022

Önceki bölümde, markdown formatını LaTeX formatına dönüştürmek için kullanılan Pandoc yazılımından bahsetmiştik. Şimdi konuyu bir adım daha ileri taşıyıp ve bookdown’a geçiyoruz. Bookdown; Rmarkdown kullanarak teknik dökümanlar, kitaplar yazabilmemizi sağlayan, Yihui Xie tarafından yazılmış …

published on 10.04.2022

I’ve been using WSL-2 on Windows for over a year. It’s very useful because some Python packages are just a headache to install on Windows. Also, docker. It’s just better on Linux. Yet, WSL-2 can also be problematic. I remember trying a dual-boot setup when things just went way too …

published on 03.03.2022

In this post, I’ll share how to install geopandas and some other gis related packages on Windows. If you are on Mac or Linux you can probably just pip install those without any issue. I usually had to do a google search every time I wanted to install these packages on Windows environment. Of …

published on 19.02.2022

Önceki yazıda LaTeX kullanmanın avantajlarından ve zorluklarından bahsetmiştim, MS Word gibi WYSIWYG programlar ile karşılaştırıp tavsiyelerimi yazmıştım. Bu yazıda Pandoc yazılımı üzerine konuşacağız. Pandoc’un da yardımıyla LaTeX’in avantajlarını alıp zorluklarını biraz geri de …

published on 12.02.2022

LaTeX bir çeşit döküman hazırlama sistemidir, ancak çoğumuzun alıştığı arayüzlerin aksine bu döküman içerisinde kod yazar gibi bazı komutlar kullanırız. Daha sonra derleyici (compiler) bu dökümanı bizim tanımladığınız kurallara göre PDF’e dönüştürür. […] 1978 yılında, Donald Knuth TeX …

published on 02.01.2022

This post is for fellow students who is studying Operations Research with CPLEX. If you don’t know already, IBM offers free academic license for IBM ILOG CPLEX Optimization Studio. […] First, you have to register IBM Academic Initiative with your academic instituion issued email. (e.g. …