Build a Task Manager CLI with Claude Code

Use Claude Code to build a fully functional CLI task manager app.

Introduction

30 Second Summary

Everyone has a to-do list somewhere. What if you could build your own custom task management app just by describing what you want in plain English?

In this project, you will use Claude Code to build a personal task manager that runs in your terminal. You'll describe features in everyday language, and Claude Code will write all the code for you.

What You'll Build

A command-line task manager application built entirely through natural-language conversations with Claude Code.

By the end of this project, you'll have:

  • Claude Code installed and authenticated on your Windows machine, ready for any future project.
  • A working CLI task manager app that adds tasks, marks them complete, lists them, and persists data between sessions.
  • A CLAUDE.md project memory file and Git workflow that gives you a repeatable pattern for using Claude Code on real projects.
  • Secret Mission: Add a priority system with color-coded terminal output to your task manager.

Are there any prerequisites?

You'll need a Claude Pro ($20/month), Max ($100/month or $200/month), Team, or Enterprise subscription to use Claude Code. No coding experience or prior tool installations are required.

Before We Start

Before We Start...

Install Claude Code and Git

Claude Code is a terminal-based AI coding assistant that writes, edits, and runs code based on your natural-language instructions. To use it, you need two things installed on your Windows machine: Git (which gives Claude Code access to Bash tools and version control) and Claude Code itself.

In this step, you will install both tools and authenticate Claude Code with your subscription. Once this is done, your machine is ready for AI-assisted development.

In this step, get ready to:
  • Install Git for Windows.
  • Install Claude Code via PowerShell.
  • Authenticate Claude Code with your subscription.
Install Git for Windows

Git for Windows provides the Bash shell tools that Claude Code relies on for running commands. It also enables Claude Code's built-in Git integration for committing and managing code.

  • Press the Windows key to open your search bar.
  • Type PowerShell and press Enter to open it.

How do I know I'm in PowerShell?

Your prompt shows PS C:\ when you're in PowerShell. If you see C:\ without the PS prefix, you're in CMD instead. Make sure you are using PowerShell for this project.

  • Open the Git for Windows download page by visiting https://git-scm.com in your browser.
  • Click Download for Windows to download the installer.
  • Run the downloaded installer.
  • Accept the default options on each screen by clicking Next until you reach the final screen.
  • Click Install, then click Finish when installation completes.

Why accept the defaults?

The default options configure Git to work well with Windows tools like PowerShell. They also add Git to your system PATH so you can use it from any terminal window.

  • Close your current PowerShell window completely.
  • Open a new PowerShell window by pressing the Windows key, typing PowerShell, and pressing Enter.
  • Verify Git is installed by running this command:
git --version

✔️ I see a version number

You should see output like git version 2.54.0.windows.1 or similar. Git is installed and ready.

ⓧ Command not found

If PowerShell does not recognize the git command, try these fixes:

  • Make sure you opened a new PowerShell window after installing Git. Existing windows do not pick up PATH changes.
  • Re-run the Git installer and ensure the option Git from the command line and also from 3rd-party software is selected (this is the default).

After fixing, close and reopen PowerShell, then run git --version again.

Install Claude Code

Claude Code is installed through a single PowerShell command. The native installer also enables auto-updates, so you always have the latest version.

  • Install Claude Code by running this command in PowerShell:
irm https://claude.ai/install.ps1 | iex

What does this command do?

irm (short for Invoke-RestMethod) downloads the install script from Anthropic's servers. The | pipe passes it to iex (short for Invoke-Expression), which runs the script.

This downloads and installs Claude Code with automatic background updates enabled.

  • Wait for the installation to complete.
  • Close your PowerShell window completely.
  • Open a new PowerShell window by pressing the Windows key, typing PowerShell, and pressing Enter.
  • Verify Claude Code is installed by running:
claude --version

✔️ I see a version number

You should see Claude Code's version printed in the terminal. The installation is successful.

ⓧ Command not found

