<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Joel Raphael Ogwai Odira </title>
    <description>The latest articles on DEV Community by Joel Raphael Ogwai Odira  (@ogwaiodira).</description>
    <link>https://dev.to/ogwaiodira</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F4070914%2Fee5b2f5b-c6fc-4298-ab90-bf4eb6845820.jpg</url>
      <title>DEV Community: Joel Raphael Ogwai Odira </title>
      <link>https://dev.to/ogwaiodira</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/ogwaiodira"/>
    <language>en</language>
    <item>
      <title>Getting Started with Excel for Data Analytics: From Basics to Data Cleaning.</title>
      <dc:creator>Joel Raphael Ogwai Odira </dc:creator>
      <pubDate>Thu, 03 Sep 2026 10:06:24 +0000</pubDate>
      <link>https://dev.to/ogwaiodira/getting-started-with-excel-for-data-analytics-from-basics-to-data-cleaning-a2</link>
      <guid>https://dev.to/ogwaiodira/getting-started-with-excel-for-data-analytics-from-basics-to-data-cleaning-a2</guid>
      <description>&lt;h2&gt;
  
  
  Introduction
&lt;/h2&gt;

&lt;p&gt;The pursuit of social, economic or even spiritual endeavours involve a continuous cycle of decision making. We rely on data to make these decisions, however negligible the data may seem.&lt;/p&gt;

&lt;p&gt;We are usually presented with raw data, take for example a local government authority collecting population data to help determine appropriate development programmes. They will likely be presented with a general count of people, raw data, which isn't useful unless processed, presented meaningfully and used to advise. This brings us the concept of excel and data analytics.&lt;/p&gt;

&lt;p&gt;We will sequentially look at three core concepts.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Excel&lt;/li&gt;
&lt;li&gt;Data Cleaning&lt;/li&gt;
&lt;li&gt;Data Analytics&lt;/li&gt;
&lt;/ol&gt;

&lt;h2&gt;
  
  
  Excel
&lt;/h2&gt;

&lt;p&gt;Excel is a spreadsheet application that automates data processing. It's the most basic tool and allows storage and manipulation of data.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fh4r4rep9hwhe2v81qt43.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fh4r4rep9hwhe2v81qt43.png" alt="Blank or new excel file" width="800" height="429"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Structure&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;A grid based interface of columns labelled alphabetically and rows labelled numerically.&lt;/li&gt;
&lt;li&gt;Cells are individual rectangular boxes containing data and are cross-referenced with the rows and columns e.g cell B2 being at the intersection of column B and row 2.&lt;/li&gt;
&lt;li&gt;The ribbon, at the top of an excel window. It contains tabs such as Home, Data and formulas with nested and grouped tools and commands.&lt;/li&gt;
&lt;li&gt;Formula bar, the long horizontal bar above the grid. It displays the currently selected cell and it's contents including formulas. You can directly input formulas in this bar.&lt;/li&gt;
&lt;li&gt;Name box adjacent and left of the formular bar displays your current cell.&lt;/li&gt;
&lt;li&gt;Worksheets which are displayed at the bottom of the grid and are basically pages within an excel document.&lt;/li&gt;
&lt;li&gt;Quick access toolbar at the top left of the window provides shortcuts to save, undo and redo actions.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Core functions.&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Data cleaning&lt;/li&gt;
&lt;li&gt;Formulas and functions&lt;/li&gt;
&lt;li&gt;Pivot tables&lt;/li&gt;
&lt;li&gt;Data visualisation&lt;/li&gt;
&lt;li&gt;What if analysis&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Data cleaning
&lt;/h2&gt;

&lt;p&gt;Presented with raw data, users need to ensure the integrity and accuracy of data to make it meaningful.&lt;/p&gt;

&lt;p&gt;One important step in cleaning is to ensure your data set has headers. This sets parameters for you when you start inspecting the data set.&lt;br&gt;
In a large data set, you can use freeze panes. Excel freezes columns and panes on top and to the left of your active cell.&lt;/p&gt;

