Daily Learning Log

Daily Learning Log
Photo by Estée Janssens / Unsplash

A running record of what I learned, built, or encountered for the first time.

August 8, 2025

Take-away of the day: Git Day 2! I learned how to use branches and restore to safely debug, refactor, and experiment on my programs.

Git

  • In addition to branches and restore, I learned how to use status and log to investigate the state of my repository.
  • Got my first look inside .git/config — the magic behind Git.

Blog

August 7, 2025

Take-away of the day: Git Day!!! I finally grasp git. git init builds a local train station. gh repo create builds a remote train station. git add gathers up loose cargo (changes since last add) and loads them on a new train car. git commit takes those cars and connects them to the train engine at the station. The first git push builds the tracks to the remote station and sends the trains along the track.

Reflection: There are a lot of improvements I can still make to my PowerShellProfile.ps1 file, but it is robust and accomplishes a lot and works. I’m sure I’ll keep refining it, but it’s solid and useful. Time to move on.

Git

  • Grasped the fundamentals of how git works and how I can use it as a solo programmer to keep my projects tidy and portable.
  • Learned how team projects use upstreams, forks and branches to work concurrently and resolve code conflicts.
  • Committed to a basic framework for keeping my git clean - git push at the end of each session and git fetch origin with git log origin/main..main at the start of each session.
  • Learned other basic commands to investigate git status, including status, branch, log --oneline, and show.

PowerShell

  • Debugged New-PyProject.ps1
  • Learned that private confines a variable to the context in which it is created.

August 6, 2025

Take-away of the day: Today was chill, after the mental marathon of the past two days. Focused on reviewing my recent learnings, profoundizing my understanding of the New-PyProject function, and tinkering with PowerShell.

PowerShell

  • Learned that & runs a command (like a system call), throw prints an error and stops the script, and [CmdletBinding()] adds features to a function like -Verbose and -WhatIf.
  • Did a deep dive into function creation and how to read and use parameters.
  • foreach ($item in $object) is the standard loop syntax, while ForEach-Object is used in pipelines (e.g., ... | ForEach-Object { }).
  • Differentiated three ways to build paths:
    • Join-Path, the native command, which will be my default.
    • + for simple strings.
    • and [System.IO.Path]::Combine(), the .NET method.

Git

  • Installed the GitHub CLI and authenticated, so I can now create repos and push from my terminal.

August 5, 2025

Take-away of the day: A lot of computer science is about conventions. Let's keep names standard so that we can communicate well across systems.

.NET

  • Used [System.Environment]::GetEnvironmentVariable() and [System.Environment]::SetEnvironmentVariable to clean up my Python environment by removing Python 3.10 from my user path variable.
  • Used [System.IO.Path]::Combine() to create robust path objects.
  • Used [System.Management.Automation.CompletionResult]::New() to create autocompletion functionality in a custom PowerShell command.

PowerShell

  • Created new cmdlets and aliases using PowerShell conventions.
  • Used the ForEach loop construct to loop through an array of directory names.
  • Used @ array constructor.
  • Built an Argument Completer and a Parameter Validator into my New-PyProject custom function.
  • Learned:
    • When piping commands that perform an action but are not meant to pass values, best practice is to use the Out-Null cmdlet to avoid passing unintended values.
    • About PowerShell's three variable scopes: Global, Script, and Local.
    • That PowerShell resolves the first word of a command in this order: aliases → functions (PROFILE or current script) → cmdlets → external executables (like python or git). If no match is found, it throws an error.

Windows OS

  • Grasped that Environment Variables:
    • let external programs know where to save directories and files.
    • allow us to build portable scripts that leverage conventions and Environment Variables with code such as Join-Path env:USERPROFILE "Downloads".
    • and provide a map that the terminal uses - via PATH and PATHEXT - to execute external executiables.

Python

  • Installed pyenv-win to ensure each project runs with the correct Python vrsion, independent of system settings.

August 4, 2025

Take-away of the day: Building the custom function New-PyProj gave me the visceral sense of PowerShell's power — it’s like a control tower for the entire system, and it is endlessly extensible.

PowerShell

  • Created a PowerShell profile and built a function, New-PyProj, that sets up a new Python project with folder structure, Git initialization, and a virtual environment using pyenv-win.
  • Wrote and executed my first multi-step PowerShell command using Test-Path, conditional logic, and piping.
  • Used [System.Management.Automation.CompletionResult]::New() to create autocompletion functionality in a custom PowerShell command.
  • Learned what a REPL is when PowerShell allowed me to correct a mid-block syntax error interactively. Yet was unable to replicate the behavior when repeating the same error with exact same code snipped. Still decoding the rules here.

Windows OS

  • Used Sysinternals' handle.exe to identify which process was locking a folder when I had "Access Denied" issues.
  • Gained clarity on the difference between / and \ in Windows paths. Lesson: default to \ to avoid unexpected behavior, such as accidentally referencing the root directory.

August 2, 2025

Systems

  • Designed a robust tagging system for my blog that will reveal a strong narrative structure as the archive grows and help readers (and future-me) find content easily.