در حال بارگذاری ...

Opening Project and Navigation0:00

So let's begin. We'll give that a moment to download, and then I'll move it to my applications directory. Great. So let's open that. And here's what we get out of the box. Let's open an example project. And here I have a fresh install of Laravel, just to give us some files to work with. So now if you come from an editor like Sublime Text, many of the commands are going to be the same. Not all, but many of them. For example, I can type command-p to instantly browse to any file. So if I go to user or registers users, that will work the way you expect. And of course, we can use fuzzy searching. So if I type ru, you can see that it still pulls up the same file. However, let's go back to user. I think the default theme isn't horrible, but it's not my favorite. There's a lot going on here. This bold blue status bar at the bottom, the theme, it's not ideal for me. All right. So you'll notice we have these five tabs here to search and replace.

Installing a Custom Theme1:31

that folder. So I can say foo.php, and you can see how that works. But I'll hit command-backspace to delete that. Next, we will have our source control for git. We'll come back to that later. We have our debug panel, and then we have our extensions. Now if you're coming from something like Sublime Text, you're of course used to package control, but I think you'll like this a bit more. So here we can see the most popular extensions sorted by the install count. But you can even do things like this, where you say, well just show me the extensions that I have installed personally. So while we're here, why don't we pull in a custom theme. We're going to look for one that I like is called Slime. It's actually a port from a Dale Reese theme who's active in the Laravel community. So let's grab this one right here, and let's give it a reload. Great. So now if I visit user, we're still going to see the original theme, and that's because we haven't yet activated it.

community. So let's grab this one right here, and let's give it a reload. Great. So now if I visit User, we're still going to see the original theme, and that's because we haven't yet activated it. We can go to code, preferences, color theme, and search for Slime. Or I'll hit escape. You can hit shift-command-p. And once again, this is just like the command palette from Sublime. So I'm just going to look for color theme, and you can see we can access it that way instead. And that way you don't have to remember which toolbar it's in. You don't have to remember a keystroke. You just type it out. So once again, I will choose Slime, and at least to my eyes, I think this looks pretty good. Now on the subject of Sublime, if you come from that editor and you're really comfortable with all of the shortcuts, I would recommend pulling in the Sublime Text Keymap, which you'll find right here. And yeah, it's just a port of all of the keystrokes you're used to so that you don't have to relearn

Hiding Status and Tabs3:39

So in this case, the status bar is set to true. Why don't we change that to false? And you'll see that pops up on the right. So now, if we close this out with command-W, yeah, now we've gotten rid of that status bar. And at least for my eyes, I like things as minimal as I can get. So even this Open Editors section kind of irks me a little bit. And as you can imagine, it's all open tabs. So if we go to RegistersUser and we'll open this within the side, well now we can see all the panels. But you know what? I see it very clearly here. I don't need this. So instead, I want to hide that. So once again, if I don't know the setting off the top of my head, I'll hit command-comma, and I'm just going to look for Open Editors. Now in code, often when you want to toggle the visibility of something, usually the property will be called visible. So yeah, there we go. Now this is a little confusing, but it refers to the number of editors shown, or I guess the number of files or tabs. We're going to

Toggling Activity Bar4:24

usually the property will be called visible. So yeah, there we go. Now this is a little confusing, but it refers to the number of editors shown, or I guess the number of files or tabs. We're going to change that to zero, like so. So now we get rid of that entirely, and now I'm just a little bit closer to that clean layout that I want. Next, now you may think this is useful, but generally you're going to memorize the keystrokes to go there, like shift-command-F that we referred to earlier. So again, it's my personal preference to hide that entirely. And this is referred to as the activity bar. You click it once to open, like this. You click it twice to close it. So maybe useful, but again, I would just prefer to hide it. So we could do this through settings. Let's look for activity bar, and then just take the same approach. Or many of these can be toggled automatically. So we'll open up shift-command-P to grab our command palette, look for activity bar,

Disabling Minimap and Sidebar5:47

the defaults. Next, you'll see that code copies the minimap that you get from Sublime. So if we go to a large file like Laravel's application class, yeah, you might find that this is useful. However, even though it's very cool looking, I realized I never use it. So once again, that is something that I would personally turn off, but you don't have to. Do what feels good. So once again, I just did that from the command palette, and we can show it here. So now I think this is looking pretty good, but what if I do want to toggle the sidebar? Well, one option is to search for sidebar, and we can see the default keymap is Command-B, Command-B, like so. On, off, on, off. Or I believe from Sublime, it's Command-KB. In PHPStorm, it's Command-1. So what you can do is don't make yourself relearn something so basic. So map it to whatever you are used to. We can go to Code, Preferences, Keyboard Shortcuts. And now, once again, this is very useful. So if we were to say

Customizing Keyboard Shortcuts6:35

yourself relearn something so basic. So map it to whatever you are used to. We can go to Code, Preferences, Keyboard Shortcuts. And now, once again, this is very useful. So if we were to say toggle sidebar, there we go. You can right-click and change it to whatever you want. So if it's Command-1 in PHPStorm, we can move that over, and now I type Command-1 to toggle that. It's very, very simple. All right, so I'm feeling pretty good. In the next episode, let's move on to something else.

دوست دارید گاهی خبرهای Laracasts را ایمیل کنیم؟