If PowerShell does not recognize claude, try these fixes:

  • Make sure you closed and reopened PowerShell after the install completed.
  • Try running the install command again: irm https://claude.ai/install.ps1 | iex.
  • If the issue persists, confirm you are in PowerShell (not CMD) by checking for the PS prefix in your prompt.

After fixing, close and reopen PowerShell, then run claude --version again.

Authenticate Claude Code

Claude Code needs to connect to your Anthropic account to work. On first launch, it will open your browser for a quick sign-in flow.

  • Start Claude Code by running:
claude

What happens on first launch?

Claude Code detects this is your first session and prompts you to log in. It will open your default browser with an authentication page. Sign in using the same account that has your Claude Pro, Max, Team, or Enterprise subscription.

  • Follow the browser-based authentication flow that opens automatically.
  • Sign in with the account linked to your Claude subscription.
  • Return to your PowerShell window after signing in.

Once authenticated, you should see the Claude Code welcome screen in your terminal. This confirms everything is connected.

  • Exit Claude Code for now by typing:
exit

Other ways to exit

You can also press Ctrl+D to close a Claude Code session at any time.

Authentication not working?

  • Make sure your browser is signed in to the correct Anthropic account (the one with a paid subscription).
  • If the browser did not open automatically, check PowerShell for a URL you can copy and paste manually.
  • If you need to re-authenticate later, type /login inside a running Claude Code session.

Still stuck? Help me troubleshoot Claude Code authentication on Windows.

Your machine is fully set up with Git and Claude Code. Next up, you will create your project folder and use Claude Code's Plan Mode to design your task manager before writing a single line of code.

Create Your Project and Enter Plan Mode

Claude Code is installed and ready to go. Now it's time to use it to build something real.

Before writing any code, you'll use Claude Code's Plan Mode to think through the architecture first. This "plan first, build second" approach produces better results than jumping straight to code.

In this step, get ready to:
  • Set up a project directory with Git initialized.
  • Use Plan Mode to design the task manager architecture.
  • Approve the plan and let Claude Code build the app.
Set up your project directory and initialize Git

Claude Code works best when it runs inside a Git repository. This gives it version control context and enables commit features you'll use later.

  • Move to your Desktop by running this command:
cd ~/Desktop
  • Create your project folder, move into it, and initialize a Git repository by running these commands:
mkdir task-manager
cd task-manager
git init
  • Confirm the folder was created by running:
ls

