Today I Learnt

June 2025

  • What is Claude?

    Claude is Anthropic's AI assistant that comes in multiple forms:

    - Claude Console (web interface at claude.ai)

    - Claude Code (terminal-based coding assistant)

    - Claude API (for developers)

    Setting Up Claude Console (Web Interface)

    1. Visit claude.ai in your browser

    2. Sign up with email or Google account

    3. Verify your email if required

    4. Start chatting immediately - no additional setup needed

    The web console is perfect for general questions, writing, analysis, and casual coding

    help.

    Setting Up Claude Code CLI (Terminal)

    Claude Code is a powerful terminal-based coding assistant that can edit files, run tests,

    and understand your entire codebase.

    Prerequisites

    - macOS with Terminal

    - Node.js installed (get it from nodejs.org)

    - An Anthropic API key

    Installation Steps

    1. Install Claude Code globally:

    You will need npm so the easiest way on OSx is

    brew install npm

    npm install -g @anthropic-ai/claude-code

    2. Navigate to your project:

    cd /path/to/your/project

    3. Start Claude Code:

    claude

    4. First-time setup:

    - You'll be prompted to enter your API key

    - Get your API key from console.anthropic.com

    - The key will be saved for future use

    What Claude Code Can Do

    - Edit multiple files across your codebase

    - Run and fix failing tests

    - Search through git history

    - Answer architecture questions

    - Browse documentation

    - Execute terminal commands

    Pro Tips for macOS Users

    - Use Tab for command completion

    - Press ↑ for command history

    - Use Cmd+K to clear terminal

    - Claude Code works great with VS Code, Xcode, and other macOS dev tools

    Getting Your API Key

    1. Go to console.anthropic.com

    2. Sign in to your account

    3. Navigate to API Keys section

    4. Click Create Key

    5. Copy and save your key securely

    Quick Start Commands

    Once Claude Code is running, try these:

    "what does this project do?"

    "show me the main entry point"

    "help me add error handling to the login function"

    "run the tests and fix any failures"

    Why This Setup Rocks

    - Web Console: Perfect for brainstorming and quick questions

    - CLI Tool: Incredible for actual coding work

    - Native macOS: Integrates seamlessly with your existing workflow

    - Secure: Direct API connection, no data leaves your machine unnecessarily

  • TIL: Nushell for Log Analysis (Almost)

    Today I explored using Nushell to analyze logs from a system where the data was almost structured. My hope was to leverage Nushell's data-first pipeline model (open log | from json | where ...) for efficient filtering and summarization.

    Unfortunately, the log format wasn’t structured enough to process directly with Nushell’s native tools. However, with a quick AI-assisted Python script, I was able to parse the raw logs into structured JSON. Once in that format, Nushell handled the rest beautifully—tabular views, filters, and summaries worked exactly as expected.

    I’m still working on a native Nushell function to preprocess this log format without external scripts, but for now, this hybrid approach worked well.

    📌 Lesson: If your logs are close to structured, Nushell can be a powerful tool—but a little preprocessing goes a long way.

  • After decades of loyalty to zsh—faithfully paired with oh-my-zsh and a tangle of plugins for autocomplete and command enhancements—I’ve started to rethink my shell setup. Don’t get me wrong: it worked, and it worked well. But the complexity crept in, mostly thanks to the ever-growing constellation of plugins. Managing them began to feel more like maintaining a legacy novel's footnotes than enjoying the actual prose.

    Enter Fish (🐟 fishshell.com): a modern shell that mimics much of zsh’s feature set, including smart suggestions and plugin-like behavior, but with a simpler, more elegant core. It’s not POSIX-compliant, sure—but for my day-to-day, that’s a tradeoff I’m willing to make.

    As for the prompt (because, yes, aesthetics do matter), I discovered Starship: a cross-shell prompt that’s fast, beautiful, and effortlessly informative. It works across environments and adds just the right touch of visual clarity without bloating your setup.

    If your terminal feels like it's doing too much behind the scenes—or worse, if you're spending more time debugging plugins than writing commands—it might be time for a refresh.