Sublime Text 2 - Jump to a specific word - sublimetext2

I am using Sublime Text and use the Cmd+F search tool very often. However everytime I use it, it highlight the word I am looking work and I then have to click on it to start typing there.
What is the shortcut to directly jump to the word I am looking for?
Many thanks

I'm assuming that as you said CMD + F rather than CTRL + F you are using the OSX version of Sublime Text.
The Windows / Linux shortcut for Goto word in current file is CTRL + ;
But if you look at the corresponding list for OSX shortcuts that one is missing.
(I am currently on a Windows machine so I can't test the lack of an OSX shortcut)

Related

Is there a spotlight-like search in sublime text?

Is there a way to bring up a search box in Sublime Text that you can start typing in possible commands to see what you have installed, and what it might be mapped to? Kind of like what OSX has?
Command Palette (hat tip to Tommi)
Ctrl-Shift-P (Windows)
Cmd-Alt-P (OSX)

Split selection into lines in PHPStorm

In Sublime I was quite fond of the "Split selection into lines" shortcut (super+shift+l). However I cannot find an equivalent of that in PHP Storm 8, I've found a "Split into lines" function in the Edit menu but feeding it either \n or \r doesn't seem to work. Does that function exist in PS ?
By default on PHPStorm 10+, you can toggle the Column Selection Mode with:
CMD + SHIFT + 8
Of course, you can configure any stroke you like. I like to keep the original one and add the one that matches Sublime which is CMD + SHIFT + L. Here is how:
Another option would be to use column selection mode:
https://stackoverflow.com/a/30031481/672989
There is a "Split Selection into Lines" action in the Extra Actions plugin.
Compatible with: Compatible with: IntelliJ IDEA PhpStorm WebStorm PyCharm RubyMine AppCode CLion GoLand DataGrip Rider MPS Android Studio
If I have a 200 line selection I don't want to have to create a cursor at the end of every line.
You do not have to "create a cursor at the end of every line" -- just create cursor on the beginning of each line (on Windows it would be Alt+Mouse drag Down/Up) and then just press End button. This is not that straightforward as separate dedicated action .. but still does the same job and pretty easy to execute.
In any case: there is no such exact action currently available in PhpStorm, unfortunately.
Please follow this ticket (star/vote/comment) to get notified on progress: http://youtrack.jetbrains.com/issue/IDEA-122181

Set syntax for a specific file name in Sublime Text 2/3

I have a program that uses a file called user.cfg to get its user defined configuration settings. The odd thing is that they chose the syntax for this file to be Tcl (it's not odd that it is Tcl, it's odd they chose the .cfg extension instead of .tcl). So, when I open this file in Sublime Text, it doesn't know what syntax highlighting scheme to choose.
What I would like to do is set the syntax highlighting for user.cfg to Tcl, but not all .cfg files to Tcl.
I have seen this question which is very similar to mine, except in that case the special file name had no extension so Sublime Text knew to assign Ruby highlighting to only that one file. Unfortunately, I have an extension so the solution given there will not work for me.
Is there any known way to get Sublime Text base a highlighting scheme on the full filename?
Take a look at the ApplySyntax plugin.
The previous answer is completely true; however, I thought it would be better to have it here all in one place rather than going on another webpage to find the list of procedure to apply it
Sublime text 3
This is found here
Ensure Package Control is installed. Instructions are found here.
In Sublime Text, press Ctrl+Shift+P (Win, Linux) or Cmd+Shift+P (macOS) to bring up the quick panel and start typing Package Control: Install Package.
Select the command and it will show a list of installable plugins.
Start typing ApplySyntax; when you see it, select it.
Restart to be sure everything is loaded proper.
Enjoy!

in MySQL Command Line, how do I paste from the clipboard using only the keyboard?

Hi I'm learning MySQL using MySQL Workbench Command Line Client v 5.6 in Windows 7.
I type my commands into a text editor, then from the text edtor I copy them onto the clipboard. To paste them into the Command Line Client (CLC) I must right click with the mouse and go to "paste" in the context menu.
I would like to forgo the mouse entirely. But in the CLC, none of the Windows keyboard shortcuts seem to work. CTRL+V for example produces "^v" while SHIFT+INSERT does nothing.
Is there a keyboard shortcut for "paste"?
Although this question is clearly not a programming question this a way you can do this.
First you start by selecting the window with the command line. This can be done by alt + tab. Then when the command line windows is active you can paste the content of your clipboard with: alt + space Then go trough the menu with e and then p. The letters will dependent on the language from your windows OS.
If you are using Win 10, you can turn on CTRL + C and CTRL + V shortcuts to work in the command prompt:
If anyone else was trying to paste the password directly into the MySQL "Enter password" prompt, use ctrl+shift+v instead of ctrl+v

pressing ctrl+w in mysql workbench results in ETB

So I'm using the MySQL Workbench SQL Editor 5.2.45 CE
However whenever I try to close a tab using the keyboard shortcut Ctrl+W, instead of closing the tab it prints out "ETB" in the query editor instead and does not close the tab...
Any idea what's causing this and how to resolve it?
You are probably working on Windows. The ETB output is from the editor when the hotkey is not handled in the UI and hits the editors input processor without being defined for an action (like select word or copy to clipboard). The editor control is a Scintilla instance which is able to also display non-printable characters.
The hotkey Ctrl+W was previously used to close tabs, but since Ctrl+F4 is much more common on Windows it was changed. So use Ctrl+F4 in the future instead.