Welcome
Blog Posts
Git - What Is a Ref in Git?
Imagine trying to find your way through a massive library without any labels or organization system - that’s what Git would be like without refs. A ref (short for “reference”) is Git’s elegant solution to making its complex system of commits human-friendly and manageable.
Git - Basic Command Guide
Git is a distributed version control system (DVCS) that helps developers track, manage, and collaborate on code changes across projects. Through its robust command-line interface, Git provides essential tools for staging changes, creating commits, and maintaining code history while offering advanced features to optimize development workflows. This guide covers both fundamental Git operations—from repository initialization and basic commits—to more sophisticated techniques like branch management, remote collaboration, and history manipulation through commands like merge and rebase. With practical examples and best practices for each command, this guide equips you with the knowledge to manage projects effectively using Git’s powerful version control capabilities, whether working individually or as part of a team.
Python - Understanding and Managing Cyclomatic Complexity in Python with flake8
Cyclomatic complexity is a crucial metric for understanding the maintainability of your code. In this guide, we’ll explore cyclomatic complexity, how flake8 can help identify complex functions and practical tips for keeping your code clean and maintainable.
AI - Gradient Descent Algorithm
Hey there! I’m Yumi—your friendly AI guide, and maybe just a little bit of a cupcake enthusiast too! 😉 I’m here to make learning about AI and machine learning fun, easy, and totally not intimidating. I love breaking down complex ideas so they’re easy to digest, just like a good recipe (which you’ll see I use a lot as an analogy!). Think of me as your digital bestie, here to help you understand the coolest tech out there while keeping things light and enjoyable. Let’s dive in and learn together—one tasty learning adventure at a time!
XML - XPATH Common Use Cases and Function Reference
XPath is a powerful tool for navigating and extracting data from XML and HTML documents, often likened to a GPS for document structures. Originally designed for XML, XPath is now widely used in web development, test automation, data processing, and DevOps. It enables developers to precisely target data within complex hierarchical structures using path-like expressions, supporting everything from test frameworks like Selenium to web scraping and configuration management.
pyATS - Working with PyATS Secret Strings
Overview
PyATS provides a secure way to handle sensitive information like passwords and credentials in your
testbed.yaml
files using “secret strings” encryption. This feature prevents exposure of sensitive data even if the testbed file is accidentally shared or accessed by unauthorized users.Linux - Verifying GPG Keys and Displaying Public Key Information
This guide provides a script that verifies GPG keys stored in
/usr/share/keyrings/
, showing detailed information, including expiration dates, key capabilities, and the full public key block. By the end, you will be able to view each.gpg
file’s public key details, understand its expiration dates, and check its intended usage.Linux - xargs Command Guide
xargs
is a powerful command-line utility that reads items from standard input and executes commands with those items as arguments.Linux - Common Regex Expressions for grep Cheat Sheet
This introductory guide serves as a handy reference for common regular expressions (regex) you can use with the
grep
command. If you’re just starting out or need a quick refresh, this cheat sheet will make it easy to get the hang of the essential regex patterns that go hand in hand withgrep
.Linux - `tmux` - Managing Sessions and Split Panes in SSH Sessions
Tmux (short for terminal multiplexer) is a powerful tool that allows users to manage multiple terminal sessions within a single window. It lets you open various windows and split them into panes within a single session. These sessions can be detached and reattached, which is incredibly useful when working remotely over SSH, as you can maintain long-running processes even if you disconnect.
Python - A Guide to Working with XML Using lxml in Python
lxml is one of Python’s most powerful libraries for working with XML and HTML documents. Built on top of libxml2, it offers fast performance and a variety of tools to handle elements, nodes, and namespaces efficiently.
XMLLINT - An XML Parsing Tool
xmllint
is a command-line tool used for parsing and validating XML files. It offers various options to perform different functions, such as formatting XML, extracting specific data, or validating against XML schemas. This versatility makes xmllint an essential utility for anyone working with XML data.Software Development - Acyclic Dependency Principle - ADP
The acyclic dependency principle (ADP) is a software development principle that manages how different parts of software depend on each other.
Linux - Using the `dig` (Domain Information Groper) Command
The
dig
(Domain Information Groper) command is a network administration command-line tool for querying Domain Name System (DNS) servers. It is commonly used to troubleshoot DNS problems and to perform DNS lookups.GitLab: Create a self-signed Certificate for a self-contained lab
These Notes are based on a lab that I had to build. These instructions may or may not work for you depending on your situation.
DEVOPS - Notes
In recent years, industry trends and innovations have significantly transformed business operations. Businesses increasingly incorporate mobility, the Internet of Things (IoT), and cloud services to meet market demands, requiring agility, simplicity, speed, and innovation to stay competitive. This transformation, known as digital transformation, necessitates new tools, culture, and processes, particularly in how developers and operations teams interact.
Python - Environment Setup with Pipx, Poetry, and Pyenv ✨
This guide will walk you through setting up your Python environment using
pipx
,poetry
, andpyenv
. These tools work together seamlessly to help you manage isolated environments, dependencies, and Python versions efficiently. Ready to streamline your Python setup? Let’s get started! 💪VMWare - General CLI Notes
A handy set of VMware ESXi CLI commands to make life easier. These notes cover common tasks like clearing ARP caches, enabling promiscuous mode on vSwitches, managing port groups, and adding vNICs to VMs—all from the command line.
Networking - VXLAN with BGP EVPN
EVPN (Ethernet VPN) with VXLAN (Virtual Extensible LAN) is a network virtualization technology that allows you to extend Layer 2 networks across Layer 3 boundaries. This is particularly useful in data center environments for creating scalable and flexible network architectures.
Linux Bash Scripting Basics
These notes cover essential concepts such as creating and structuring basic Bash scripts. It explains how to use variables and basic operators, and introduces conditional statements like if-else and comparison operators. It also delves into the use of loops, including for and while, for handling repetitive tasks. Additionally, the document covers how to define and use functions, including how to pass arguments, manage return values, and understand variable scope. Several practical examples are included, such as file management, file operations, and output processing tasks like factorial calculation, to illustrate the application of these concepts in real-world scripting.
Linux - Communicating through the Terminal to Other Users
In this tutorial, we’ll learn how to leave a message to another local user in Linux. There are several commands that we can use to achieve this. We’ll first look at the wall command. We’ll then cover the remaining commands mostly used for this purpose.
Git - Download a specific directory
When working with large repositories, cloning the entire project isn’t always necessary or efficient, especially if only specific files or directories are needed. Git’s sparse-checkout feature provides a way to download only the required parts of a repository, saving time, bandwidth, and storage space.
Python - Yield Keyword in Iterating Functions
In Python, the
yield
keyword is used in a function to create an iterator. When a function containing ayield
statement is called, it returns an iterator object that can be iterated using afor
loop or thenext()
function. Each time the iterator is advanced, the function runs until it encounters ayield
statement, at which point it returns the value specified after theyield
keyword. The next time the iterator is advanced, the function resumes execution immediately after theyield
statement and continues until it encounters anotheryield
statement or until the function exits.Python - Code Snippets from Previous Projects
A collection of useful code snippets and notes that I’ve found handy throughout various projects. Whether you’re dealing with API limits or parsing YAML files, these examples should make your life a bit easier!
Data Science Notes
The empirical rule, also known as the 68-95-99.7 rule or the three-sigma rule, is a statistical guideline that describes data distribution in a normal distribution. The rule states that for a normal distribution:
Git Hooks: Automating and Enforcing Workflows
Git hooks provide a way to automate tasks and enforce workflows by triggering custom scripts during various Git events. These hooks can be used to run tests, validate commit messages, or enforce policies before changes are committed or pushed. By utilizing client-side and server-side hooks, developers can ensure consistency and quality throughout the development process.
HATEOAS - Hypermedia as the Engine of Application State
HATEOAS stands for Hypermedia as the Engine of Application State. It’s a constraint of the REST application architecture that keeps the RESTful style architecture unique from most other network application architectures.
Linux - Using `tcpdump` for Ubuntu 20.04 and up
Some notes I made about using
tcpdump
to get a network capture on a linux host.Python - Pandas DataFrames Overview
A DataFrame in Pandas is a two-dimensional, size-mutable, and potentially heterogeneous tabular data structure with labeled axes (rows and columns). Think of a DataFrame as a table (like an Excel spreadsheet or SQL table) where each column can contain different data types (integers, floats, strings, etc.), but all columns share the same index.
Software Development - Understanding OAuth 2.0
In today’s digital age, proving your identity online is critical to accessing various services and applications. While traditional methods like username and password authentication have been widely used, the increasing complexity of online ecosystems demands a more secure and flexible approach. OAuth 2.0 is the modern standard for access delegation, allowing users to grant third-party services access to their resources without sharing credentials directly.
Understanding OAuth 2.0: A Beginner's Guide to Modern API Security
In today’s digital age, proving your identity online is critical to accessing various services and applications. While traditional methods like username and password authentication have been widely used, the increasing complexity of online ecosystems demands a more secure and flexible approach. OAuth 2.0 is the modern standard for access delegation, allowing users to grant third-party services access to their resources without sharing credentials directly.
Docker Pruning and Conserving Memory on Your Host: A Brief Tutorial
Docker is an essential tool for containerization, but as you build, run, and delete containers, you’ll notice that your system starts accumulating unused data. This can be in the form of “dangling” images, stopped containers, unused volumes, and more. This tutorial aims to guide you through the process of cleaning up these unused resources to conserve memory and disk space on your host machine.
Linux - What does the Double pipe `||` mean in Bash scripting?
The
||
(double pipe) operator is used as a logical OR in Bash scripting to chain commands. It allows you to run the command following the||
operator if the command preceding it fails (i.e., returns a non-zero exit status).Software Development - Dependency Inversion Principle
The Dependency Inversion Principle (DIP) is a programming concept that encourages developers to write more flexible and reusable code.
Python - Pandas Cheat Sheet
Pandas is a powerful Python library used for data manipulation and analysis. It provides flexible data structures, such as DataFrames, that allow you to easily work with structured data. Pandas is commonly used for data wrangling, cleaning, and performing various data operations in a fast and efficient way.
XML - Understanding the Basics
Extensible Markup Language (XML) is a widely-used format for storing and transporting data. It is both human-readable and machine-readable, making it ideal for data exchange between different systems. XML uses a hierarchical structure, where data is organized into a tree-like format with a root element, child elements, attributes, and other types of nodes.
Ansible - Ansible Pyenv Compatibility
Ansible 2.10 uses galaxy
pip install ansible-base
(must uninstall core if you need to upgrade to core)XML - Understanding the Basics
Extensible Markup Language (XML) is a widely-used format for storing and transporting data. It is both human-readable and machine-readable, making it ideal for data exchange between different systems. XML uses a hierarchical structure, where data is organized into a tree-like format with a root element, child elements, attributes, and other types of nodes.
jid - (JSON Incremental Digger)
jid
is a simple and powerful interactive tool for querying and exploring JSON data. It allows you to filter and browse through JSON objects in real-time using an intuitive interface, making it easier to work with complex JSON data structures.
subscribe via RSS