&lt;p&gt;It keeps the frozen columns and rows constant regardless of where you're scrolling in the dataset. &lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Data validation&lt;/strong&gt;&lt;br&gt;
This ensures only certain type of data is allowed in columns. You could set this to text only or numbers only for example.&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;&lt;em&gt;Data validation works best when set before data collection, else it only restricts further data types if data exists already.&lt;/em&gt;&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;Where data exists already, you use sort and filter tab to view the data items in each column and clean. In a  dataset with gender columns for example, You'd need to ensure you don't have Female and F representing the same thing, or Male and M.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fwrbug8knnd0ega3b47kh.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fwrbug8knnd0ega3b47kh.png" alt="sample filter function in a column" width="475" height="683"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;The numbers tab under home tab allows you to format data in each column and standardise. Take a date column for example. In uncleaned data, you'd have dates entered in various formats like DD/MM/YY, YY/MM/DD, DD/MONTH/YEAR etc.&lt;/p&gt;

&lt;p&gt;The numbers tab gives you freedom to set columns into text only, standardised date format, specific currency etc.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Flqhiopmc0l89f0xx360d.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Flqhiopmc0l89f0xx360d.png" alt="Numbers tab" width="690" height="632"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Duplicates&lt;/strong&gt;&lt;br&gt;
Duplicates can be removed from the &lt;strong&gt;&lt;em&gt;Data tab&lt;/em&gt;&lt;/strong&gt;. You can select columns and ensure only unique data exists.&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;Exercise with caution to avoid unnecessarily removing valid data. Two items may have a duplicate in one column while everything else varies in other columns making each a unique item.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;&lt;strong&gt;TRIM&lt;/strong&gt;&lt;br&gt;
The &lt;code&gt;=TRIM()&lt;/code&gt; removes unwanted spaces in a text string, whether leading, trailing or in between text.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Case sensitivity&lt;/strong&gt;&lt;br&gt;
You can ensure all uppercase, first letter uppercase or all lowercase using &lt;code&gt;=UPPER()&lt;/code&gt; &lt;code&gt;=PROPER()&lt;/code&gt; and &lt;code&gt;=LOWER()&lt;/code&gt; respectively.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;&lt;code&gt;=CLEAN()&lt;/code&gt;&lt;/strong&gt;&lt;br&gt;
This removes unwanted characters especially where data was imported. Should also be used cautiously to avoid unintentionally excluding valid data.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Extracting and splitting&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;Text to columns found in the data tab and splits text strings in a column into different columns e.g. when you need First and second names separately.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;code&gt;=LEFT()&lt;/code&gt; &lt;code&gt;=RIGHT()&lt;/code&gt; &lt;code&gt;=MID()&lt;/code&gt; allows you to extract characters in a cell depending on position, for example, &lt;code&gt;=RIGHT(B4, 3)&lt;/code&gt; gives us &lt;em&gt;ent&lt;/em&gt; as in the example below.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F2f53588ra59nkm5e00s9.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F2f53588ra59nkm5e00s9.png" alt="TRIM SAMPLE" width="465" height="122"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;code&gt;CONCAT&lt;/code&gt; allows us to combine text strings. See example below.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fihqikt6wrgmnletdfhs3.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fihqikt6wrgmnletdfhs3.png" alt="CONCAT sample" width="740" height="140"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;FIND AND REPLACE&lt;/strong&gt;&lt;br&gt;
Allows quick location of specific items and replacement with a standardized value.&lt;/p&gt;

&lt;h2&gt;
  
  
  Data analytics
&lt;/h2&gt;

&lt;p&gt;Cleaned data ensures any analysis done gives reliable insights. &lt;/p&gt;

&lt;p&gt;Data cleaning is part of the analytics process. It's the first step when presented with a set of raw data.&lt;/p&gt;

