My Journey with PowerShell: Getting Comfortable with Folders, Files, and the Terminal

My Journey with PowerShell: Getting Comfortable with Folders, Files, and the Terminal

When I first opened the PowerShell terminal, the plain blue screen looked serious — and frankly, intimidating. But I had a clear goal:
I wanted to learn how to navigate folders, manage files, and perform basic tasks directly through the terminal.

So in the beginning, I repeated a simple cycle over and over again:

  • Created folders and .txt files
  • Wrote content into them
  • Modified the content
  • Deleted them, re-created them, renamed them
  • Deleted folders and cleaned up everything

I kept doing this because I wanted my hands to get used to the commands. I wanted to shift my brain from “click with the mouse” to “type it with confidence”. Repetition helped a lot.

Problems I Faced Along the Way

  • I got “file in use” errors while trying to delete folders — turns out even having a folder open in Explorer can block removal.
  • I wasn’t sure when to use -Recurse and -Force with Remove-Item, but I figured it out with trial and error.
  • OneDrive’s sync process would sometimes lock files. Pausing sync temporarily solved it.

Now I feel much more confident. PowerShell is no longer something I avoid — it’s a tool I reach for when I want to get things done quickly and precisely.

Want to Try This Yourself?

If you’re curious about PowerShell and want to get hands-on experience with file and folder management, here’s a beginner-friendly guide to get you started.

How to Open PowerShell

  • Press Win + R, type powershell, then press Enter
  • OR: Search “PowerShell” in the Start menu and open it

Folder and File Basics

TaskCommand
Show current directoryGet-Location
Navigate to folderSet-Location "FolderName" or cd
Create new folderNew-Item -ItemType Directory -Name "FolderName"
Create new fileNew-Item -ItemType File -Name "file.txt"
List folder contentsGet-ChildItem or ls
List only .txt filesGet-ChildItem -Filter *.txt

Working with File Contents

TaskCommand
Write text to file (overwrite)Set-Content -Path "file.txt" -Value "Hello"
Append text to fileAdd-Content -Path "file.txt" -Value "New line"
Read file contentGet-Content file.txt
Clear file content (keep file)Clear-Content -Path file.txt

Deleting Files and Folders

What to deleteCommand
A fileRemove-Item file.txt
A folder and its contentsRemove-Item FolderName -Recurse -Force
Only folder contents (keep folder)Remove-Item FolderName\* -Recurse -Force

Copying and Moving

TaskCommand
Copy a fileCopy-Item original.txt copy.txt
Move a fileMove-Item file.txt FolderName\
Rename a fileMove-Item file.txt newname.txt

Useful Commands

CommandPurpose
Test-Path file.txtCheck if file or folder exists
Select-String -Path *.txt -Pattern "keyword"Search for text in files
echo "hello"Write message to screen (CMD-style)

Create a test folder on your desktop and open PowerShell inside it. Then practice each command multiple times.
Repetition is what turns syntax into second nature — and that’s when things really get fun.

Leave a Reply

Your email address will not be published. Required fields are marked *