Home Download Buy Blog Forum Support

Key Binding Help

Key Binding Help

Postby kakarlus on Thu Aug 02, 2012 3:03 am

hi guys,

need help on this. i want to bind my F8 key to build also but targetting a specific build system, i dont know what arguments to pass.

{ "keys": ["f7"], "command": "build" },
{ "keys": ["f8"], "command": "build", "args": },


thanks,
carlos
kakarlus
 
Posts: 8
Joined: Thu May 10, 2012 3:39 am

Re: Key Binding Help

Postby kakarlus on Thu Aug 02, 2012 3:23 am

or is this not possible?
kakarlus
 
Posts: 8
Joined: Thu May 10, 2012 3:39 am

Re: Key Binding Help

Postby kakarlus on Thu Aug 02, 2012 3:43 am

{ "keys": ["ctrl+f7"], "command": "set_setting", "args": {"setting": "build_system", "value": "Packages/User/KioskCompile.sublime-build"} },
{ "keys": ["ctrl+f8"], "command": "set_setting", "args": {"setting": "build_system", "value": "Packages/User/KioskADL.sublime-build"} },


tried this one but doesnt work sob. :s
kakarlus
 
Posts: 8
Joined: Thu May 10, 2012 3:39 am

Re: Key Binding Help

Postby quodlibet on Thu Aug 02, 2012 11:17 pm

With the build system that was introduced a few versions ago, you can create variants which can be accessed via the command palette. For more information: http://docs.sublimetext.info/en/latest/ ... stems.html

Now, I haven't tested this, but it looks like you should be able to bind keys to execute specific variants. For example, this is from the default keybindings:
Code: Select all
{ "keys": ["ctrl+shift+b"], "command": "build", "args": {"variant": "Run"} },


Hope this helps,
Alex
quodlibet
 
Posts: 499
Joined: Sat Jun 18, 2011 5:53 pm


Return to Technical Support

Who is online

Users browsing this forum: No registered users and 15 guests