&lt;p&gt;Data analytics can be described as the elaborate process of inspecting, cleaning, transforming and modelling raw date to express usable insights. You are basically turning raw data into actionable information.&lt;/p&gt;

&lt;p&gt;In data analytics, you will do 4 types of analysis.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Descriptive analysis simply tells us what happened. For example 30 students in a dataset of 100 students scored grade A in stream X in 2026.&lt;/li&gt;
&lt;li&gt;Diagnostic analysis examines why only 30 students scored Grade A, by looking at historic trends maybe, or even variables that could have limited perfomance in that class.
-Predictive analysis uses the diagnostic data to predict what could happen in future.
-Prescriptive analysis offers insights into what action can be taken to get better performance of the students for example or to limit the inhibiting factors.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Conclusion
&lt;/h2&gt;

&lt;blockquote&gt;
&lt;p&gt;Data sets vary vastly and each will require uniquely different tools and approach to clean. The strict rule is to ensure validity, uniformity and highest level of accuracy. Data sets can be processed but integrity of the original data must always be upheld.&lt;/p&gt;
&lt;/blockquote&gt;

</description>
      <category>data</category>
      <category>analytics</category>
    </item>
    <item>
      <title>Understanding the Git Workflow: Working Directory, Staging, Commit and Push</title>
      <dc:creator>Joel Raphael Ogwai Odira </dc:creator>
      <pubDate>Sun, 23 Aug 2026 14:35:07 +0000</pubDate>
      <link>https://dev.to/ogwaiodira/understanding-the-git-workflow-working-directory-staging-commit-and-push-4pop</link>
      <guid>https://dev.to/ogwaiodira/understanding-the-git-workflow-working-directory-staging-commit-and-push-4pop</guid>
      <description>&lt;h2&gt;
  
  
  Introduction
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;The Ecosysytem&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;To understand the git workflow, we have to understand the ecosystem within which it exists. The tools that facilitate this workflow.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Git&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;This is a local version control system that tracks changes to files and code. It runs on every users local computer hence also known as an open source distributed version control system.&lt;br&gt;
Whenever you create files or code, git is the software system that tracks these actions and ensures their integrity.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Gitbash&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Simply a command line interface. Like Git itself, it runs on your local computer and allows users to execute git commands.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Github
&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Github is the web based platform. Its an endpoint and host for all work done by users and various collaborative tools.&lt;br&gt;
It is an interactive platform where creators and other users can view and even contribute to your work while giving you the benefit to control such interaction and contribution through access control tools.&lt;/p&gt;

&lt;p&gt;For the git workflow to be complete, every aspect of this ecosystem has to work in harmony.&lt;/p&gt;




&lt;h2&gt;
  
  
  The Workflow
&lt;/h2&gt;

&lt;p&gt;The workflow follows an ordered sequence with various actions being perfomed in each sequence.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Working directory&lt;/li&gt;
&lt;li&gt;Staging changes&lt;/li&gt;
&lt;li&gt;Creating a commit&lt;/li&gt;
&lt;li&gt;Pushing to a working repository&lt;/li&gt;
&lt;/ol&gt;

&lt;h3&gt;
  
  
  Working directory
&lt;/h3&gt;

&lt;p&gt;A github repository stores all files, folders and documentation related to a specific project. In git workflow, the repository is stored locally on your computer.&lt;br&gt;
We established that git and gitbash run on your local computer, therefore for the software system, git, to manage and track changes, the repository has to be cloned to a path on your local computer.&lt;/p&gt;

&lt;p&gt;Git can't manage data or code in the entire repository concurrently. The user has to define specific files on which to work on. This brings the concept of working directory. It simply means the specific path the code or file where you are currently using git to make and track changes.&lt;/p&gt;

&lt;h3&gt;
  
  
  Establishing Your Working Directory
&lt;/h3&gt;

