From Scratch
I’ll try to not assume anything. I think that not assuming is HARD, one always obvius details, but I’m going to try.
Sublime Begins
Assuming that you have Sublime installed in the last version(yes assuming, that’s not a Joke) i will proceed with a few steps or configurations over Sublime with the objective to do your workflow more effective.
Control
The official website of Package Control says:
The Sublime Text package manager that makes it exceedingly simple to find, install and keep packages up-to-date.
In this part i think that is no needed to add much more. Install the Package control from Install Package Control, in Sublime Text, the Package Control is one of your best friends, trust me.
When Package Control is installed just press SHIFT+CMD+P and is ready to use, you can now used for install all the packages that you need.
The powerfull cmd+p
If you are under a Mac, use cmd if not, use ctrl instead. CMD+P is set by default in Sublime and it I’ll help to us find files in any project that we loaded in Sublime. The only thing you need to do is write the path or even better a hint of the file you want to search for and Sublime provides you files that match with your text, very usefull.
Shortcuts for everything
These are commands that i used regullarly:
- CMD + , : User preferences.
- CMD + SHIFT + P : Execute command palette.
- CMD + P : Find files by name.
- CMD + R : Find methods in the current file.
- CMD + D : Select the word.
- CMD + CTRL + G : Select all the equals words.
- CMD + K + B : Hide sidebar.
- CMD + SHIFT + / : Comment code.
- CMD + SHIFT + R : Find methods in all your projects files.
- CMD + CTRL + UP ARROW : Swicht Lines.
- CMD + SHIFT + V : Paste with identation.
- CMD + BACKSPACE : Delete the current line.
- CTRL + G : Go to line.
- CTRL + BACKSPACE or ALT + BACKSPACE : Delete by words.
- CTRL + SHIFT + K : Delete the current line and move the next line in the deleted line.
- To create a new file type CMD + SHIFT + P and then type NEW FILE.
Personal Recommendations
This tools adapts Sublime for any use, in other post I’ll write about plugins that works with PHP workflow.
- Side Bar Enhancements
- If you start with Sublime or even if you have a little of experience on it this tool will help you to do the basic stuff of files, folders and projects. Explore the differents alternatives of find, add folders to the project, running the file, moving, etc.
- Go To Documentation
- This tools saves me a lot of time, and trust me a lot is a lot. In my day I use many languages in my text editor and honestly not always remember all the definitions for every language. When i didn’t kwow this tools, I use the google search, but I lost the focus because I need to go to the browser and type what I’m looking for. Now I set a shortcut for this tools and the only thing that I need to do is focus on the word in Sublime type the shorcut and BOOM the browser is launch and go directly to the offical documentation of the language that I’m using, just great !
- Git Savvy
- Well, I use Git a lot so this is very helpfull to me having in Sublime the current branch, the diff of files and much more.
- Advanced New File
- This plugin will help you to manage your files creation in a project. You need, at least one a day.
- MarkDown Editing
- MarkDown Preview
- I use markdown to write, for example this post. With this plugins for example i can see a preview in the browser quickly or set the Syntax Markdown in Sublime, to name a few functions.
Install Packages
Don’t be affraid. Explore Package Control there are thousands of packages availables, always remember that someone else already had the problem you are having your now.
There are package for everything, in the next post i I’ll write about workflow in PHP settings snippets, Key bindings and more, stay tunned.