feat(SublimeText2.UtilPackages): cache packages

This commit is contained in:
Iristyle
2013-04-04 08:54:47 -04:00
parent 1e6f643a1b
commit d65666cdfc
541 changed files with 26347 additions and 0 deletions

View File

@@ -0,0 +1,2 @@
*.pyc
.DS_Store

View File

@@ -0,0 +1,22 @@
[
{
"keys": ["ctrl+shift+end"],
"command": "move_tab",
"args": { "position": "999" }
},
{
"keys": ["ctrl+shift+home"],
"command": "move_tab",
"args": { "position": "0" }
},
{
"keys": ["ctrl+shift+pageup"],
"command": "move_tab",
"args": { "position": "-1" }
},
{
"keys": ["ctrl+shift+pagedown"],
"command": "move_tab",
"args": { "position": "+1" }
}
]

View File

@@ -0,0 +1,22 @@
[
{
"keys": ["super+alt+shift+down"],
"command": "move_tab",
"args": { "position": "999" }
},
{
"keys": ["super+alt+shift+up"],
"command": "move_tab",
"args": { "position": "0" }
},
{
"keys": ["super+alt+shift+left"],
"command": "move_tab",
"args": { "position": "-1" }
},
{
"keys": ["super+alt+shift+right"],
"command": "move_tab",
"args": { "position": "+1" }
}
]

View File

@@ -0,0 +1,22 @@
[
{
"keys": ["ctrl+shift+end"],
"command": "move_tab",
"args": { "position": "999" }
},
{
"keys": ["ctrl+shift+home"],
"command": "move_tab",
"args": { "position": "0" }
},
{
"keys": ["ctrl+shift+pageup"],
"command": "move_tab",
"args": { "position": "-1" }
},
{
"keys": ["ctrl+shift+pagedown"],
"command": "move_tab",
"args": { "position": "+1" }
}
]

View File

@@ -0,0 +1,22 @@
[
{
"caption": "Move Tab: To the left",
"command": "move_tab",
"args": { "position": "-1" }
},
{
"caption": "Move Tab: To the right",
"command": "move_tab",
"args": { "position": "+1" }
},
{
"caption": "Move Tab: To first position",
"command": "move_tab",
"args": { "position": "0" }
},
{
"caption": "Move Tab: To last position",
"command": "move_tab",
"args": { "position": "999" }
}
]

View File

@@ -0,0 +1,18 @@
Copyright (c) 2012 Frédéric Massart - FMCorz.net
Permission is hereby granted, free of charge, to any person obtaining a copy of
this software and associated documentation files (the "Software"), to deal in
the Software without restriction, including without limitation the rights to
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
the Software, and to permit persons to whom the Software is furnished to do so,
subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

View File

@@ -0,0 +1,33 @@
Move Tab
========
Plugin for Sublime Text 2 to move tabs around.
Usage
-----
The following commands are accessible via the command palette:
- Move Tab: To the left
- Move Tab: To the right
- Move Tab: To first position
- Move Tab: To last position
The shortcuts are:
- Linux/Windows: CTRL + Shift + (Page up / Page down / Home / End)
- MacOS X: Command + Alt + Shift + (Left / Right / Up / Down)
Installation
------------
Clone this repository into the Packages directory. If you don't know where it is, enter the following command in the console:
print sublime.packages_path()
_To access the console press CTRL + `_
License
-------
Licensed under the [MIT License](http://www.opensource.org/licenses/mit-license.php)

View File

@@ -0,0 +1,62 @@
# -*- coding: utf-8 -*-
"""
Move Tab
Plugin for Sublime Text 2 to move tabs around
Copyright (c) 2012 Frédéric Massart - FMCorz.net
Licensed under The MIT License
Redistributions of files must retain the above copyright notice.
http://github.com/FMCorz/MoveTab
"""
import sublime, sublime_plugin
class MoveTabCommand(sublime_plugin.WindowCommand):
def run(self, position):
position = str(position)
view = self.window.active_view()
(group, index) = self.window.get_view_index(view)
if index < 0:
return
count = len(self.window.views_in_group(group))
direction = None
if position.startswith('-') or position.startswith('+'):
direction = position[0]
steps = int(position[1:])
if direction == '-':
position = index - steps
else:
position = index + steps
position = int(position)
if position < 0:
position = count - 1
elif position > count - 1:
if direction: position = 0
else: position = count - 1
# Avoid flashing tab when moving to same index
if position == index:
return
self.window.set_view_index(view, group, position)
self.window.focus_view(view)
def is_enabled(self):
view = self.window.active_view()
if view == None:
return False
(group, index) = self.window.get_view_index(view)
return len(self.window.views_in_group(group)) > 1
def is_visible(self):
return True
def description(self):
return None

View File

@@ -0,0 +1 @@
{"url": "https://github.com/SublimeText/MoveTab", "version": "2012.08.24.06.11.17", "description": "Plugin for Sublime Text 2 to move tabs around"}