&lt;p&gt;The crucial first step is to ascertain you are in the right directory. You use a set of command lines to do this.&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;As opposed to windows &lt;code&gt;C:\Users&lt;/code&gt; , in gitbash paths are mapped using unix style &lt;code&gt;/c/Users&lt;/code&gt;&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;&lt;code&gt;pwd&lt;/code&gt; shows you the current path you are in the directory. &lt;code&gt;ls&lt;/code&gt; shows you the contents of your current directory. If you are in the wrong path you have a set of options to;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;navigate and access the right directory&lt;/li&gt;
&lt;li&gt;create a new directory or file&lt;/li&gt;
&lt;li&gt;list your current directory contents&lt;/li&gt;
&lt;/ul&gt;

&lt;ol&gt;
&lt;li&gt;&lt;strong&gt;Navigate and access the right directory&lt;/strong&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Command line&lt;/th&gt;
&lt;th&gt;Function&lt;/th&gt;
&lt;th&gt;Sample&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;pwd&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Show current directory&lt;/td&gt;
&lt;td&gt;&lt;code&gt;pwd&lt;/code&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;cd&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Change Directory&lt;/td&gt;
&lt;td&gt;&lt;code&gt;cd Photos&lt;/code&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;cd ..&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Up one level&lt;/td&gt;
&lt;td&gt;&lt;code&gt;cd ../&lt;/code&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;cd ../..&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Up two levels&lt;/td&gt;
&lt;td&gt;&lt;code&gt;cd ../..&lt;/code&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;cd ~&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Home Directory&lt;/td&gt;
&lt;td&gt;&lt;code&gt;cd ~&lt;/code&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;cd -&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Previous Directory&lt;/td&gt;
&lt;td&gt;&lt;code&gt;cd -&lt;/code&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;cd /&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Root&lt;/td&gt;
&lt;td&gt;&lt;code&gt;cd /&lt;/code&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F3pu4btittygy2otf49e0.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F3pu4btittygy2otf49e0.png" alt="Illustration of commands" width="800" height="614"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Creating new directory or file&lt;/strong&gt;
&lt;/li&gt;
&lt;/ol&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;mkdir &lt;/span&gt;folder_name                  &lt;span class="c"&gt;# Create one directory&lt;/span&gt;
&lt;span class="nb"&gt;mkdir &lt;/span&gt;folder1 folder2 folder3      &lt;span class="c"&gt;# Create multiple&lt;/span&gt;
&lt;span class="nb"&gt;mkdir&lt;/span&gt; &lt;span class="nt"&gt;-p&lt;/span&gt; path/to/nested/folders    &lt;span class="c"&gt;# Create nested folders&lt;/span&gt;
&lt;span class="nb"&gt;touch &lt;/span&gt;filename.txt                 &lt;span class="c"&gt;# Create an empty file&lt;/span&gt;
&lt;span class="nb"&gt;touch &lt;/span&gt;file1.txt file2.md file3.py  &lt;span class="c"&gt;# Create multiple empty files&lt;/span&gt;

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ol&gt;
&lt;li&gt;&lt;strong&gt;Listing contents of your current directory&lt;/strong&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Command line&lt;/th&gt;
&lt;th&gt;Function&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;ls&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;All files&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;ls -l&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;All files in detailed format&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;ls -a&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;All files, detailed including hidden files &lt;code&gt;.&lt;/code&gt;
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;ls la&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Detailed plus hidden files&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;The above processes show how to get to the right directory, you can then make changes and manage content using a variety of tools available.&lt;/p&gt;

&lt;h3&gt;
  
  
  Staging in Git
&lt;/h3&gt;

&lt;p&gt;You have done your changes in the working directory. What next? We learnt Git is a software and gitbash is the command line interface. Data, files and code in this format is unusable except by or through your local computer only. To collaborate, display and have these stored in a retrievable format; we need Github, the web interface.&lt;br&gt;
Between your working directory and github, we go through 2 steps, first which is staging.&lt;/p&gt;

