🚀 My First Steps with GitHub Actions: A Beginner’s Story

🚀 My First Steps with GitHub Actions: A Beginner’s Story


🌟 A New World of Automation

When I first heard about GitHub Actions, I dismissed it as one of those shiny tools meant only for big tech giants with sprawling infrastructures. I pictured massive companies deploying hundreds of microservices, each supported by pipelines crafted by entire DevOps teams.

But one day, I pushed a small piece of code to GitHub and caught myself thinking: “Wouldn’t it be amazing if the tests just ran on their own, without me typing a single command?”

That was my turning point. I realized GitHub Actions isn’t reserved for enterprises—it’s for anyone who codes. Whether you’re a student, hobbyist, or professional developer, you can use it to:

  • Save time on repetitive work.
  • Automate boring but important tasks (tests, builds, linting).
  • Make projects smoother, faster, and more reliable.

This is my journey: from curiosity to building my first automated workflows. We’ll start small—just enough to see the magic—and grow into more powerful setups. Along the way, you’ll get hands-on labs to try for yourself.


🛠 Understanding GitHub Actions Through a Simple Lens

At first, the terminology felt like alphabet soup: workflow, action, runner. I didn’t know where to start.

Then I found an analogy that made everything click:

  • Workflow → The recipe. It tells GitHub what you want to cook—the big picture of automation.
  • Actions → The cooking steps. Each step is a small task like “install dependencies” or “run tests.”
  • Runner → The kitchen. This is the machine (Linux, Windows, or macOS) where everything gets executed.

Once I saw GitHub Actions this way, the mystery disappeared. I wasn’t writing rocket-science code—I was just writing recipes that GitHub would happily follow.


🧪 Lab 1: Saying “Hello” to GitHub Actions

I decided to start at the smallest step possible. My question: “Will GitHub even listen to me?”

So I wrote my first workflow:

name: Hello World

on:
  push:
    branches:
      - main

jobs:
  say-hello:
    runs-on: ubuntu-latest
    steps:
      - name: Checkout code
        uses: actions/checkout@v3

      - name: Print Hello
        run: echo "👋 Hello GitHub Actions!"
        

The moment I pushed the code and opened the Actions tab, my heart jumped: the workflow appeared and actually ran! Seeing the log print out “👋 Hello GitHub Actions!” was like watching a lightbulb turn on.

Lesson learned: Even the simplest workflow proves GitHub Actions is real, responsive, and waiting to automate whatever you ask.


🔍 Moving Beyond “Hello”

“Okay, it can greet me. But can it do real work?” That was my next thought. Naturally, I turned to tests.


🧪 Lab 2: Automating Python Tests

I added a new workflow to install Python, grab dependencies, and run pytest:

name: Python Tests

on: [push, pull_request]

jobs:
  test:
    runs-on: ubuntu-latest
    steps:
      - name: Checkout code
        uses: actions/checkout@v3

      - name: Set up Python
        uses: actions/setup-python@v5
        with:
          python-version: "3.10"

      - name: Install dependencies
        run: pip install -r requirements.txt

      - name: Run tests
        run: pytest
        

The first time I saw a big green ✔️ on my pull request, I realized: I had just built Continuous Integration (CI).

Lesson learned: I no longer needed to remember pytest. GitHub took care of it automatically every time code was pushed.


🌍 My First Deployment with Actions

Tests were good, but what if GitHub Actions could also ship my project to the world? Time to try deployment.


🧪 Lab 3: Deploying a Website to GitHub Pages

Here’s the workflow I wrote:

name: Deploy Website

on:
  push:
    branches:
      - main

jobs:
  deploy:
    runs-on: ubuntu-latest
    steps:
      - name: Checkout code
        uses: actions/checkout@v3

      - name: Deploy to GitHub Pages
        uses: peaceiris/actions-gh-pages@v4
        with:
          github_token: ${{ secrets.GITHUB_TOKEN }}
          publish_dir: .
        

When I refreshed my GitHub Pages link, my site was live. No manual uploads, no FTP clients—just a push to main.

Lesson learned: GitHub Actions isn’t only CI—it’s also Continuous Delivery (CD).