You should see an empty directory (the hidden .git folder won't show unless you run ls -Force).

Seeing an error with mkdir?

Make sure you're running PowerShell, not CMD. Your prompt should start with PS C:\ rather than just C:\.

If you accidentally ran these commands somewhere other than your Desktop, run cd ~/Desktop and try again.

help me troubleshoot my PowerShell directory setup

  • Start Claude Code inside your project by running:
claude

You should see the Claude Code welcome screen appear in your terminal. This means Claude Code is now running inside your task-manager directory and can read and create files here.

What does starting Claude Code in a directory do?

When you run claude inside a folder, Claude Code treats that folder as its working directory. It can read files, create new ones, and run commands scoped to this location.

Starting it inside an initialized Git repository also gives Claude Code access to Git integration features like committing and staging.

Enter Plan Mode to design the architecture

Plan Mode tells Claude Code to research and propose changes without making them. It will outline the file structure, persistence approach, and CLI commands before writing a single line of code.

  • Press Shift+Tab to cycle into Plan Mode. You should see the mode indicator in the status bar change to plan.

What is Plan Mode?

Plan Mode is a permission mode where Claude Code reads files and runs exploration commands, then presents a plan for approval before touching anything. It separates thinking from doing, so you can review the approach before any files get created.

Pressing Shift+Tab cycles through permission modes: default, acceptEdits, then plan. You may need to press it more than once to reach Plan Mode.

  • Type the following prompt into Claude Code and press Enter:
I want to build a CLI task manager in Node.js. It should let me add tasks, list all tasks, mark tasks as done, and delete tasks. Store tasks in a JSON file so they persist. Keep it simple - a single file script with no build tools.

Why this prompt works well

This prompt is specific about four things: the technology (Node.js), the features (add, list, done, delete), the persistence method (JSON file), and the constraint (single file, no build tools). Specific prompts produce better plans because Claude Code doesn't have to guess your intent.

  • Read through the plan Claude Code proposes. It will outline the file structure, the approach to persistence, and how the CLI commands will work.

Take a moment to review the architecture. Claude Code should propose something like a single tasks.js file with a package.json, storing tasks in a local tasks.json file.

Approve and execute the plan

Once you're satisfied with the plan, it's time to let Claude Code build the app. Approving the plan exits Plan Mode and lets Claude Code start creating files and running commands.

  • When Claude Code presents its plan and asks how to proceed, select the option to approve and review each edit manually. This keeps you in the loop as Claude Code creates each file.
  • If you prefer to exit Plan Mode first, press Shift+Tab to cycle back to default mode. Then type the following prompt:
Go ahead and build it.

What happens next?

Claude Code will create files, initialize a package.json, install any dependencies it needs, and write your task manager script. It asks for permission before each file write and command execution.

When Claude Code asks to write a file or run a command, review what it's doing and approve each action. This is the default behavior so you can see exactly what changes are being made.

  • Approve each permission request as Claude Code creates your project files. Watch as it sets up package.json, writes the tasks.js script, and installs any dependencies.
  • Wait for Claude Code to finish building. It will let you know when the implementation is complete.

Why does Claude Code keep asking for permission?

Claude Code always asks for permission before modifying files or running commands. This safety model means you can review every change before it happens. You can approve individual actions one at a time, which is recommended while you're learning.

Once Claude Code finishes, your task-manager folder should contain a package.json and a tasks.js file (plus a node_modules folder if dependencies were installed).

Claude Code didn't create the files?

Make sure you approved each permission request. If you accidentally denied a request, give Claude Code the same prompt again and approve the actions this time.

If Claude Code seems stuck or confused, type exit to close the session, then run claude again and re-enter your prompt from the beginning.

help me troubleshoot why Claude Code didn't create my task manager files

Your task manager app now exists as real files on your machine. Next up, you'll test it and learn how to iterate when something isn't quite right.

Test and Iterate on Your App

Claude Code has built your task manager, but you haven't seen it in action yet. Testing is how you discover what works and what needs refinement.

In this step, you'll run your app, give Claude Code specific feedback to improve the output formatting, and commit your progress using Git.

In this step, get ready to:
  • Run the task manager and verify it works.
  • Iterate on the output formatting with targeted feedback.
  • Commit your changes using Claude Code's Git integration.
Run your task manager

Your task manager exists as code in tasks.js, but you need to see it working to know it's correct. You'll ask Claude Code to run it, add a task, and confirm everything persists.

  • In your Claude Code session, type the following prompt and press Enter:
Run the task manager and show me the help output. Then add a task called "Learn Claude Code" and list all tasks to confirm it worked.

What will Claude Code do?

Claude Code will ask permission to run terminal commands on your behalf. You'll see prompts like "Claude wants to run: node tasks.js --help" with options to accept or reject.

Approve each command. Claude Code will run the app, show you the help text listing available commands, then add a task and display the list to prove persistence is working.

  • Look at Claude Code's output after it runs the commands.
  • You should see help text listing available commands (add, list, done, delete), followed by a confirmation that "Learn Claude Code" was added, and finally a task list showing your new task.

What is tasks.json?

When you added your first task, the app created a tasks.json file in your project folder. This is a simple JSON file that stores your tasks so they survive between sessions. Every time you add, complete, or delete a task, the app writes the updated data to this file.

Claude Code asked a clarifying question instead of running?

Sometimes Claude Code will ask a follow-up question instead of acting immediately. Answer its question directly, and it will proceed with running the commands.

If you see an error about a missing dependency, tell Claude Code to install it and try again. Specific corrections are always better than starting over.

Help me troubleshoot why my task manager isn't running correctly in Claude Code

Iterate with specific feedback

The default list output is functional but hard to scan quickly. This is where Claude Code's iteration loop shines. Instead of rewriting code yourself, you give specific feedback and Claude Code modifies the existing code while preserving everything that already works.

  • Type this prompt into your Claude Code session:
The list output is hard to read. Format it as a numbered table with columns for ID, Status, and Task Name. Use checkmarks for done tasks and empty boxes for pending ones.

Why specific feedback beats vague requests

Notice that this prompt names exactly what's wrong ("hard to read") and exactly what you want instead (numbered table, specific columns, checkmarks vs empty boxes). Targeted corrections like this produce better results than vague requests like "make it look nicer."

This is the core skill of working with Claude Code. The more specific your feedback, the fewer iteration cycles you need.

  • Approve the file changes when Claude Code asks permission to modify tasks.js.
  • After Claude Code finishes, ask it to list your tasks again so you can see the new formatting.
  • You should see a clean table with numbered rows, a Status column (with an empty box next to "Learn Claude Code" since it's still pending), and a Task Name column.

Formatting doesn't look right?

If the table is misaligned or missing columns, give Claude Code another specific correction. For example: "The Status column is too wide. Shrink it to just the checkmark character."

Help me fix the table formatting in my Claude Code task manager

Commit your progress with Claude Code

Claude Code works directly with Git. It can stage changes, write commit messages, and create branches without you leaving the session.

  • Type this prompt to commit your work:
Commit all changes with a descriptive commit message.

What does Claude Code do with this?

Claude Code will stage all your files (package.json, tasks.js, and tasks.json), write a commit message that describes what was built, and commit. It will show you the commit message before executing so you can approve it.

  • Approve the Git commands when Claude Code asks permission.
  • You should see a confirmation that the commit was created, along with the commit message Claude Code wrote.

Seeing a Git error about user identity?

If Git complains about missing user.name or user.email, tell Claude Code to configure them for you. For example: "Set my Git user name to My Name and email to my@email.com, then try the commit again."

Help me fix a Git identity error when committing through Claude Code

Your task manager is tested, polished, and committed. Next up, you'll create a CLAUDE.md file that gives Claude Code persistent memory about your project preferences.

Create Your CLAUDE.md Project Memory

Your task manager is working and committed to Git. You've experienced the core loop of prompting, testing, and iterating with Claude Code.

Now it's time to give Claude Code long-term memory. Every time you start a new session, Claude Code starts fresh with no knowledge of your preferences or project decisions. A single file called CLAUDE.md solves this problem by giving Claude Code persistent context it reads automatically.

In this step, get ready to:
  • Create a CLAUDE.md file that documents your project's stack and preferences.
  • Verify that Claude Code reads your CLAUDE.md on startup.
  • Commit the CLAUDE.md file to your Git repository.
Understand what CLAUDE.md does

CLAUDE.md is a plain-text Markdown file at the root of your project that Claude Code reads automatically at the start of every session. It gives Claude persistent context about your project so you never have to re-explain your preferences.

  • In your active Claude Code session, ask Claude Code to create a CLAUDE.md by entering this prompt:
Create a CLAUDE.md file for this project. It should document: the stack (Node.js CLI, no frameworks, JSON file storage), my naming conventions (camelCase for variables, kebab-case for filenames), and a note that I prefer small, focused changes with explanations after each modification.
  • Claude Code will ask for permission to create the file. Approve it.

What is CLAUDE.md?

Think of CLAUDE.md as a briefing document you hand to a new team member on day one. It tells Claude Code how your project is structured, what conventions you follow, and how you like to work.

The value compounds over time. As your project grows, you can add architecture notes, common commands, and testing instructions. Every future session starts with that context already loaded.

After Claude Code creates the file, you should see CLAUDE.md listed in your task-manager folder alongside your existing files.

Claude Code didn't create the file?

Make sure you approved the file-creation permission when Claude Code asked. If you accidentally denied it, re-enter the same prompt and approve this time.

If Claude Code seems confused about the project, check that your terminal is still in the task-manager directory.

Why isn't Claude Code creating my CLAUDE.md file?

Verify the memory works

The real test is whether Claude Code picks up your CLAUDE.md in a fresh session. To check this, you need to exit and restart Claude Code.

  • Exit your current Claude Code session by typing:
exit
  • Start a fresh Claude Code session by running this command in PowerShell:
claude

Claude Code now reads your CLAUDE.md at session start. You should see it reference the file as it loads.

  • Test that the memory is working by entering this prompt:
What do you know about this project?

Claude Code should respond with details from your CLAUDE.md file. It should mention the Node.js CLI stack, your naming conventions (camelCase for variables, kebab-case for filenames), and your preference for small changes with explanations.

Claude Code doesn't mention your preferences?

Make sure the CLAUDE.md file is in the root of your task-manager folder, not inside a subfolder. Claude Code only reads it from the project root.

Also check that the file is named exactly CLAUDE.md with all caps. A lowercase claude.md won't be recognized.

Why isn't Claude Code reading my CLAUDE.md file?

Commit your CLAUDE.md

Your CLAUDE.md is part of your project, so it belongs in Git alongside your code. This way it stays versioned and travels with your repository.

  • Ask Claude Code to commit the new file by entering this prompt:
Commit the CLAUDE.md file with the message "Add project memory file"
  • Claude Code will stage the file and create the commit. Approve the action when prompted.

What does this commit do?

Claude Code stages CLAUDE.md with git add and commits it with the exact message you specified. You now have two commits in your repository: the initial app commit and this one for project memory.

You should see Claude Code confirm the commit was created successfully.

Commit failed?

If Claude Code reports an error about Git configuration, it may need your name and email set. Ask Claude Code to configure them for you by saying: "Set my Git name to [your name] and email to [your email], then try the commit again."

Why did my Claude Code Git commit fail?

You now have persistent project memory set up. Every time you start Claude Code in this folder, it already knows your stack, conventions, and working preferences. Next up, you'll use the full workflow (Plan Mode, build, test, commit) to add a brand new feature.

Add a Feature Using the Full Workflow

Your task manager works, your CLAUDE.md is loaded, and your commits are clean. Now it's time to put the full workflow together from start to finish.

In this step, you'll add a search feature to your task manager by following the complete Claude Code development cycle: plan the feature in Plan Mode, build it, test it, and commit it. This is the repeatable pattern you'll use on every future project.

In this step, get ready to:
  • Plan a search feature using Plan Mode.
  • Build and test the feature through conversational prompts.
  • Commit the finished feature using Claude Code's Git integration.
Plan a new feature

Every new feature starts with a plan. Plan Mode lets Claude Code research and think through an approach without changing any files. This gives you a chance to review the design before any code is written.

  • In your Claude Code session, press Shift+Tab to cycle into Plan Mode.

You'll see the mode indicator change to confirm you're in Plan Mode.

  • Give Claude Code this prompt describing the search feature:
I want to add a "search" command that lets me find tasks by keyword. It should search both the task name and show matching results in the same table format.

What happens in Plan Mode?

Claude Code will outline the file structure changes, explain its approach to keyword matching, and show how the search results will use your existing table format. It won't create or modify any files yet.

Review the plan to make sure it makes sense. If something looks off, you can ask Claude Code to adjust its approach before any code is written.

Specificity matters in prompts

Notice how the prompt says "the same table format" instead of just "show results." The more specific you are about the output format, the fewer iterations you'll need later.

Execute and test the feature

Once you're happy with the plan, it's time to let Claude Code build the feature and prove it works.

  • Press Shift+Tab again to exit Plan Mode and return to normal mode.
  • Tell Claude Code to build and test the feature by entering this prompt:
Build the search feature, then demonstrate it by searching for "Claude" in my tasks.

What should I see?

Claude Code will modify tasks.js to add the search command, then run it to show you results. It will ask for permission before writing files or executing commands. Approve each action.

You should see a table of tasks matching the keyword "Claude" (including the "Learn Claude Code" task you added earlier). The output should use the same numbered table format with ID, Status, and Task Name columns.

Search not finding your task?

Make sure you previously added a task containing the word "Claude" (from Step 3). If your tasks.json is empty, add a task first by asking Claude Code to run the add command, then try the search again.

If the output format doesn't match the list command's table, give Claude Code specific feedback: "Make the search output use the exact same table format as the list command."

Help me troubleshoot my Claude Code search feature

Commit the feature

The final step of the cycle is saving your work with a meaningful commit. Claude Code's Git integration handles staging, writing a commit message, and committing in one go.

  • Ask Claude Code to commit the search feature:
Commit this feature with an appropriate message.
  • Review the commit message Claude Code proposes before approving.

Claude Code will stage the modified files and commit with a descriptive message about the search feature. Your project now has three clean commits.

Why clean commits matter

Each commit captures one logical change: the initial app, the project memory file, and the search feature. This makes it easy to roll back a single feature without losing everything else.

Commit failed or nothing to commit?

If Claude Code says there's nothing to commit, the changes may have been committed earlier. Run git log --oneline to check your commit history.

If you see a Git error about identity, Claude Code may need your Git name and email configured. Ask it: "Set up my Git config with the name Student and email student@example.com, then commit."

Help me fix my Git commit in Claude Code

You've now completed the full Claude Code development cycle: plan, build, test, commit. This is the same pattern you'll use for every feature on every project. Next up, you'll put this workflow to the ultimate test in the Secret Mission.

Secret mission

Add Priorities and Color-Coded Output

You've mastered the core Claude Code workflow. Now push yourself further by adding a priority system to your task manager. With a single detailed prompt, you'll add color-coded output, priority sorting, and filtering.

Clean Up Your Resources

Clean Up Your Resources

This project runs entirely on your local machine, so there are no ongoing costs or cloud resources to worry about. Decide whether to keep your files and tools, or remove them.

Resources you used:

  • The task-manager project folder on your Desktop (contains your app code, CLAUDE.md, and tasks.json).
  • Claude Code CLI tool (installed via the native PowerShell installer).
  • Git for Windows (installed during setup).

Keep everything running

No action needed. Choose this if you plan to keep using your task manager or want to build on it further.

  • Your task-manager folder stays on your Desktop, ready to use anytime.
  • Claude Code stays installed and will auto-update in the background. Run claude in any project folder to start a new session.
  • Git for Windows remains available for any future projects that use version control.

Pause - I'll come back to this later

Since everything is local, there is nothing consuming resources while idle. Your files sit on disk until you return.

  • No processes to stop. The task manager only runs when you explicitly call it.
  • Your task-manager folder, Claude Code, and Git for Windows all remain installed and ready when you come back.

Delete - I don't want to use this again

Remove all project files and optionally uninstall the tools you set up during this project.

  • Delete the project folder by running this command in PowerShell:
  • Uninstall Claude Code by removing the binary and its data. Run these commands in PowerShell:
  • Uninstall Git for Windows through Windows settings.

That's a Wrap!

That's a Wrap!

Nice work! You just built a real CLI tool using nothing but natural-language prompts to Claude Code.

You've learned how to:

  • Built a fully functional CLI task manager app entirely through conversational prompts.
  • Used Plan Mode to think through architecture before writing any code.
  • Created a CLAUDE.md project memory file that gives Claude Code persistent context across sessions.
  • Added a priority system with color-coded terminal output through a single detailed prompt.

Ready to quiz yourself?