Category: Operating Systems

  • Zsh vs. Bash on macOS: Should You Care?

    Starting with macOS Catalina, Apple ditched Bash as the default shell and gave Zsh the crown. Cue the collective sighs and confusion. But here’s the deal—if you’re doing any real terminal work on macOS, it’s worth knowing why that switch happened and whether you should care.

    Why the Switch?

    Apple made Zsh the default for licensing reasons. The version of Bash that shipped with macOS was ancient (v3.2 from 2007) because newer versions use GPLv3, which Apple didn’t want to mess with. Zsh doesn’t have that problem, so… boom, default.

    But it’s not just a legal shuffle—Zsh brings some goodies to the table.

    Zsh Perks

    • Auto-suggestions: Like fish shell vibes—Zsh can guess what you’re typing and finish your thought. Bash can’t do that natively.
    • Globbing on steroids: More powerful wildcard matching. Want to match all files with two digits and a .logextension? Zsh makes that easy.
    • Plugins & ThemesOh My Zsh turns Zsh into a productivity beast. You get Git status right in the prompt, syntax highlighting, fancy themes… Bash just feels barebones after.
    • Customization: Bash can be customized too, sure—but Zsh makes it easier and sexier.

    Downsides?

    Not much, unless you’ve got a pile of Bash scripts with weird quirks. Zsh is mostly compatible, but not 100%. You might have to tweak some syntax here and there.

    Also, Zsh’s .zshrc isn’t the same as .bash_profile or .bashrc, so your muscle memory might need a refresh.

    So, Which Should You Use?

    If you’re already neck-deep in Bash and it’s working? Stick with it.

    If you’re starting fresh or want something more modern and extensible? Zsh is the move. Especially if you’re living in Terminal daily. Install Oh My Zsh, pick a theme, grab some plugins, and feel like a hacker god.

  • Create Windows Installation Media on Mac

    Prepare the ISO File

    1. Download the Windows ISO file from Microsoft’s official site.

    2. Save it to a convenient location (e.g., your Desktop).

    Insert and Identify the USB Drive

    1. Insert the USB drive into your Mac.

    2. Open Terminal and type:

    diskutil list

    3. Find the device identifier for your USB (e.g., /dev/disk2). Make sure you identify the correct disk to avoid overwriting other drives.

    Unmount the USB Drive

    Run the following command to unmount the USB (replace /dev/diskX with your USB identifier):

    diskutil unmountDisk /dev/diskX

    Convert the ISO to a Hybrid Format (if needed)

    macOS doesn’t always work well with ISO files, so convert it to a .img format:

    diutil convert -format UDRW -o ~/Desktop/Windows.img ~/Desktop/Windows.iso

    This creates a Windows.img.dmg file on your Desktop. Rename it to Windows.img for simplicity:

    mv ~/Desktop/Windows.img.dmg ~/Desktop/Windows.img

    Write the ISO to the USB

    1. Use dd to write the image to the USB:

    sudo dd if=~/Desktop/Windows.img of=/dev/rdiskX bs=1m status=progress

    • Replace /dev/rdiskX with your USB identifier (use rdisk for faster writing).

    • if= specifies the input file (the Windows image).

    • of= specifies the output drive (the USB).

    • status=progress displays real-time progress.

    2. Be patient. This process may take a while, and there will be no progress indicator.

    Eject the USB

    Once dd is complete, eject the USB drive:

    diskutil eject /dev/diskX

    Test the USB

    Insert the USB into your Windows PC, and boot from the USB to ensure it works as install media. You may need to change the boot order in the BIOS/UEFI.

    ⚠️ Caution: The dd command can permanently erase data if used incorrectly. Double-check your disk identifier before running the command.