&lt;p&gt;Staging in github is therefore self explanatory. Getting your changes prepared to be included in the next commit. This part of the sequence allows you to select what changes are commited.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Check status in your working directory&lt;/strong&gt;
&lt;/li&gt;
&lt;/ol&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;git status
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This command shows the status of changes in the directory. They could either be :&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Untracked files/changes not staged for commit&lt;/li&gt;
&lt;li&gt;changes to be commited (These are ready and prepared for commit)&lt;/li&gt;
&lt;/ul&gt;

&lt;ol&gt;
&lt;li&gt;&lt;strong&gt;Stage unprepared files and folders&lt;/strong&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;After ascertaining the unstaged files, use the command&lt;br&gt;
&lt;br&gt;
 &lt;code&gt;git add&lt;/code&gt;&lt;br&gt;
&lt;br&gt;
 but in different versions to give you control of what to stage.&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Command line&lt;/th&gt;
&lt;th&gt;Function&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;git add filename.txt&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Stage specific file&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;git add folder/&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Stage folder and all it's contents&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;git add .&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Stage all new and modified files in parent directory and all subdirectories&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;
&lt;code&gt;git add -A&lt;/code&gt; or &lt;code&gt;git add --all&lt;/code&gt;
&lt;/td&gt;
&lt;td&gt;Stage all new, modified and deleted files across the repository&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;git add -u&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Stage only modified and deleted files, excludes untracked or new files&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;
&lt;code&gt;git add -p&lt;/code&gt; or &lt;code&gt;git add --patch&lt;/code&gt;
&lt;/td&gt;
&lt;td&gt;Stage individual parts of a file&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;ol&gt;
&lt;li&gt;Run &lt;code&gt;git status&lt;/code&gt; again, at which point files should appear under &lt;em&gt;changes to be commited.&lt;/em&gt;
In case of any errors you have the following command prompts at your disposal.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;&lt;code&gt;git restore --staged filename.txt&lt;/code&gt; to unstage a file&lt;br&gt;
&lt;code&gt;git restore --staged .&lt;/code&gt;to unstage everything&lt;br&gt;
&lt;code&gt;git diff --staged&lt;/code&gt; to see differences of staged files&lt;br&gt;
&lt;code&gt;git diff&lt;/code&gt; to see unstaged files&lt;/p&gt;

&lt;h3&gt;
  
  
  Commit
&lt;/h3&gt;

&lt;p&gt;The standard and most commonly used commit command simply is;&lt;/p&gt;

&lt;p&gt;&lt;code&gt;git commit -m Clear description of what this commit does&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;This command records the staged changes. &lt;em&gt;Note that at this point we are still in our local computer.&lt;/em&gt; Unstaged changes therefore remain in our working directory.&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;Another command &lt;code&gt;git commit -a&lt;/code&gt; bypasses the &lt;code&gt;git -add&lt;/code&gt; stage and stages all modified and deleted files in your working directory. See table below for variance between different commit command prompts.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Feature&lt;/th&gt;
&lt;th&gt;&lt;code&gt;git commit -a&lt;/code&gt;&lt;/th&gt;
&lt;th&gt;&lt;code&gt;git commit&lt;/code&gt;&lt;/th&gt;
&lt;th&gt;&lt;code&gt;git commit -am "msg"&lt;/code&gt;&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Stages modified files&lt;/td&gt;
&lt;td&gt;Yes&lt;/td&gt;
&lt;td&gt;No&lt;/td&gt;
&lt;td&gt;Yes&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Stages deleted files&lt;/td&gt;
&lt;td&gt;Yes&lt;/td&gt;
&lt;td&gt;No&lt;/td&gt;
&lt;td&gt;Yes&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Stages untracked (new) files&lt;/td&gt;
&lt;td&gt;No&lt;/td&gt;
&lt;td&gt;No&lt;/td&gt;
&lt;td&gt;No&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Opens text editor for message&lt;/td&gt;
&lt;td&gt;Yes&lt;/td&gt;
&lt;td&gt;Yes&lt;/td&gt;
&lt;td&gt;Passes message inline&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;A commit acts to move changes permanently from our staging area and makes them a permanent record. Git calls this a snapshot and is done in the &lt;code&gt;.git&lt;/code&gt; folder. To see this folder you use the command we discussed earlier &lt;code&gt;ls -a&lt;/code&gt; or &lt;code&gt;ls -la&lt;/code&gt;.&lt;/p&gt;

