Claude Code - Full Tutorial for Beginners
By Tech With Tim
Summary
Topics Covered
- CLI Trumps Desktop for Serious Coding
- Git Checkpoints Save AI Mistakes
- Planning Prevents AI Coding Chaos
- Claude.md Enables Persistent Memory
Full Transcript
This video will teach you claude code.
I'll go over everything and assume no prior knowledge. I'll walk you through
prior knowledge. I'll walk you through the setup and installation step by step.
I'll show you how to utilize the tool, the best practices, multiple features, and by the end of the video, you'll be comfortable using this tool to generate some pretty insane outputs and awesome
coding projects. So, with that said,
coding projects. So, with that said, let's get into it. So without getting into too many details, Claude Code is effectively a command line or terminal application that allows you to generate
code, debug projects, make websites, create applications, whatever it is that you want. It is effectively Anthropic's
you want. It is effectively Anthropic's version of, you know, cursor or something, right? Where you can generate
something, right? Where you can generate a bunch of code using the terminal. Now,
this is promptbased coding, which means you don't need to actually write any of the code yourself. You simply type to an AI agent. You tell it what your desired
AI agent. You tell it what your desired output is and then it goes ahead and starts coding. Now, oftent times Claude
starts coding. Now, oftent times Claude Code will be used in combination with other developer tools and I'll show you a few of them in this video, but generally speaking, you do not need to be an expert to use this. And even as a
complete beginner, you can create some really cool projects. So, with that said, let's look at how we set it up.
Now, in order to get Claude Code working, you are going to need a Claude subscription, which is paid. So, you're
going to need a Pro, Max, Teams, or Enterprise subscription or an API key with some tokens or credits from the Claude console. Now, I would suggest
Claude console. Now, I would suggest that if you're just looking to mess around with this, get the cheapest plan from Claude. You will run out of credits
from Claude. You will run out of credits pretty quickly if you are using this for very heavy work, but of course, test it first before you start going and buying a bunch of different credits. It also
matters what model you're using, which we'll talk about later, which will determine what the overall price for all of the prompts that you send is going to be. Now, generally, you're not going to
be. Now, generally, you're not going to be overbuild. you'll just run out of
be overbuild. you'll just run out of credits and then you would have to buy more. So, don't worry about that. Okay.
more. So, don't worry about that. Okay.
Now, to install this is going to require that we work directly inside of the terminal. So, what we're going to do is
terminal. So, what we're going to do is we're going to open up a terminal or a command prompt or a PowerShell instance depending on the operating system that you're working on. Now, if you are on Windows, then I'm going to suggest that
you open up PowerShell. So, you can go to the Windows search bar, search for PowerShell, and then open up a terminal like this. And I will just put it on the
like this. And I will just put it on the right hand side of my screen. Now, if
you're on Mac or Linux, then open up a normal terminal. So, just type terminal
normal terminal. So, just type terminal in the spotlight search, and then you'll be in an environment where you can start using cloud code. Now, in order to install this, I'm going to leave this documentation in the description, which gives you the commands that you can
simply copy depending on your operating system. So, if you are on Mac or Linux,
system. So, if you are on Mac or Linux, then you can copy this curl command right here. Just paste it into your
right here. Just paste it into your terminal and run it. If you're on Windows and you're using PowerShell, as I suggested, then you can copy this irr command. You can paste it, hit enter,
command. You can paste it, hit enter, and it should install Claude Code for you. If you're using the command prompt,
you. If you're using the command prompt, maybe you're on an older version of Windows, then you can copy this version right here, paste it in the command prompt. Again, it will install the tool.
prompt. Again, it will install the tool.
Claude Code is not a desktop application. It actually runs directly
application. It actually runs directly inside of your shell or your terminal.
So, in order to use this in the future, you will need to open up PowerShell again or Terminal again or use this from some kind of tool in order to actually interact with Claude and generate code.
Now, once it says it's installed, the way that you can test this is by simply typing claude in your terminal. So, if
you type claude, you should get some kind of output here. Now, when you first run this, it will ask you to authenticate with your Anthropic or Claude account. So, just do that. Go
Claude account. So, just do that. Go
into your browser, sign into your account, and then you'll be good to go.
Now, also, whenever you run this for the first time and you type that command, it's going to ask you to trust the current folder that you're inside of.
So, we're going to go ahead and press on yes, I trust the folder, and then it's going to bring up the Claude Code UI.
Now, at this point, you should have got Claude code installed. And just
remember, if you were to close the terminal or the PowerShell, you would have to reopen this, right? I'm just
going to zoom in. And then again, type claude. And then you can press enter.
claude. And then you can press enter.
And again, you'll get back into that user interface. So, don't worry if you
user interface. So, don't worry if you lose it. Now, for some of you that are
lose it. Now, for some of you that are complete beginners and already this is a little bit intimidating, Enthropic actually did create an easier way to write code using Claude. It is not the same thing as cloud code, but it is very
similar. And you can access that by
similar. And you can access that by downloading the desktop app for Claude.
So if you have an account with them, you can just download the desktop app. If
you do that, the app will look something like this. From here, what you'll be
like this. From here, what you'll be able to do is switch between this chat and this code mode. And if you go into the coding mode here, you'll be able to select a project. You can write a prompt
directly inside of here. You can change the mode like coding, asking, planning, right? You can add uh different files.
right? You can add uh different files.
You can connect it to GitHub. You can
choose your model. and it's a lot simpler and easier to use. So again, if you're a beginner, you can just use this. But if you want to get any serious
this. But if you want to get any serious work done, the CLI or the command line tool, which I'm showing you, is what you're going to want to set up and have on your machine. Now, if you've been programming for a while, you probably know the job market is tough recently,
and you may feel like traditional résumés just don't show who you really are as a creator or a technologist. Now,
that's where DinkMe comes in. It's a
brand new AI native career network built for the real era of real work, real projects, real impact, not just job titles. Now, instead of a static resume,
titles. Now, instead of a static resume, Dink gives you a living identity card, your Dink card, that automatically showcases your code, papers, citations, and measurable impact across platforms
like GitHub and Google Scholar.
Recruiters, professors, and startups can discover what you've actually done, not just what you wrote on paper. Now,
that's what Dink does for you. But for
companies, Dink is an AI powered talent engine that analyzes and compares researchers and engineers in seconds. It
helps teams spot the best fits faster than traditional recruiting tools. Now,
the best part of all of this is that you can claim your DIN card for free. Start
building your personal identity in minutes and let your work speak for itself in a world where RS get screened for 6 seconds before a decision. Now,
here you can even see my DIN card right here. has all of my details, information
here. has all of my details, information that you wouldn't see on a resume, my whole career trajectory, my GitHub, the number of stars, my YouTube channel, Instagram, all of that stuff is here, as
well as networks, career trajectory, Twitter, and anything else that you want to include. Now, you can get started
to include. Now, you can get started with Dink today for free by clicking the link in the description, and a massive thanks to them for sponsoring today's video. Let's get back into it. Now, with
video. Let's get back into it. Now, with
that in mind, before you just go crazy here with Claude, what I'm going to suggest that you do is install Git on your computer. Now, Git is a tool that's
your computer. Now, Git is a tool that's going to allow you to essentially kind of checkpoint what Claude is doing and revert back to a previous version of your codebase in case it makes any mistakes. You won't have it by default
mistakes. You won't have it by default on your machine. So, you do need to install it. Now, you can do that by
install it. Now, you can do that by going to the link that I'll put in the description where you can download this for Windows, Mac, or Linux. However,
because we have Claude code, we actually can just ask Claude Code, can you install Git for me? Now, if you do that, it should actually think about the commands that it's going to need to run to install this for you. It should
likely ask you for permission. So, you
can see here it's asking for permission to run a command. I'm going to go yes, and don't ask for this command again.
And then it's going to actually run the command to install that tool for you.
Now, for some reason that doesn't work, then what you can do is just install it directly from the website right here.
Okay. So in my case, it actually gave me an error that said that I need to be running PowerShell as an administrator in order to actually run this command.
So if you get an error like that, no worries. What you can do is you can just
worries. What you can do is you can just open PowerShell by pressing rightclick and then run as administrator. Now, if
you're running this in Mac, it should be good to go by default. But here, what I'm going to do is just type claude.
Okay, I'm going to go yes, I trust this folder. And then same thing, install git
folder. And then same thing, install git for me. And let's see if it's able to do
for me. And let's see if it's able to do it now that I gave it the permissions.
All right, so I just got get installed.
I'm not going to go through the whole process. And the next thing that I do
process. And the next thing that I do recommend that you do is create a GitHub account. The reason why we'll want to
account. The reason why we'll want to make a GitHub account is we're going to connect Claude to GitHub so that it's able to actually create new repositories for us and save all of the code that we're writing from the very beginning so
that we don't lose anything. Now, GitHub
is essentially a website or kind of a remote location where we can store different code. So rather than just
different code. So rather than just having it on our own computer, we can store it with GitHub where we can access it from another machine. We can share it with another developer. And more
importantly, if we lose access to maybe our own computer or maybe we delete the folder or Claude messes up or something, we can always get the repository or the code again by going to this website. So
go to GitHub, make an account. It is
completely free. And I'm going to just quickly show you how to connect your GitHub account to your terminal here locally so that you're able to use it um kind of with Claude. All right. All
right. So, in order to connect Git, which is running on our local computer, to GitHub, which is running in the web, what we need to do is run the following command, which is gh login. Now, notice
that I didn't know how to do this. So, I
just asked claude code. And it told me exactly what to run. So, what I'm going to do is type gh log in like so. And
then it should run this command for me and allow me to connect to GitHub. Okay.
So, you can see that it's going to ask to run the command. So, let's go ahead and type on yes. And in this case, gh was not found. So it should go ahead and install that for me. So I'm just going to type option C so it can install that
tool for me. Okay. So it looks like it was able to install that. And then I'm going to go yes so that it can run that command. All right. So notice it's
command. All right. So notice it's giving me some output here where it says it wants me to go to this URL and then type in our one-time code. So what we are going to do here is go we're going to select the account. So I'm going to
go with tech with Tim. And then I'm going to copy this code that it's given me here. So just copy that and paste it
me here. So just copy that and paste it and press continue. And that should then authorize GitHub here in our terminal.
Now, in order to do that, I need to just off with mobile. So, let me do that. All
right. So, it looks like we are all authenticated now. You can see that I
authenticated now. You can see that I was logged in as tech with Tim. And now
we have GitHub set up. I know it is a little bit of a pain to do this at the beginning, but trust me, it is absolutely worth it because now anytime we use Claude, it can automatically save the code for us. A lot of other tutorials don't cover this. That's why
you're watching mine because I want to go through it step by step and I want you to get set up in one single video.
Now, I promise we can move on to some more features. Okay, so let me close my
more features. Okay, so let me close my browser. Let's open up Claude Code a
browser. Let's open up Claude Code a little bit larger. And I want to show you how most developers actually work with Claude Code. Now, rather than just using the terminal here, a lot of times you're going to use this with a
development environment. What I mean by
development environment. What I mean by that is you're likely going to use an editor like VS Code or Cursor or Jet Brains IDE or something along those lines. So, you can actually see what
lines. So, you can actually see what Claude code is doing and not just have this terminal view. So, for example, a very popular editor is Visual Studio Code. A recent version of that which is
Code. A recent version of that which is kind of AI enabled is Cursor. So, for
example, you could open up Cursor. I'm
just going to open up an editor right here. And if you want a recommendation,
here. And if you want a recommendation, I would suggest just download Cursor because this is the best one to use for right now that also has its own AI features, but we can augment that by just using cloud code. So, you can see
that I have uh what is it kind of like a repository set up. Now when you open up one of these applications, so let's say you download cursor or you download VS Code or you get any code editor on your
computer, what you can do is you can go to a file, you can go to open folder, you can go to your desktop or any location that you're going to be able to find in the future and we can do
something like claude code test. And I'm
just going to make a new folder. Uh how
do I already have a folder cloud code test? Okay, well that was not what I
test? Okay, well that was not what I wanted. So let's go claude code test 2.
wanted. So let's go claude code test 2.
All right. So I'm going to make a new folder. The reason I'm making a new
folder. The reason I'm making a new folder is this is where I want my coding project to live. I'm going to select that and then I'm going to open it. So
again, I've just opened my code editor.
Doesn't matter which one you're using.
You can ignore all of the crazy features from cursor here and we can close some of these windows and kind of just hide them. And what we can do is we can open
them. And what we can do is we can open up the terminal directly inside of here.
So if you're working inside of cursor or VS code or windsurf. So something that is like a uh VS Code fork because a lot of these editors are based on Visual Studio Code. What you can do to open the
Studio Code. What you can do to open the terminal is you can try to find kind of like a drag bar at the bottom of the screen. But you can see I'm having
screen. But you can see I'm having trouble finding it here. Instead, you
can hit control and then back tick on your keyboard or command and then back tick on your keyboard and it should open up a terminal directly inside of this folder that you opened for you. Now, if
that's difficult for you, you can hit control shiftp or commandshiftp if you're on Mac and you can type terminal and then create new terminal and then just choose one of the instances. So,
command prompt or powershell if you're on Mac or Linux. Again, you just choose probably the first one that pops up. So,
let's say I do that and you can see it makes a new terminal for me and I'll be able to see it on my screen. Now, if you want to see the lefth hand sidebar, which is the file viewer, you can press this button right here. Again, this is
in cursor, but you can do this in another editor as well. And you'll be able to now see all of the files that Claude Code will generate for us in 1 minute. Now, again, if you can't find
minute. Now, again, if you can't find this button, you can hit controlB or commandB on your keyboard, and that will toggle the file view on the lefth hand side. Now, I know it seems complicated,
side. Now, I know it seems complicated, but most of the time you're going to want to work like this because you want to see the files and actually know what Cloud Code is doing, especially if you're unfamiliar with the terminal. I
would highly suggest opening this in some kind of user interface like we've done here so you actually know what's going on. Okay, so now we're inside of a
going on. Okay, so now we're inside of a terminal. This is the exact same
terminal. This is the exact same environment I was just showing you before, except it's now in this code editor, right? And again, this code
editor, right? And again, this code editor is called cursor in case anyone is confused. If you just go, you can
is confused. If you just go, you can type cursor download on the internet and you can download it super easily. just
open it up and literally all you have to do is just go file open folder open a new location and you can start writing code. So from this terminal we're going
code. So from this terminal we're going to type claude. Now when we type claude it's going to open up claude code just like it did before but now in this location. So same thing I'm going to
location. So same thing I'm going to trust the folder and now I have claude code in my terminal and I can start getting it to actually generate some stuff. So now we're going to actually
stuff. So now we're going to actually start using it. We're going to start building a project and I'm going to start walking through a lot of the features that it has. Now, you'll
actually notice that because I'm using it in this editor now, it's detected that. And it's telling me that I can
that. And it's telling me that I can actually have some special features here in Claude Code because I'm working in cursor. So, what I'm going to do is just
cursor. So, what I'm going to do is just go ahead and press enter. And now we can just start working. But again, it's going to be able to reference the files that we actually looking at in cursor.
Um, it's going to show us the changes that it's making. It's very powerful.
All right. So, without further ado, let's get this to do something. And
let's say that we just want to create a simple web-based game. Let's go with something really really simple for right now like maybe tic-tac-toe and just ask it to make that game. So I'm going to
say make tic tactoe that I can play on the web. Okay. Now I'm going to start
the web. Okay. Now I'm going to start going through all of the other configurations and settings, but for now let's just run this so we can see some kind of output and know that we're actually getting some result. Okay. So
you can see that it's going to start doing this and generating some output.
Now, something worth noting here is that if you wanted to, you actually could run Claude code multiple times in parallel.
So, while I was creating tic-tac-toe, for example, I could create another game. I could audit the codebase. I
game. I could audit the codebase. I
could, you know, change something, whatever. And that's one of the things
whatever. And that's one of the things that makes this quite powerful. I'm not
going to do that right now because again, we're still at the beginner level. Um, but you get the idea. Okay.
level. Um, but you get the idea. Okay.
So, you can see that it's generated some code for me here. It's kind of giving it right in the terminal. And it's asking me to allow it to create tic-tac-toe.
Now, what I'm going to do is just go here and I'm going to go yes, allow all edits during the session. And notice I'm using my arrow keys here to navigate.
So, I'm going to press enter so I can just go ahead and start writing this without asking me for permission. Okay.
So, you can see that it says it has created this for me. And it's telling me that the way that I can run this is to start the tic-tac-toe.html or doubleclick the file in the file
explorer. So, I'm just going to say
explorer. So, I'm just going to say start tick tactoe.html.
Uh, I'm not sure if that's actually the correct command, but let's just run that and see if that's going to do anything for me. It says open it in the default
for me. It says open it in the default browser. Yes. And don't ask again for
browser. Yes. And don't ask again for this. And let's see if it can open this
this. And let's see if it can open this up for me. And I can run it. Okay. And
you can see this is my browser. And we
have tic-tac-toe which has now been created, which looks pretty good. We can
generate a new game. You get the idea.
Now the one thing that I want to bring your attention to here is that as soon as we started running this a dotclaw folder was automatically created for us in the directory where we're working as
well as the code that was generated.
Right? So you can see tic-tac-toe now has been written. So this is pretty cool and this is the reason why you would do this inside of a code editor. So you're
able to actually see the changes in the code that's being generated in real time. Again, you don't need to do that,
time. Again, you don't need to do that, but that's what many people like to do when they're using a tool like this.
Okay, so we've got something created.
Now, we need to start going through a lot of the different configuration and setups. Now, keep in mind, if you don't
setups. Now, keep in mind, if you don't know how to do something, just ask Claude to help you. It can help you. It
can change configurations. It can set stuff up for you, but of course, it's useful to know the basics. So, inside of here, as you already saw, you can just type human language and you will get some output. However, you can also type
some output. However, you can also type /help. Let's start with that. And this
/help. Let's start with that. And this
is going to give you a general kind of shortcut or list of commands and things you can do in cla. So you can see that I can toggle between a few different things here. And you'll notice that if I
things here. And you'll notice that if I put an exclamation point, this is going to put me in bash mode. If I do a slash, this is going to allow me to type different commands. If I do an at, this
different commands. If I do an at, this is going to allow me to reference various files or paths. If I do an amperand, this is going to be for background tasks or keybinds or whatever that says, I think. So for background
new line, not exactly sure what that means actually. I've never used the
means actually. I've never used the amperand. Continuing, we go to commands.
amperand. Continuing, we go to commands.
And if I scroll down here, you can see there's a ton of different commands that I can run. We cannot possibly go over all of them in this video, but I will show you a bunch of them that are useful. So, if you're ever like, how do
useful. So, if you're ever like, how do I do something or I wonder what's possible? Type /comands and you can see
possible? Type /comands and you can see a bunch of stuff pops up and you're probably going to learn something just by looking through this menu. And then
custom commands, of course, you can make your own commands. We're not going to go over that right now. Okay. Okay, so
first thing that you want to be aware of is the different modes that you can use inside of clawed code. You can have a planning mode, you can have an asking mode, and you can have a coding mode.
Now, the ask mode is the default mode where it's going to ask you before it does something. So, you can see it asked
does something. So, you can see it asked before it generated a command. It asked
before it wrote code, right? The code
mode is just going to code by default.
It's not going to ask you for permission. And the planning mode is
permission. And the planning mode is going to create a detailed plan that Claude will follow so that it has a little bit more structure. In order to change the mode, you can hit shift and then tab on your keyboard. So shift and
tab. You can see it showing shift tab to
tab. You can see it showing shift tab to cycle. We have plan mode. We have the
cycle. We have plan mode. We have the normal mode, right, which is this. And
then we have the coding mode, which is kind of accept edits on. So here,
planning mode, right? Accept edits. It's
just going to do the thing. And then the ask mode is default mode where it's not showing you anything there. Again, to do that is shift and then tap. Now, if you want to see the shortcuts, you can type again the uh question mark and you can
see the different shortcuts that you can use and it will start showing you all of the different ones that you can put directly inside of here. Okay, so that is how you change the mode. So, the
first mode that I want to change into is the planning mode. And I want to show you a few other shortcuts. Let's say you write something super long here and you don't want to have to just like erase all of it. Well, what you can do is hit
escape twice on your keyboard. So,
escape, escape, and that's going to clear whatever is currently inside of this window. So, escape, escape. Now, if
this window. So, escape, escape. Now, if
you want to go back to the previous thing that you typed, you can use the up arrow key. So, you can actually toggle
arrow key. So, you can actually toggle through the previous commands you ran by using the up and the down arrow keys in your terminal. There's actually more
your terminal. There's actually more shortcuts that exist there. But, if you just want to cycle through the previous commands in case you're repeating something, you don't need to type it again. You can just cycle with the up
again. You can just cycle with the up and the down arrow key. Now, another
thing worth noting is that sometimes you want to actually create a line break in the prompt. So, for example, I have like
the prompt. So, for example, I have like hello and then I want to go down to the next line, right? I don't want to press enter because if I press enter, it's going to submit the command, but I want to move actually down and have like kind
of multiple lines. So, in order to do that, you hit the alt or the option key and then you just press enter. So, you
can see that what I did on my keyboard here is I just pressed alt. So, I'm
holding alt on Windows. If you're on Mac, it might be option. And then I press enter. And I can actually go down
press enter. And I can actually go down to the next line so that I can have things on multiple lines. And then
again, I can clear that by hitting escape twice. So again, that's alt or
escape twice. So again, that's alt or option. You hold that down and then
option. You hold that down and then press enter. Okay. So we're in the
press enter. Okay. So we're in the planning mode now. We've learned the commands. We have a general kind of lay
commands. We have a general kind of lay of the land when it comes to using this.
And we have to first decide what it is that we actually want to create. So the
most important part about AI coding is actually knowing what you want. If you
don't know what you want and you let the agent steer you, you're going to get horrible crazy results that take you forever to debug and change. But if
you're very clear and specific on what you want and you have it do one small task at a time, you can get fantastic results and create amazing stuff. So
this is just a tutorial. I don't have anything crazy that I want to build, but I definitely still want to come up with a plan for what it is that I want to do.
So I always start in the plan mode and what I'm going to do is actually stream my thoughts into Claude and ask it to come up with a plan to create this project. I don't need to know the
project. I don't need to know the codebase. I don't need to know the
codebase. I don't need to know the languages. I don't need to have done
languages. I don't need to have done research. is obviously helpful if you do
research. is obviously helpful if you do those things, but if you just want to start completely from scratch, we can do that. So, let's just stream our
that. So, let's just stream our thoughts. In order to do that, I am
thoughts. In order to do that, I am actually going to use a dictation tool on my computer called Whisper Flow. So,
rather than typing, I'm going to speak into my mic. I want to create a simple top-down shooter game that is runnable in the browser. I want to have some sprites or at least cool kind of like character animations. I want my
character animations. I want my character to have a gun. I want enemies to kind of be coming at him from different angles. I want to be able to
different angles. I want to be able to move with the arrow keys and then use my mouse to kind of point and click at the different enemies and shoot them. We
should have levels. We should progress clearly. We should have a menu screen.
clearly. We should have a menu screen.
We should keep it relatively simple and kind of like 2D retro style. Okay. So,
that is my thought process. So, I've
just streamed that into Claude. And then
same thing, I'm going to hold alt and go down. I'm just going to put kind of a
down. I'm just going to put kind of a little separator and I'm going to say create a plan for this game. And then we will start executing and coding it. So,
I'm just instructing it even though it's in the plan mode. You know, I want to plan this out before I proceed. And you
can use this to plan features, not just entire apps like I'm doing right here.
Okay. So, I'm going to go ahead and press on enter here. And it should start generating the plan for me. Let's give
that a second to make it. Okay. Now,
just while this is running, I want to point your attention to a few things here. So, first, you can actually see
here. So, first, you can actually see how long it's taking to run, as well as the number of tokens that are being used when it's doing this generation. So, if
you really care about the cost, obviously something to pay attention to.
Now, you also notice that this is able to use tools. There's some tools that are built into Claude, but there's other tools that you can actually install yourself if you want to make this more capable. So, for example, if I hit
capable. So, for example, if I hit control O, which it's showing me right here, it's going to expand this so that it's actually showing me, you know, exactly what's happening. Uh, and I can see what it is that's kind of going on
here, right? So, it says, okay, I'm
here, right? So, it says, okay, I'm thinking the user wants to create a game. All right, this is a fun project.
game. All right, this is a fun project.
Okay, here's what I want to do. Blah
blah blah blah blah, whatever. Right?
And then if I want to go back, I can do control O and it brings me back here to where I can kind of see, you know, what it's doing and the plan that it's generating. So if you want to open it in
generating. So if you want to open it in like verbose mode where you see the logs, it's control O. Now you also can have this triggered to run in the background. I'm not going to do that
background. I'm not going to do that right now, but if you hit controlB or commandB depending on your operating system, you can trigger this to run as a background session. And then that way
background session. And then that way you can actually just use cloud code for something else in the same terminal view while this is going on in the background. And again, you can have as
background. And again, you can have as many background tasks as you want running at the same time. Okay, so the plan was created. However, it's asking me a few questions here that I need to answer. So, I'm going to go with no
answer. So, I'm going to go with no sounds for now. So, let's answer that.
And then it's also asking me about the game size. And I'm just going to go full
game size. And I'm just going to go full screen. Actually, you know what? Let's
screen. Actually, you know what? Let's
go 800 by 600 just to make it easier.
And I'm going to submit my answers to Claude. So, another cool thing that it
Claude. So, another cool thing that it does is it clarifies with you before it actually starts going and generating all of the tasks. Now while this is running I will show you that you can change the
model that's being used here. So by
default I believe this is going to use the most powerful model or actually let me just answer this first and then we'll go into the model. So Claude has written a plan and it's ready to execute. Would
you like to proceed? Yes. Auto accept.
Yes. Manually approve edits. Type here
to tell Claude what to change. Okay. So
I'm going to go yes. Clear the context and auto accept edits. Now when you clear the context, what that's going to do is essentially remove all of the previous stuff that you've messaged Claude with. So, it's no longer being
Claude with. So, it's no longer being included in the API request to Claude and it's just going to go based off the plan. This is good to save tokens, but
plan. This is good to save tokens, but if you wanted to keep the context, then you could do that, right? By auto
accepting the edits, etc. So, I'm going to go yes, clear the context and auto accept this. And you can see that it is
accept this. And you can see that it is going to start actually generating this and going through the plan. So, this is the plan to implement. And there you go.
It's going to start building. Now, while
it does that, I did want to talk about the models. So it can be quite expensive
the models. So it can be quite expensive to run this and you can very quickly run through your usage. So if you want to make this more affordable for yourself, you can change the model that's being used here. So if you type /model here
used here. So if you type /model here and claude is not currently doing something, it will bring you into an interactive window that will allow you to change the model. So let's actually just do this from another claude code
here. So I'm going to go /model. And
here. So I'm going to go /model. And
when I do that, it's going to give us three options. Okay, so opus, sonnet,
three options. Okay, so opus, sonnet, and haiku or however you pronounce that.
Now you can see the three different models here. So Opus is going to be your
models here. So Opus is going to be your most powerful model and as it says it's for more complex work. This will be the most expensive but also just the best generally speaking. Sonnet is kind of a
generally speaking. Sonnet is kind of a middle ground model. So if you're doing some tasks that don't have extreme complexity, don't require a bunch of tool calling, you can select this one by just pressing enter. And if you want a
faster model that's going to give you quick answers and be significantly less expensive, then you can switch over to Haiku. Cool. Cool. So now we've gone
Haiku. Cool. Cool. So now we've gone back to our first kind of claude code instance here. And you can see that it
instance here. And you can see that it says it's implemented these features in the shooter.html file. So what I'm going to do now is
file. So what I'm going to do now is just say run the shooter file. Okay. And
I'm just going to have it run this and open it in the browser for me so I can actually see what it looks like. And
then of course if we have revisions, let's go yes. And don't ask for start commands. Uh oh, it says it cannot find
commands. Uh oh, it says it cannot find that for some reason. Okay. Uh let's see if it can run it again. Okay. And sorry
I've got this running now. For some
reason I made a mistake. And you can see we have this kind of retro shooter which I think looks pretty cool in my opinion.
And I can kind of move around. I can
shoot. We have like this wave of enemies that's coming.
Okay, cool. And that's I mean like literally exactly what I asked it to build, which is pretty good I would say for a first iteration. So we also have health, right? We have like the menu
health, right? We have like the menu bar, a bunch of that stuff. We could
obviously add add sound effects.
Cool. Okay, so let's close that. And if
we wanted to make revisions and same thing, we could just do something like, you know, add PowerUps to this app, and then it would go ahead and be able to do that.
Now, before we do that though, I want to talk about Git and GitHub. So, if you're going to be working on a large project, I highly recommend that you instruct Cloud Code to create a new GitHub
repository and to make commits and save all of the changes that it's making. So
the way to do that would be something like this. From now on, I would like you
like this. From now on, I would like you to make a new Git repository for this project. I would like you then to make
project. I would like you then to make clean commit messages, save them locally, and then push them to GitHub so that we always have a saved version of the project and it's easy for us to
revert back in case we make any changes.
So set up a GitHub repository, configure everything and just use Git and GitHub for the rest of the project. So we're
going to tell it that. Let's go ahead and press on enter. and it will just start running all of the commands that's needed to set that up. So, you don't really need to do anything here. It
should just know what to do. So, same
thing. We're just going to say yes and allow this to go and it will start setting it up. Okay, so it took a second here, but it did work. And actually, if I open up this URL now in my browser, we
should be able to see the Git repository that it created. Again, notice it automatically created it for us. And you
can see now we have us as well as Claude that are adding commits to this repository. So now it is saved and all
repository. So now it is saved and all of the work is going to be done automatically with what do you call it?
Uh git and github. Okay. Now let's go through a few other things that are worth noting. So I just told it right
worth noting. So I just told it right like always use git and github for this project and automatically make the commits. Now sometimes it will do that
commits. Now sometimes it will do that just automatically. But the thing with
just automatically. But the thing with claude is that as soon as I exit this, so I go like /exit, right? And if I just go claw it again and I start what's a new session, I've just lost all of the
context and the history of what was happening inside of here. So if I ask it like what did you do last or something like that, it can look at the git history, but it's not going to really
know what happened. You can see it says this is the start of our conversation, so I haven't done anything yet, right?
Because we started a new session. So
that's an important thing to understand about clawed sessions is that you don't have this kind of like unlimited memory like you might have in some other tools and that's where we are going to get
into talking about the clawed MD file.
Now the clawed MD file is something that will allow you to have persistent memory. So Claude kind of knows the
memory. So Claude kind of knows the rules of your codebase. It knows what it's done before, what it should and what it shouldn't do. And you can set it up to be really complex and advance so that you don't need to keep instructing
it to do the same thing. Because again,
if I start working right now, it's not going to automatically commit this to get in and GitHub like I want it to do.
So, in order to create a claude MD file, what you can do is type this /nit command. When you type /nit, what it's
command. When you type /nit, what it's going to do is automatically create claw.md for you. And in the claw.md, it
claw.md for you. And in the claw.md, it
will actually put in different information based on the analysis that it has of your codebase. Now, you of course can modify this claw.md file, and I'll show you how to do that in one second. But this is effectively again
second. But this is effectively again the persistent memory for claude when it's working in your codebase. And we'll
give it a second here to generate that MD file. So let's go. Yes, go ahead and
MD file. So let's go. Yes, go ahead and create that for us. Okay. Yes, go ahead and make that uh so that we'll have that file there and it will always reference it when we create a new session. Okay.
So you can see that it is showing me what the claude MD file will look like that it's going to create here where it goes over like project overview, running the game, development, setup, you know, whatever, all of this kind of stuff. So,
I'm going to go yes and allow edits during this session. And then it's going to create this claw.markdown file for me. Now, if we go through here, okay,
me. Now, if we go through here, okay, let's see if it has anything else.
Design pattern, color scheme, get workflow. Okay, cool. Awesome. And then
workflow. Okay, cool. Awesome. And then
it explains kind of all of this stuff.
So now, if there's some specific things that I always want Claude to do in the project, I can just tell it that. So,
I'm going to say update the claw.md file
to indicate that as you do work, you need to commit things to git and push them to GitHub regularly with clean commit messages. just so we never lose
commit messages. just so we never lose the status or work that we've done.
Okay, so let's go ahead and press on enter here. And you can see I said, you
enter here. And you can see I said, you know, claw.md. Whisper actually picked
know, claw.md. Whisper actually picked up that this was a file and it automatically tagged it for me. And now
you can see it's making changes, right?
And then updating that include MD. And
if we scroll down here, it explains what it needs to do. So now if we were to restart this. So let's go /exit to get
restart this. So let's go /exit to get out of that. Okay. And go claude. I'm
just going to say, "What do you know about this project?"
Okay. And it should be able to look in this claw.md file and give me some
this claw.md file and give me some information. Okay. And you can see it
information. Okay. And you can see it reads the claw.md file cuz it knows to go there and it gets us all of that persistent info. All right. So, now that
persistent info. All right. So, now that we've gone over that, I want to talk about tasks. Now, if you run the /tasks
about tasks. Now, if you run the /tasks command, this will show you any background tasks that are running. Now,
background tasks are typically going to be things like web servers that are running continuously and that you don't want to block the execution of your clawed code instance. So, right now, if I want to get out of this, I'm just
going to press uh escape to get out of that there. And you could see that I've
that there. And you could see that I've kind of got out of the dialogue. Now,
task might be something like a web server, a front-end, I don't know, like React website that's running, whatever.
There can be all kinds of background tasks and by default Claude will put some of them into the background but you can also put them in the background yourself. So what I want to show you is
yourself. So what I want to show you is if I do something like you know run a web server to host my two sites or host my two games what's going to happen here
is claude is going to detect that this is a task that would be blocking.
Blocking means that if we just ran it in this terminal that it's going to block us being able to do anything else. So
you can see that we now see one bash which means that there's a task that's happening and it says it's running this in the background. So if we want to see that we can hit CtrlT which will show the different tasks. We can go to the
bash and hit enter to view it. If we go back we also can type /tasks and then it's going to show the task that's running and how long it's been running for. Now from here if we want to kill
for. Now from here if we want to kill this task so I no longer want the web browser to be running for example I can press K and that's going to kill it for me. And then I can go back just by
me. And then I can go back just by hitting enter. Okay. And you can see
hitting enter. Okay. And you can see background command was killed. Right
now, for some reason, it's going to go and generate this again, I think. But if
I wanted to stop this, then what I could do is press escape. So, for example, if I do something like hello and then I press escape super fast, you'll see it's interrupts that command. So, if you want to stop the execution of something in
lifetime, press escape. I probably
should have mentioned that earlier, but I honestly just forgot. Um, but that's something to know. Okay, so those are tasks. Again, these are things that are
tasks. Again, these are things that are kind of like running in the background that are typically these long running operations. Now, however, if you do want
operations. Now, however, if you do want to create kind of parallel clawed bots that are like writing code or doing different operations for you where they're touching files or modifying
things, that's where we get into agents.
So, if you go to / agents, you can create agents and these agents can perform special tasks and you can delegate tasks to them. So, for example, you could have an agent that is handling
doing a styling, right? Or like changing the user interface, an agent responsible for the back end. Okay? I'm not going to get into all the details of how to set this up because it does get a little bit complex and kind of beyond the scope of
this tutorial, but I want to show you things like that do exist. Now, we also have things like MCP. If you want to connect to, for example, Notion or Gmail or Google Drive or you want to connect
to a bunch of other services, you can do that right from an MCP server inside of Claude, which really expands its capabilities. Again, let's get out of
capabilities. Again, let's get out of that. Let's go through slash. You can
that. Let's go through slash. You can
see there's a bunch of other stuff that you can do here. You can set up hooks, for example, that will automatically run code for you or different tasks. You can
set up keybinds, memory, you know, all of this kind of stuff. So, just go through it, have a look. And another
thing that's useful is skills. So you
can actually create skills that are essentially repeatable tasks that Claude does all of the time. So rather than creating an agent, you can create a skill and then you can run a particular skill by just saying, "Hey, you know,
run this skill that I've taught you how to do, it will go look up the skill and then be able to run it continually." So
you can see how powerful this can get if you really go through the full configuration. But at this point, if you
configuration. But at this point, if you followed along, you know how to use Claude Code better than 99% of people. I
showed you all of the core functionality and features and you can go out and start coding effectively whatever you want because now you know how to navigate this tool. I know this was long. I know it's a bit complex, but I
long. I know it's a bit complex, but I wanted you to get the proper setup so you didn't need to watch a bunch of other videos. If you guys have other
other videos. If you guys have other questions or you want more tutorials on cloud code, then definitely let me know and I will see you in another video.
Loading video analysis...