Home Download Buy Blog Forum Support

Can't figure out how to create a plugin

Can't figure out how to create a plugin

Postby maxedison on Sun Feb 05, 2012 4:59 pm

I took the example code for the "Duplicate" plugin from the Sublime Text examples page: http://www.sublimetext.com/docs/plugin-examples

I saved that code into a file named duplicate.py, stored inside ... > Packages > User

I then added a keybinding for it to the User .sublime-keymap file: { "keys": ["super+alt+d"], "command": "duplicate" }

But nothing happens.

After that didn't work, I tried installing this plugin: https://bitbucket.org/sir_gollum/sublim ... _region.py
To install it, I simply put it in ... > Packages > User.

Again, nothing happens. What am I doing wrong?
maxedison
 
Posts: 5
Joined: Mon Sep 19, 2011 7:51 pm

Re: Can't figure out how to create a plugin

Postby weslly on Sun Feb 05, 2012 5:12 pm

Those examples are for Sublime Text 1.x, the API reference for ST2 is here: http://www.sublimetext.com/docs/2/api_reference.html
weslly
 
Posts: 202
Joined: Sun Aug 28, 2011 3:57 am
Location: Brazil


Return to Plugin Development

Who is online

Users browsing this forum: No registered users and 9 guests