&lt;p&gt;Other actions that happen during this stage, git creates a commit object known as a Hash. It records the unique code changes, author name, timestamp, commit message, and the hash of the parent commit.&lt;/p&gt;

&lt;p&gt;At this point, you can run &lt;code&gt;git status&lt;/code&gt; again and if all is good you should see the message &lt;em&gt;“nothing to commit, working tree clean”.&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;For any ammendments, you also have these at your disposal.&lt;/p&gt;

&lt;p&gt;&lt;code&gt;git commit --ammend&lt;/code&gt; Modifies most recent commit e.g add a file or edit commit m&lt;br&gt;
&lt;code&gt;git commit --ammend -m new message&lt;/code&gt; Changes message in last commit&lt;br&gt;
&lt;code&gt;git commit --ammend --no -edit&lt;/code&gt; Ammends last commit but keeps message&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Commit message&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Should be short and precise, preferably less than 50 characters. It summarily explains what was changed, why it was changes and any caution users should take. It should be done in present tense.&lt;/p&gt;

&lt;h3&gt;
  
  
  Git Push
&lt;/h3&gt;

&lt;p&gt;This is the last stage in the workflow. This uploads commits from your local repository to a web based platform, Github. This happens within the corresponding branch in your local and remote repository. At this point others can create edits, push and pull requests.&lt;/p&gt;

&lt;p&gt;*&lt;em&gt;Push and pull&lt;/em&gt; requests work when collaborators or even the main user suggest changes, new features etc to an existing project. This allows stable code since the creators have access control tools to preview changes before they are merged on to the main branch.&lt;/p&gt;

&lt;p&gt;It's imperative that users carefully determine what branch they are doing a push to. Several options are available.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;code&gt;git status&lt;/code&gt; will show current branch at the top.&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;git branch&lt;/code&gt;Lists all local branches and the current one is marked with an asterisk.&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;git rev-parse --abbrev-ref HEAD&lt;/code&gt; and &lt;code&gt;git branch --show-current&lt;/code&gt; simply show the branch. See below image for an actual sample.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Ftlgb2e5852d9x1ytq4kq.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Ftlgb2e5852d9x1ytq4kq.png" alt="Branch commands" width="799" height="410"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;See table below for a summary of push commands.&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Command line&lt;/th&gt;
&lt;th&gt;Function&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;git push&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Pushes current local branch to corresponding remote branch&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;git push origin main&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Specifies for git to push main branch in local repository to branch named origin in remote repository&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;git push -u origin main&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Pushes and reminds git to use this upstream relationship in subsequent push&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;git push origin feature -branch&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Pushes a feature branch&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;git push --all&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Pushes all local branches&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;git push --tags&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Pushes Tags as well&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;Summary&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;The numerous commands can be confusing. However, the main concept of this workflow isn't the commands rather grasping the orderly sequence. This workflow can be summarised as a &lt;strong&gt;&lt;em&gt;local to remote workflow.&lt;/em&gt;&lt;/strong&gt;&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;Working Directory  →  Staging Area  →  Commit  →  Remote Repository&lt;/p&gt;


&lt;/blockquote&gt;

</description>
      <category>git</category>
      <category>github</category>
      <category>gitbash</category>
      <category>workflow</category>
    </item>
  </channel>
</rss>
