DEV Community

Cover image for How I Fell in Love with Claude Code (And Why You Might Too)
Adrian Jiga
Adrian Jiga

Posted on

How I Fell in Love with Claude Code (And Why You Might Too)

I've always been curious about AI coding tools. Like most developers, I saw the hype, tried a few chat-based assistants, and found myself spending more time copying and pasting code between windows than actually solving problems. It felt clunky. I kept going back to my old workflow because it was just... faster.

Then I tried Claude Code, and something changed.

What even is Claude Code?

Claude Code is a command-line tool from Anthropic. You install it, run claude in your terminal, and suddenly you have an AI that can actually see your project, read your files, run commands, and make changes directly. No more copy-pasting. No more explaining your folder structure. It just works with what's already there.

Install

The native installer is the recommended way to install Claude Code. It doesn't require Node.js.

macOS / Linux:

curl -fsSL https://claude.ai/install.sh | bash
Enter fullscreen mode Exit fullscreen mode

Windows (PowerShell):

irm https://claude.ai/install.ps1 | iex
Enter fullscreen mode Exit fullscreen mode

Alternative: npm (if you prefer)

If you'd rather use npm, you'll need Node.js 18 or higher:

npm install -g @anthropic-ai/claude-code
Enter fullscreen mode Exit fullscreen mode

Note: Don't use sudo with npm install as it causes permission issues.

After installation, verify it worked:

claude --version
Enter fullscreen mode Exit fullscreen mode

You should see something like:

2.1.22 (Claude Code)
Enter fullscreen mode Exit fullscreen mode

Authentication

Before you can use Claude Code, you need to authenticate. You have two options:

Option 1: Claude Pro or Max subscription (recommended)

If you have a Claude Pro or Max subscription, just run:

claude
Enter fullscreen mode Exit fullscreen mode

It will open your browser for a one-time OAuth login with your Claude account.

Option 2: API key

If you're using the Anthropic API directly, set your key:

export ANTHROPIC_API_KEY="your-api-key-here"
Enter fullscreen mode Exit fullscreen mode

Add this to your ~/.bashrc or ~/.zshrc to make it permanent. Then reload your shell config:

# If using bash
source ~/.bashrc

# If using zsh
source ~/.zshrc
Enter fullscreen mode Exit fullscreen mode

Starting your first session

Navigate to any project folder and start Claude Code:

cd ~/projects/my-cypress-tests
claude
Enter fullscreen mode Exit fullscreen mode

You'll see a welcome screen and a prompt where you can start typing:

╭─────────────────────────────────────────╮
│ Claude Code                             │
╰─────────────────────────────────────────╯

>
Enter fullscreen mode Exit fullscreen mode

Now you can just type what you want Claude to do:

> Explain the structure of this project
Enter fullscreen mode Exit fullscreen mode

It will read your files and give you an overview. From here, you can ask follow-up questions, request changes, or have it run commands.

My first real use case

I was stuck on a problem that had been eating my afternoon. After upgrading a dependency in one of my projects, a bunch of tests started failing. The error messages weren't helpful, and I couldn't figure out what had changed.

Out of frustration, I opened Claude Code and just typed something like "these tests broke after I upgraded xmlbuilder2, can you help me figure out why?"

What happened next surprised me. It didn't just throw generic suggestions at me. It asked to look at my package.json, examined the failing tests, checked what changed between versions, and found the issue. A method signature had changed in the new version. It even offered to fix it.

Two minutes. I'd been stuck for two hours.

Why it clicked for me

It understands context. This is the big one. When I'm working on my Cypress tests, Claude Code sees my actual project. It knows I'm using Cypress, not Playwright. It sees my folder structure, my custom commands, my fixtures. When it suggests something, it fits.

It lives in the terminal. So much of my work happens in the terminal anyway: running tests, checking logs, debugging CI pipelines. Having an AI right there, in the same environment, just makes sense. I can run a test, see it fail, and immediately ask "why did this fail?" without switching windows.

It learns my patterns. After working with it on a few files, it picked up how I structure my tests, my naming conventions, how I organize things. When I ask it to write something new, it feels like my code, not generic AI output.

Some real examples

Here are some actual things I've used it for.

