<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Binu Nethmi on Medium]]></title>
        <description><![CDATA[Stories by Binu Nethmi on Medium]]></description>
        <link>https://medium.com/@binu.n428?source=rss-d6cfe0170481------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*DK8iNHIBlpz7nwRuxNn12g.jpeg</url>
            <title>Stories by Binu Nethmi on Medium</title>
            <link>https://medium.com/@binu.n428?source=rss-d6cfe0170481------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Fri, 04 Dec 2026 08:56:58 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@binu.n428/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[Beginner’s Guide to SAP]]></title>
            <link>https://medium.com/@binu.n428/beginners-guide-to-sap-1a9e5ef391cb?source=rss-d6cfe0170481------2</link>
            <guid isPermaLink="false">https://medium.com/p/1a9e5ef391cb</guid>
            <category><![CDATA[sap]]></category>
            <category><![CDATA[abap]]></category>
            <category><![CDATA[sap-training]]></category>
            <dc:creator><![CDATA[Binu Nethmi]]></dc:creator>
            <pubDate>Sat, 23 May 2020 17:28:19 GMT</pubDate>
            <atom:updated>2020-05-23T17:28:19.566Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/300/1*GdgAhnzLwrpxZeaGUOqctA.jpeg" /></figure><p>I would like to teach the basics of a language that I learnt while I was in my placement year. It was new to me but was very exciting. I would be taking you all through on how to code in ABAP by developing a simple Hello World program.</p><p>Let’s cut to the chase. I’ll try my best to keep you awake .</p><h3>What is SAP?</h3><blockquote><strong>SAP</strong> stands for Systems Applications and Products in Data Processing. SAP system consists of a number of fully integrated modules, which covers virtually every aspect of business management.</blockquote><p>We can provide ERP (Enterprise Resource Planning) solutions by using SAP. The SAP uses ABAP as its core language.</p><h3>What is SAP Logon?</h3><p>You may be wondering on how to start developing a program using SAP. That’s where we have to talk about SAP Logon. <strong>SAP Logon</strong> is a locally installed program that you use to directly log on to a SAP system.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/586/1*IU_e7nnlkGyi3eNJn4HgsQ.png" /><figcaption>SAP Logon</figcaption></figure><p>You should be able to see IDS under the column <strong>Name</strong>. It’s the system we use to try new things. When we start out as a beginner, this is the system they provide us to try out our sample exercises and specifications. This would be our beginner work space to experiment and learn. When working with this system, we see many ways to do the same thing differently because it gives the exposure to try. It helped me a lot in the learning process and will help you too.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/800/1*G2RRk07WSp6a-SOZMKMrxw.jpeg" /></figure><p>Once you learn the basics, they give other systems to work on. Since those are live company systems, we have to be much more responsible with them. There are three systems that we should work on:</p><ol><li>Development</li><li>Quality</li><li>Production</li></ol><p>According to the issue, we have to choose the correct system.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/747/1*lLWPLIA2TeghAZekN-_aWg.png" /><figcaption>IDS Login Page</figcaption></figure><p>This is IDS Login Page. I’ll be explaining the code using this system.</p><p>You have to add the user name and password to log in with the credentials that the company has provided you with.</p><h3>What is a TCode?</h3><p>TCode stands for Transaction code. It is a common term used in SAP. While developing something we can’t miss using at least one TCode. Developers often use TCodes to execute certain function within SAP.</p><p>By entering the TCode into the command field on the toolbar we can jump to any screen in SAP.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/657/1*iKymLB8ZXIVMzrZ6jbPkCw.png" /><figcaption>Entering a tcode into the command field</figcaption></figure><p>There are some main TCodes that will come across for sure if you are doing a development in SAP.</p><ol><li><strong>SE11</strong>: <em>ABAP</em> <em>Dictionary Maintenance</em> (Database tables)</li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/433/1*fn0B7dsyh9UVlsZCeMkDNA.png" /><figcaption>SE11 Tcode</figcaption></figure><p>2. <strong>SE38 :</strong> <em>ABAP Editor</em> (Programs)</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/573/1*bow2xWDFqMpXGmBBriBnRw.png" /><figcaption>SE38 Tcode</figcaption></figure><p>3. <strong>SE80</strong> : <em>Object Navigator</em></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/296/1*kbXJYdSrk7S9zeeXycRuOA.png" /><figcaption>SE80 Tcode</figcaption></figure><p>4. <strong>SE37</strong> : <em>ABAP Function Modules</em></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/446/1*zXHW1nncbGkeweZjF-igMQ.png" /><figcaption>SE37 Tcode</figcaption></figure><p>I have listed the most important TCodes for your reference. You can find the TCodes and what it is for from the link given below.</p><p><a href="https://sapbrainsonline.com/abap-tutorial/abap-transaction-codes-list.html">List of SAP Transaction codes for ABAP Development</a></p><p>I just gave an overall simple explanation about SAP and the main points that will surely come across when coding a new program.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/640/1*EdUtohwgoG-5raMr6SlenQ.png" /></figure><h3>Create a new program (SE38)</h3><p>After successfully logging into the IDS, the first thing you have to do is to create a program. For that you have to go to the <strong><em>ABAP </em>Editor</strong> screen. The TCode that directs you to the <em>ABAP</em><strong><em> </em></strong>Editor screen is <strong>SE38.</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/587/1*t1pSVaklMox-J6oP6v5JTQ.png" /><figcaption>SE38 — ABAP Editor</figcaption></figure><p>Giving a meaningful name for your program helps you to identify a certain program. This is a good practice to follow for every program you write.</p><ul><li>You may wonder what’s with the ‘Z’ at the very beginning of the program name. It’s how SAP indicates our custom programs. Standard programs don’t have ‘Z’ at the beginning.</li></ul><p>Time to learn more about SE38.</p><h4>How to find an existing program code?</h4><p>There’s no trouble if you remember the name of the program that you want to search. But think about forgetting the name of a program. As coders , it happens all the time .</p><p>SAP provides a solution for that. Let’s see what that is.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/518/1*3VG1tMxy7Ckx_mMPOu1uEQ.png" /><figcaption>SE38 — Searching a program</figcaption></figure><p>As the screenshot given above, you can type the first letter you remember. In our case its ‘Z’ .</p><p>Type ‘*’ next to the letter in the program name input field. Next click on the search option icon in the corner of the program input field.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/842/1*l-eR4iMZjYQOOQwn67wmoA.png" /><figcaption>Search options</figcaption></figure><p>You can find all the programs starts with ‘Z’ and you can find the required program from that list.</p><h4>Display option in SE38</h4><p>If we want to display an existing program, type the program name and click on the ‘Display’ button.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/919/1*_FrLrM-x52tO07e3KoEgnA.png" /><figcaption>SE38 Display option</figcaption></figure><p>We can refer and understand other programs by using this option.</p><h4>Change option in SE38</h4><p>If we want to change an existing program, we can click on the given below icon.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/468/1*tVZuGeKcjsxvh-dp77bhiQ.png" /><figcaption>Change icon</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/904/1*0iTTR-nUwJC08LLZS5aJyQ.png" /><figcaption>Changing a program code</figcaption></figure><p>Now you can change the code.</p><p>There’s another option.</p><p>Like we did in display option, type the program name in SE38 and click on the change option. It directly gives the chance to change the program. Same thing happens both ways. Use the better option accordingly.</p><ul><li>It’s better to go with the ‘Display’ option unless otherwise you were told to change someone’s program. It can prevent accidental changes happening in someones code. So, better to use ‘Display’ option when you are studying someones code.</li></ul><h4>Create option in SE38</h4><p>If we want to create a new program , type the program name and click on the ‘Create’ button in SE38.</p><p><strong>Let’s create our new program.</strong></p><p>When you initially creating a program, the given window below will pop.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/609/1*XfQBWbpn8ZIFDV9QLBJYgQ.png" /><figcaption>Program Attribute window</figcaption></figure><p>In this window you have to add the attributes that are needed to be included to your program. In here we have given a title, type and a status.</p><p>Now Save it.</p><p>Next, we have to save our program in a package.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/453/1*lQU7ZyaE5lvm3SLIl-sE6w.png" /><figcaption>Saving to a local Object</figcaption></figure><p>We can save the program in a local object or we can save it in our own package.</p><p>If you are saving this in a <strong>local object</strong> you have to use $TMP and click on the Local Object button.</p><p>If you are saving the program in your <strong>own package, </strong>then you have to add that package name into the package input field and save it using the save icon button.</p><h4><strong>How to create a custom package?</strong></h4><p>We have to use SE80 tcode (Object Navigator screen) to create our package.</p><p>Let’s say our package name is ‘ZPAC1’</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/395/1*_37B9BT76ZWh_jKHJKpYvA.png" /><figcaption>Create Package in SE80</figcaption></figure><p>After clicking ‘Yes’, you have to add a short description in the package details pop up window.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/662/1*oF3iEL9ybgSVTpOq4NeWFA.png" /><figcaption>Add Package details</figcaption></figure><p>After saving it, it directs to the workbench request pop up window.</p><h4>What is a transport requests (TR)?</h4><p>Transport requests (TR) are like containers which store the changes that are made in the development system. It also records the information regarding the type of change, the purpose of transport, request category and the target system. Every TR contains one or more change tasks.</p><p>What it does is it helps us to transport our changes to Quality or Production systems.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/497/1*_W2CNhJvHMfcu-RFWzBkHQ.png" /><figcaption>Creating a TR</figcaption></figure><p>After clicking on the Create Request button you can create your own TR.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/593/1*3yzc1ZhgbDNDf6qkuqCMmQ.png" /><figcaption>Adding TR details</figcaption></figure><p>Add a description in your TR details and save it. Adding a project is optional.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/494/1*1JiQ5d27AOGrvFg-_nT8xg.png" /><figcaption>Newly created TR</figcaption></figure><p>You can see there is request number. In our example its IDSK901787 . It has a standard format <strong>&lt;SID&gt;K&lt;Number&gt;</strong></p><ul><li><strong>SID</strong> — System ID</li><li><strong>K</strong> — Is fixed keyword/alphabet</li><li><strong>Number</strong> — can be anything from a range starting with 900001</li></ul><p>Now you have your own TR. Click on the tick.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/392/1*FQuuDxVeeLeNCT2hNwxJDQ.png" /><figcaption>SE80- New Package</figcaption></figure><p>Now we have our own package.</p><p>We can go and check whether we have created our TR successfully.</p><h4>How to Display TR?</h4><p>We use SE01 (Transport Orgamizer Screen)to display TRs.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/581/1*KK0GCP1-09kxEiw25JBo0g.png" /><figcaption>SE01- Display TRs</figcaption></figure><p>By adding the request number and clicking on the display button , you can display the TR.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/560/1*CW1g1v0xvfS0mgk0Sf-9_g.png" /><figcaption>SE01- Expanded view of a TR</figcaption></figure><p>In here you can see our package has been included to the TR which we created just now.</p><p>Let’s say you want to edit the description of your TR.</p><h4>How to edit the TR description?</h4><p>Double click on the description .</p><p>It will direct to the window given below and in properties we can do the change.</p><p>Click on the change icon (the pencil).</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/637/1*c3uQt_SBQfj_doui-EaGhQ.png" /><figcaption>SE01- Changing the request details in properties</figcaption></figure><p>Add the description and save it. (Ctrl+s).</p><p>If you go back, you can see the new description in the TR description.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/570/1*E-D1Y9kQXfWKaMmpqzoljg.png" /><figcaption>SE01-After the description change in properties</figcaption></figure><p>Let’s go to the very beginning where all of this started. We wanted to create a package and we have our package in our hand now. Let’s continue.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/446/1*kFVD0MJjNCLjo0Rec8AFCA.png" /><figcaption>Saving our program in our package</figcaption></figure><p>Add the package name and save it .</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/498/1*qYbUDoPGEsDIkvH39BKg6g.png" /><figcaption>TR</figcaption></figure><p>It asks about our TR again.See whether it’s the correct one .</p><p>If it’s yours, click on the tick. If not, go and create a new TR for your change and save the changes in that TR.</p><p>Now we have created our new program.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/710/1*PrWkK7VNDx5fv8yhYnAZgQ.png" /><figcaption>SE38-New Program</figcaption></figure><p>This is where we have to write our code.</p><p>Let’s just write a code to display “Hello World”.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/704/1*egRugR1G63apWiVzY3KrzA.png" /><figcaption>SE38- ‘Hello World’ write statement</figcaption></figure><p>It’s just a write statement. We use single quotation to represent a string. We have to end a statement using a full stop.</p><p>Before executing we have to follow three steps.</p><ol><li>Check syntax</li><li>Save</li><li>Activate</li></ol><p><strong>1)Check syntax</strong></p><p>We check for syntax errors.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/674/1*Wxy8pMaR4uaDubP6LWVTVg.png" /><figcaption>Check for syntax errors</figcaption></figure><p>By clicking the check icon (Ctrl+F2) you can check for syntax errors</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/332/1*VPal8My2Og-o_BE9zn5QWA.png" /><figcaption>Output after checking syntax errors</figcaption></figure><p>In our case there are no errors.</p><p><strong>2)Save</strong></p><p>Using save icon or (Ctrl+s) we can save the program.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/260/1*LKQVZwcL7nTzA-f-ocisrA.png" /><figcaption>Output after saving</figcaption></figure><p>We successfully saved our program.</p><p><strong>3)Activate</strong></p><p>We can’t execute if the code is not activated.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/687/1*mtYUgAwCAeTvwRWIWqVJsg.png" /><figcaption>Activate a program</figcaption></figure><p>Select the correct program in the given below window and click on the tick to activate.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/890/1*o5jUP7aMG-y9fxYl3r1nUg.png" /><figcaption>Inactivate Objects list</figcaption></figure><p>The Program got activated successfully.</p><p>When you’re familiar with SAP, what you do is you directly activate and execute the program. If there are no errors it’s easier . But say there’s an error .We have to go one by one to see what happened. So, as beginners follow the above order. Don’t use rabbit jumps .</p><p>Now it’s time to execute and display Hello World.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/687/1*VamlrkM2cmQvSAJDJX6Gxw.png" /><figcaption>Execute the program</figcaption></figure><p>Click on this icon or press (f8) to execute.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/342/1*lq80llcYO4u92Kkpv9ADHQ.png" /><figcaption>Output</figcaption></figure><p>We successfully displayed Hello World.</p><p>You have created your first SAP ABAP program.Great job!! Cheers!!!</p><p>There are some points that I would like to cover. I think these will give you some additional knowledge.</p><p>Let’s begin.</p><p>Can you remember we created our new package ‘ZPAC1’ using SE80?</p><p>We can create many more using SE80. Not only packages. It’s like a root.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/584/1*_wvb7q8IqcKK4_f6rpLHVQ.png" /><figcaption>SE80-Object Navigator</figcaption></figure><p>Like this, we can create a program in our package using SE80.</p><p>We have another way to create a program using SE80. We can directly create a program. Let’s see how.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/387/1*joCIWXpCxiyMXIO7x-MNmA.png" /><figcaption>Se80-Creating a program</figcaption></figure><p>After typing the name of your new program and pressing enter, you can create directly.</p><ul><li>But if we want to create a program, we go for SE38 because we are used to follow that path.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/360/1*H0JQJ_69N9GYKb_nqyqXFg.png" /><figcaption>SE80-List of the things that we can create</figcaption></figure><p>We can use SE80 to create whatever in this given above list.</p><h4>How to get the object list in SE38?</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/705/1*-XLmhvE-mP1j0uVG_w9QFA.png" /><figcaption>Display Object List icon</figcaption></figure><p>If we click on that icon, you can see , we get the chance to work on our program parallel with the object list.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/872/1*yHxBtJ113RCTNiHzq0j-tQ.png" /><figcaption>Display Object list</figcaption></figure><p>If you want to check whether all the changes you’ve been doing have attached to the TR you created, you go for SE01. Let’s go and check in SE01.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/564/1*7Sr8SOYstcxH0aX5SQngUg.png" /><figcaption>SE01- Expanded TR with tasks</figcaption></figure><p>Yes. The package and the program are attached to our TR successfully.</p><h4>How to find the TR number if forgotten?</h4><p>Go to SE01 .</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/655/1*DuE43jf8B14c5RWHGi_Wgw.png" /><figcaption>SE01-Transport Organizer</figcaption></figure><p>In here, if you were unable to remember the TR number you just created, it has to be in Modifiable request stage because you were modifying the code minutes ago.</p><p>So, tick Modifiable and click on Display button.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/628/1*vcI2Sbw69uTULpy9vVqyjA.png" /><figcaption>SE01-Modifiable TR List</figcaption></figure><p>There you can find all the modifiable TRs and you can get your TR number.</p><ul><li>If you want to find out the released TRs, you tick the Release status and click on the Display button. It will give you all the Released TRs.</li></ul><p>You are awesome!! You have reached the end of this article without giving up. CHEERS!!</p><p>That’s all for now . Hope you could get the most out of it.</p><p>I wanted to cover up the environment briefly as possible, while walking towards the destination “<strong>Writing a simple ‘Hello World’ program</strong>” .</p><p>See you in the next article!</p><p>Thank you , Have a great day and stay safe!</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=1a9e5ef391cb" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Beginner’s Guide to GIT]]></title>
            <link>https://medium.com/@binu.n428/beginners-guide-to-git-95d4aa993576?source=rss-d6cfe0170481------2</link>
            <guid isPermaLink="false">https://medium.com/p/95d4aa993576</guid>
            <dc:creator><![CDATA[Binu Nethmi]]></dc:creator>
            <pubDate>Thu, 07 May 2020 17:37:54 GMT</pubDate>
            <atom:updated>2020-05-07T17:43:25.814Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*mtsk3fQ_BRemFidhkel3dA.png" /></figure><p>This article is the first of many more to come. I was introduced to GIT when i was preparing for my internship interviews and i found it very fascinating on how it could be used to manage projects when working on a team. This article is mainly aimed at the basics which i learnt and how i use it to manage my personal projects.</p><h3><strong>What is Git?</strong></h3><p>Git is officially a distributed <strong>version control system</strong> (VCS). It allows to track the changes in an application, a folder or a single file.</p><p>Let’s imagine you are working on a report. Having thought that, this is the final one you are planning to submit a file which you think you have concluded properly and you save it. But while reading, you notice some changes that are still there and you have to change them. Likewise, you do lots of changes before submitting and that may cause to have many versions only for that single file.</p><p>You can somehow manage since it’s only you who works on it and you know about the things that you have been doing. But think about a group project where multiple people are working and has dozens of files. Making changes and trying things out can be risky for scenarios like that because it can affect every component in that project.</p><h3>Why Git is important?</h3><p>By using Git , developers can try new features and decide whether to include or not by examining the execution process. If they are not happy with any change, they can remove it by searching the commit. That’s why GIT is important. It keeps <strong>track of every change</strong> along with the details of the person involved and can remove those changes easily .</p><h3>How to download Git?</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/576/1*55vFWxJ_-u0jsZdaWtTxXQ.png" /><figcaption>Git download page</figcaption></figure><p>You can download the latest version of git from the following link.</p><p><a href="https://git-scm.com/downloads">https://git-scm.com/downloads</a></p><p>Select the correct Operating System you work on and download it. Along with that we have to use the terminal<strong>.</strong></p><p>If your using a <strong><em>MAC</em></strong> or <strong><em>LINUX</em></strong> machine use the default Bash terminal which is pre-installed in the machine.</p><p>If your using <strong><em>WINDOWS</em></strong> use its built-in-PowerShell or GIT Bash terminal which comes with Git.</p><p>The next step to do is configure Git.</p><pre>git config --global user.name &quot;Your Git Username&quot;</pre><pre>git config --global user.email &quot;yourgmail.com&quot;</pre><p>We config this only to track the details of the person who did changes. We don&#39;t use this anywhere for logging purposes.</p><h3>Repositories</h3><p>Repositories are the <strong>containers </strong>for GIT. Anytime you want to use GIT on a single file or a project initialising a repository is required.</p><h4><em>Initialising a repository</em></h4><pre>git init</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/554/1*W2x0Z4S1ZDumomSsLhqW2w.png" /><figcaption>Git Bash — <em>Initialising a repository</em></figcaption></figure><p><strong>Display the hidden files and folders</strong></p><pre>ls -a</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/478/1*mbeoDfl7-xesIsxY_GhtQg.png" /><figcaption>Git Bash — Display the hidden files and folders</figcaption></figure><p><strong>. git</strong> folder is created by Git . It stores all the information about the Repository.</p><p><strong>Check the status of the Repository</strong></p><pre>git status</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/561/1*9RmPldYUevxwzWHjr-Skjg.png" /><figcaption>Git Bash — Check the status of the Repository</figcaption></figure><p>Whoa! “There’s no changes to commit. Do something! Create or copy!!</p><h3>Let’s start!</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/624/1*Gw8MSzvjHiwPNUineYeIpQ.png" /><figcaption>Git Bash — <em>Create a new file</em></figcaption></figure><p>If we want to commit just after home.html there are <strong>two steps</strong> which has to follow <strong>for committing</strong>.</p><p>1. We have to <strong>decide the files</strong> that are needed to be changed along with the changes</p><p>2. Those needed to be <strong>added to the staging area</strong> and from the staging area we commit.</p><p>When it’s a large project there can be many changes across dozens of files and we might want to make a smaller commit only on a .css files that changed.</p><p>So, you add the .css files that changed and then commit those files selectively.</p><p><strong>Add files to the staging area</strong></p><pre>git add</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/624/1*5cQ5VayKXsBzXlgiY7QtIQ.png" /><figcaption>Git Bash — <em>Add files to the staging area</em></figcaption></figure><p>Now we can commit. There are couple of ways to commit. The simplest way is given below.</p><p><strong>Message flag commits</strong></p><pre>git commit -m &quot;message&quot;</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/615/1*8NjEtcb5tiy8rf6LKqDsHw.png" /><figcaption>Git Bash — <em>Message flag commits</em></figcaption></figure><p>Whatever string you pass will be associated with that commit. message in quotes has to explain what you are committing, the content, the reason why you are making a commit.</p><p><strong>Display the history of commits</strong></p><pre>git log</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/624/1*8pDuinw3DCnnLuPLmNgZRg.png" /><figcaption>Git Bash — <em>Display the history of commits</em></figcaption></figure><h4><em>Example</em></h4><p>There are three files.</p><p>1. home.html</p><p>2. app.js</p><p>3. stylesheet.css</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/624/1*R-K3cT5sSSgpDy_aws5nXA.png" /><figcaption>Git Bash — Create app.js and stylesheet.css</figcaption></figure><p>You can use these simple codes for try outs</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/529/1*MyasSF2N6yaiwxjTeduWFA.png" /><figcaption>Home.html code</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/469/1*1mjCY2ibYpVjYcNiE5iPVQ.png" /><figcaption>app.js code</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/576/1*zkHFXNg6x2ITW_xDHjQlJA.png" /><figcaption>app.js output</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/249/1*ZEjUSjaJGmZzCUaDGNQ8qQ.png" /><figcaption>home.html output</figcaption></figure><p>If we look at the status,</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/624/1*4Cx_4h342eITRRzDGLUhYg.png" /><figcaption>Git Bash — Checking the current status</figcaption></figure><p>There are two different things.</p><p>1. One file that was <strong>modified</strong>. (home.html)</p><p>2. Two files are <strong>untracked</strong> completely. (app.js, stylesheet.css)</p><p>We’ll group two of these files (home.html, app.js) and use the other one (stylesheet.css) later.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/624/1*iPCQU5mHPPFUuOkItGuxFQ.png" /><figcaption>Git Bash — <em>Add app.js and home.html to the staging area and checking status</em></figcaption></figure><p>It says this is going to be your next commit if you were to commit right now. Let’s add a commit.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/624/1*2wxKisw1VABRW6g2KOztSQ.png" /><figcaption>Git Bash — <em>Add a commit and checking the log</em></figcaption></figure><p>Let’s go to our stylesheet.css file and do some changes.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/512/1*z0lBK4QiZRO1o3oUCzlXig.png" /><figcaption>Home.html code — Added the stylesheet</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/252/1*djfacGf_n3WfzUDkVRj1Xw.png" /><figcaption>Stylesheet.css code</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/485/1*4VmYLxk4e3SaJKskW5rKQA.png" /><figcaption>home.html output</figcaption></figure><p>You did a change. Now it’s time to commit.</p><p><strong>Add all the changed files to the staging area</strong></p><pre>git add .</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/624/1*o9NjHBeiOQa-9Jz338M_eQ.png" /><figcaption>Git Bash — <em>Add all the changed files to the staging area</em></figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/624/1*tO8qj5N1LX0IVTp3N7AYTw.png" /><figcaption>Git Bash— add commits</figcaption></figure><p>Let’s do another small change in stylesheet.css file. Let’s change the background colour in both body and the heading 1.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/298/1*kgtO9Hu3jbpErj5-MU-Uxg.png" /><figcaption>Stylesheet.css code</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/624/1*G_Of_FQZcNA8qpEOVeB_Og.png" /><figcaption>Home.html output</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/624/1*hxjC_ZCC3qBD3YkrXzrg5g.png" /><figcaption>Git Bash — Checking the status</figcaption></figure><p>Since you made a change , you have to commit now.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/581/1*XTbKkzoapZgxw4M-NejhhQ.png" /><figcaption>Git Bash — Add all to the statging area and commit</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/624/1*7hW43adhTBnLZrPHMIpfUQ.png" /><figcaption>Git Bash — Checking the log</figcaption></figure><h4>Why do we need commits?</h4><p>It’s not just to have a log of what you did. We can also go back at any point and start over.</p><p>Let’s say you want to remove the colour change.</p><p><strong>Checking out to commit</strong></p><pre>git checkout &lt;commit-hash&gt;</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/624/1*bHHrSyUY-WqW85X85bWNiw.png" /><figcaption>Git Bash — Commit-hash</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/624/1*ylu6eUEiZlvZBvfwrtFtZw.png" /><figcaption>Git Bash — Checking out</figcaption></figure><p>By adding the actual hash for the specific commit that you want to visit, which is listed in git log, you can check out.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/624/1*7VOhDu097CXkGXOAS7HmBQ.png" /><figcaption>home.html output</figcaption></figure><p>By looking at the home.html output you can see , it has the previous colour.</p><p>We can even go to the very beginning of our code .</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/624/1*utlMMDmvfRvqHr3sSo4JqA.png" /><figcaption>Git Bash — Commit hash of the first commit</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/624/1*46-LP_NUqp3VoRtjmdHadw.png" /><figcaption>Git Bash — Checking out</figcaption></figure><p>Go back and see the home.html. Home.html code is empty. There’s nothing to see if we refresh home.html</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/624/1*7Bd1PYHdXbGRjw7D0nmImw.png" /><figcaption>Home.html output</figcaption></figure><p>We probably don’t go back to the very beginning, but It’s cool if you can do that.</p><h3>Branches</h3><p>A <strong>branch</strong> is an individual timeline of our project commit. These are alternative environments that we can track parallelly without making changes to main branch of the projects that everybody else are working. We can play with the code by adding new features and do experiments as we wish in our own separate branch. The official stable version of our project code, the main branch, the <strong>master</strong> branch.</p><p>By default, all the commits are saved in the master branch.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/624/1*pSFskob0GYM9esCNGLmmvQ.png" /><figcaption>Git Bash— Checking the status to find out the brach we’ve been working on</figcaption></figure><p><strong>List all branches</strong></p><pre>git branch</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/624/1*JJJNSzwfGcqEfQMEALyjOw.png" /><figcaption>Git Bash — current branch</figcaption></figure><p>This command <strong>will not</strong> make branches</p><p>The <strong>*</strong> tells us that you are currently on a different branch called “HEAD detached at e91998d”</p><p>(e91998d -the commit)</p><p>So, whenever we go back with “git checkout” like we just did to look at some other commit, an older version of our code, we are taking off from master branch.</p><p>We can go back to the master branch with the same command “git checkout”</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/624/1*VSAjEvIyYlqxwFqlzBkQcQ.png" /><figcaption>Git Bash — Switching to master branch</figcaption></figure><p>If you go back and see your code, you can notice that the code is back again. Refresh!!</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/624/1*6bwCiu9cBeUhVeqU1s3neg.png" /><figcaption>Home.html output</figcaption></figure><p><strong>Create your own new branch</strong></p><pre>git branch &lt;branch name&gt;</pre><p>If you don’t provide a name it’s just going to list the branches.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/624/1*c8Oz70qswHU9i1uJ4ZckXQ.png" /><figcaption>Git Bash— Create a new branch and listing</figcaption></figure><p>Our newly created branch is listed in here.</p><p>If we want to checkout like we did before,</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/624/1*TC6SacJcOQV17L3R5hX1QA.png" /><figcaption>Git Bash— Switching to the new branch</figcaption></figure><p>Nothing will change in the code. All we’ve done is move over from one timeline to another. (master -&gt; colorchange)</p><p>Even we are now in our own branch “colorchange”, we still at the same commit, we’ve just moved over.</p><p>Let’s do a change now!</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/624/1*4S43APPPZRAWWus-lvQD5Q.png" /><figcaption>home.html output after doing some small changes</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/624/1*YdPLVhElSp-a085qTG_Qkw.png" /><figcaption>Git Bash— Checking the status</figcaption></figure><p>We can see the two files that I changed, home.html and style.css. The untracked ones are the pictures that I used.</p><p>Let’s add everything to commit.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/624/1*UQ5Op8AOKBuC4HJeKdC1AQ.png" /><figcaption>Git Bash — Add everything to staging area and commit</figcaption></figure><p>We are working on our changecolor branch. Let’s have a look at our master branch to see what happened.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/624/1*oathLuK19U4HsVN1sXi6bg.png" /><figcaption>Git Bash— Checking the log</figcaption></figure><p>It doesn’t say anything about the changecolor or the last commit that I created which was “Background change”.</p><p>That’s not here because that was in a different timeline, So, I didn’t impact my original timeline master. And if I refresh,</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/624/1*Y7_xq9aZeUs3YCZ9dgZn6Q.png" /><figcaption>Home.html output</figcaption></figure><p>We are back to the previous one.</p><p>We can discuss and see whether we can adopt this to our master branch or not and continue with the conclusion of that discussion. If it’s your own project, you can do whatever you prefer. Just try new things. If you are happy with them, go with it. But when it comes to group projects, everyone’s opinion is required.</p><p>Let’s say your team liked what you have changed and they want that to be merged to the master branch.</p><p><strong>Add the change to the master branch</strong></p><pre>git merge &lt;branch name&gt;</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/624/1*o45p-C5F7A7ssFYbkoC-Nw.png" /><figcaption>Git Bash— Checking the log after the merge</figcaption></figure><p>You can see I now have that commit. We are still on master but now I have that code and all the commits that came from my background change branch.</p><p>And finally Refresh and see whether the change is there.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/624/1*zYhYVVZYSQ84t9Zq--iKIA.png" /><figcaption>Home.html output</figcaption></figure><p>Yes, it’s there. The change has been merged to the master branch successfully.</p><p>That’s all for this article . Great work!! Cheers!! Now you can relax a bit.</p><p>But this is just a basic intro . We have so much to learn about Git.</p><p>See you in the next article!</p><p>Thank you , Have a great day and stay safe!</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=95d4aa993576" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>