🌙 Scheduling Workflows

By now, I had builds, tests, and deployments running automatically. But what about tasks I wanted to run without a push—like a nightly cleanup job?

Turns out, GitHub Actions supports cron schedules.


🧪 Lab 4: Nightly Jobs

on:
  schedule:
    - cron: "0 0 * * *"  # Every midnight

jobs:
  nightly:
    runs-on: ubuntu-latest
    steps:
      - run: echo "🌙 Nightly build complete!"
        

Every night at midnight, my job ran on its own.

Lesson learned: Actions aren’t just reactive—they can also run proactively on schedules.


🖥 Testing on All Platforms

I usually code on Linux. My friend codes on Windows. Another friend works on macOS. Would my project run everywhere? I wasn’t sure—until Actions gave me the answer.


🧪 Lab 5: Multi-OS Matrix Testing

jobs:
  test:
    runs-on: ${{ matrix.os }}
    strategy:
      matrix:
        os: [ubuntu-latest, windows-latest, macos-latest]
    steps:
      - uses: actions/checkout@v3
      - run: echo "Running tests on ${{ matrix.os }}"
        

Suddenly, my project was tested across three operating systems with no extra effort.

Lesson learned: GitHub Actions helps ensure cross-platform confidence without needing three laptops.


🧠 What I Learned Along the Way

After these labs, I started picking up best practices:

  • Always checkout your code first. Without it, steps can’t run.
  • Use GitHub Secrets. Never hardcode API keys.
  • Keep workflows modular. Separate testing, deployment, and linting.
  • Expect failures. Debugging with logs is part of the journey.


📊 Where GitHub Actions Took Me Next

Once I got comfortable, I began experimenting with:

  • Slack notifications after deployments.
  • Building and pushing Docker images.
  • Linting to enforce coding standards.
  • Manual triggers (buttons in GitHub).

At this point, Actions wasn’t just a CI/CD tool—it was an automation engine for my entire developer workflow.


🎓 Closing the Story

I started this journey thinking GitHub Actions was “too advanced” for me. But step by step—hello world, tests, deployments, schedules, cross-platform builds—I built confidence.

👉 Final lesson: Every push is more than just saving code. With GitHub Actions, every push becomes a trigger for something bigger: testing, deploying, notifying, or scheduling.

Once you start automating, you won’t want to go back.


This was timely, thank you!

Like
Reply

how do you sign up for the class? Or is it through the university?

Like
Reply

To view or add a comment, sign in

More articles by Michael Lively

  • Good, Bad and the Ugly Prompts

    Exercise: Figure out what makes each one tick. Analyst Agent Exercise 1: https://learn.

  • Footwear Case Study

    MikesFancyFootware is a fast-growing, digital-first footwear brand for men and women that relies heavily on online…

  • Copilot Companion Site

    Links: GitHub Download Link: https://github.com/eaglelandsonce/CopilotDay1Download MS-4018 MSLearn & Video Companion…

  • Data Architecture Day 3 (Under Construction)

    Importance of Juypter Notebooks 1. Your AI Is Only as Good as Your Data Plumbing: 3 Core Principles for Scalable…

  • Data Architecture Day 2 (Under Construction)

    DAY 2 ======================= Lab Files: https://github.com/eaglelandsonce/Day2DataArchLabs 1.

  • Data Architecture Day 1 (Under Construction)

    DAY 1 ======================= Lab Files: https://github.com/eaglelandsonce/Day1DataArchLabs Lab Files 1.

  • Krippendorff's Alpha

    Imagine you and a friend watch a new movie. When it's over, you both rate it on a scale of 1 to 10.

  • Intro to LIME

    Introduction: The "Black Box" Problem We increasingly rely on artificial intelligence for critical decisions, from…

  • Emergent AI

    1.0 Introduction: The Unlikely Teacher When we picture the origins of artificial intelligence, we often imagine sterile…

  • Intro to Random Forest

    Introduction: From a Single Tree to a Powerful Forest When faced with a major decision, whom do you trust more: a…

Others also viewed

Explore content categories