Debugging test failures

When a test fails and the error isn't helpful, I can pipe the output directly to Claude Code:

npx cypress run --spec "cypress/e2e/api/orders.cy.js" 2>&1 | claude "The test on line 45 is failing with 'expected undefined to equal 200'. Can you check why?"
Enter fullscreen mode Exit fullscreen mode

It reads the test output, examines the test file, sees the API response structure, and usually spots the issue, like a response property that got renamed or nested differently.

Generating tests from existing patterns

Let's say I have a working test for one integration and need a similar one for another. Instead of copy-pasting and manually changing things:

> Create a new test file for the Jaggaer integration following the same pattern as cypress/e2e/integrations/coupa.cy.js
Enter fullscreen mode Exit fullscreen mode

It reads the existing test, understands the structure, and generates a new file with the right assertions and setup. I just review and tweak if needed.

Converting API tests to Postman

This one saved me a lot of time. I had Cypress tests with all our API calls and the dev team wanted a Postman collection:

> Convert the API calls in cypress/e2e/api/orders.cy.js to a Postman collection JSON file
Enter fullscreen mode Exit fullscreen mode

It extracted all the requests, preserved headers and bodies, and even set up environment variables for things like {{baseUrl}}. Two minutes instead of an hour.

Fixing CI pipeline issues

GitHub Actions failing with weird bash errors? Just paste the error:

> My GitHub Action is failing with this error:
> /home/runner/work/_temp/script.sh: line 3: unexpected EOF while looking for matching `"'
> Can you help me fix it?
Enter fullscreen mode Exit fullscreen mode

It explained that my heredoc syntax was being interpreted by the shell and gave me the corrected version with proper quoting.

Quick refactors

Need to rename something across multiple files or update an import pattern?

> Rename the function "getOrderData" to "fetchOrderDetails" in all files under cypress/e2e/
Enter fullscreen mode Exit fullscreen mode

It shows you what it's going to change, you confirm, and it's done.

Useful one-liners

You can also run Claude Code with a direct prompt instead of starting an interactive session:

# Explain what a file does
claude "explain what cypress/support/commands.js does"

# Find potential issues
claude "review cypress/e2e/checkout.cy.js for flaky test patterns"

# Generate something quick
claude "add a custom command to cypress/support/commands.js that waits for an API response"
Enter fullscreen mode Exit fullscreen mode

This is handy when you just need a quick answer or a single change.

Slash commands

Inside an interactive session, Claude Code has built-in slash commands:

/help          - Show all available commands
/clear         - Clear the conversation history
/compact       - Condense conversation to save context
/config        - View or modify settings
/cost          - Show token usage and estimated cost
/doctor        - Check your installation health
/init          - Create a CLAUDE.md file for your project
/review        - Request a code review
/exit          - Exit Claude Code
Enter fullscreen mode Exit fullscreen mode

The /init command is especially useful. It creates a CLAUDE.md file in your project that helps Claude understand your codebase, conventions, and preferences.

What I appreciate most

It asks before changing things. It shows you what it wants to do and waits for you to say yes. This matters when you're working on real projects.

It admits when it's not sure. I've had it tell me "I'm not certain about this specific behavior—want me to check the docs?" That honesty builds trust.

It remembers what you're working on. Within a session, I can say "actually, apply that same fix to the other files too" and it knows exactly what I mean.

It's not magic

I want to be honest here. It's not perfect. Sometimes it suggests things that don't quite work. Sometimes it misunderstands what I'm asking for. Complex refactors still need oversight.

But it's wrong way less often than I expected. And when it is wrong, explaining why usually gets it to a working solution quickly.

Conclusion

I was skeptical of AI coding tools for a long time. Too much hype, too many demos that didn't hold up on real projects. Claude Code changed how I think about this.

That progression skepticism -> curiosity -> trying it on a real problem -> actually relying on it happened faster than I expected. It's the tool that took debugging from frustrating to manageable, and repetitive tasks from draining to quick.

If you've been curious about AI coding assistants but found them clunky, give Claude Code a try. Start with something that's been frustrating you. You might be surprised.

More information

You can find more usage patterns and documentation here:

Top comments (0)