Package​resource​viewer

Adding Additional Accounts

If have multiple GitHub accounts, or have a private GitHub installation, you can add the other
accounts and switch between them whenever you like.

Go to the GitHub user settings file (Preferences -> Package Settings -> GitHub -> Settings — User),
and add another entry to the dictionary. If it is another GitHub account, copy the
for the default GitHub entry (if you don’t see it, you can get it from Preferences ->
Package Settings -> GitHub -> Settings — Default, or in the example below), and just give the
account a different name. If you’re adding a private GitHub installation, the will be
whatever the base url is for your private GitHub, plus “/api/v3”. For example:

"accounts":
{
    "GitHub":
    {
        "base_uri": "https://api.github.com",
        "github_token": "..."
    },
    "YourCo":
    {
        "base_uri": "https://github.yourco.com/api/v3",
        "github_token": ""
    }
}

Don’t worry about setting the –that will be set for you automatically, after you
switch accounts (Shift-Cmd-P, “GitHub: Switch Accounts”).

License

“None are so hopelessly enslaved as those who falsely believe they are free.” Johann Wolfgang von Goethe

Copyright 2014 Tito Bouzout tito.bouzout@gmail.com

This license apply to all the files inside this program unless noted different for some files or portions of code inside these files.

This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation. http://www.gnu.org/licenses/gpl.html

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with this program. If not, see http://www.gnu.org/licenses/gpl.html

Installing

With the Package Control plugin: The easiest way to install CodeFormatter is through Package Control, which can be found at this site: http://wbond.net/sublime_packages/package_control

Once you install Package Control, restart Sublime Text and bring up the Command Palette ( on OS X, on Linux/Windows). Select “Package Control: Install Package”, wait while Package Control fetches the latest package list, then select CodeFormatter when the list appears. The advantage of using this method is that Package Control will automatically keep CodeFormatter up to date with the latest version.

Without Git: Download the latest source from GitHub and copy the CodeFormatter folder to your Sublime Text “Packages” directory.

With Git: Clone the repository in your Sublime Text “Packages” directory:

git clone https://github.com/akalongman/sublimetext-codeformatter.git CodeFormatter

The “Packages” directory is located at:

  • OS X:

    ST2: ~/Library/Application Support/Sublime Text 2/Packages/
    ST3: ~/Library/Application Support/Sublime Text 3/Packages/
    
  • Linux:

    ST2: ~/.config/sublime-text-2/Packages/
    ST3: ~/.config/sublime-text-3/Packages/
    
  • Windows:

    ST2: %APPDATA%/Sublime Text 2/Packages/
    ST3: %APPDATA%/Sublime Text 3/Packages/
    

Getting Started

Open the interactive tutorial in Sublime Text! Look for Requester: Show Tutorial in the command palette.

Or, open a file and insert the following.

requests.get('https://jsonplaceholder.typicode.com/albums')
requests.post('https://jsonplaceholder.typicode.com/albums')

get('https://jsonplaceholder.typicode.com/posts')  # 'requests.' prefix is optional
post('jsonplaceholder.typicode.com/posts')  # as is the URL scheme

Place your cursor on one of the lines and hit ctrl+alt+r (ctrl+r on macOS). Or, look for Requester: Run Requests in the command palette shift+cmd+p and hit Enter. A response tab will appear, with a name like GET: /albums.

Head to the response tab and check out the response. Hit ctrl+alt+r or ctrl+r (ctrl+r or cmd+r on macOS) to replay the request. You can edit the request, which is at the top of the file, before replaying it.

Now, go back to the requester file and highlight all 5 lines, and once again execute the requests. Nice, huh?

Multiline Requests, Request Body, Query Params

post(
    'httpbin.org/post',
    json={'name' 'Jimbo', 'age' 35, 'married' False, 'hobbies' 'wiki', 'pedia']}
)

get(
    'httpbin.org/get',
    params={'key1' 'value1', 'key2' 'value2'}
)

Body, Query Params, and Headers are passed to requests as dictionaries. And for executing requests defined over multiple lines, you have two options:

  • fully highlight one or more requests and execute them
  • place your cursor inside of a request and execute it

Try it out.

Basic Functionality

Package Control is driven by the Command Palette. To open the palette,
press ctrl+shift+p (Win, Linux) or
cmd+shift+p
(Mac). All Package Control commands begin with Package
Control:
, so start by typing Package.

The command palette will now show a number of commands. Most users
will be interested in the following:

Install Package
Show a list of all available packages that are available for install.
This will include all of the packages from the default channel, plus
any from repositories you have added.
Add Repository
Add a repository that is not included in the default channel.
This allows users to install and automatically update
packages from GitHub and BitBucket. To add a package
hosted on GitHub, enter the URL in the form
https://github.com/username/repo. Don’t include
.git at the end! BitBucket repositories should use the
format https://bitbucket.org/username/repository.
Remove Package
This removes the package folder, and the package name from the
installed_packages list in
Packages/User/Package Control.sublime-settings. The
installed_packages list allow Package Control to automatically
install packages for you if you copy your Packages/User/
folder to another machine.

Dropped features

conditionals

The standard syntax highlights recognizes part after conditional as a comment. This is a really nice feature, however it is rather fragile and has many issues, e.g. with unterminated blocks (opening/closing brace inside a preprocessor conditional).
So for sake of simplicity it was decided to remove it at all, leaving only a plain handling, which is more or less stable and has pretty straightforward implementation.

You may however checkout a preprocessor-cond-scopes branch which doesn’t have this limitation.

Local variable declaration/initialization

C can be quite complicated to parse in some parts, for example related to pointer declarations (what is ? Is it a simple multiplication, or a declaration of a pointer to type called ?). Needless to say, it is just impossible to parse C using regular expressions. Therefore, C Improved doesn’t try to recognize variable declarations, so there is no distinct scope/highlighting for them.

Some discussion on this can be found in a related issue.

Readme

Source
raw.​githubusercontent.​com

BracketHighlighter

Bracket Highlighter matches a variety of brackets such as: , , , , , , and even custom
brackets.

This was originally forked from pyparadigm’s SublimeBrackets and SublimeTagmatcher (both are no longer available). I
forked this to fix some issues I had and to add some features I had wanted. I also wanted to improve the efficiency of
the matching.

Moving forward, I have thrown away all of the code and have completely rewritten the entire code base to allow for a
more flexibility, faster, and more feature rich experience.

Feature List

  • Customizable to highlight almost any bracket.
  • Customizable bracket highlight style.
  • High visibility bracket highlight mode.
  • Selectively disable or enable specific matching of tags, brackets, or quotes.
  • Selectively use an allowlist or blocklist for matching specific tags, brackets, or quotes based on language.
  • When bound to a shortcut, allow option to show line count and char count between match in the status bar.
  • Highlight basic brackets within strings.
  • Works with multi-select.
  • Configurable custom gutter icons.
  • Toggle bracket escape mode for string brackets (regex|string).
  • Bracket plugins that can jump between bracket ends, select content, remove brackets and/or content, wrap selections
    with brackets, swap brackets, swap quotes (handling quote escaping between the main quotes), fold/unfold content
    between brackets, toggle through tag attribute selection, select both the opening and closing tag name to change both
    simultaneously, etc.

License

Released under the MIT license.

Copyright 2013 — 2021 Isaac Muse isaacmuse@gmail.com

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.

Case Conversion

Позволяет переключаться между snake_case, camelCase, PascalCase и т. д. После установки плагина с помощью Package Control (введите «pic» для быстрого доступа к Install Package), попробуйте:

До: navMenu

Нажмите: ;;c, затем ;;c

После: nav_menu

Обратите внимание, что это не будет работать должным образом, если вы попытаетесь преобразовать целую строку. До:

До: <nav id=»menu_system» class=»nav_menu isOpen»>

Нажмите: ;;c, затем ;;c (для camelCase)

После: navIDMenuSystemClassNavMenuIsOpen

Если вы являетесь веб-разработчиком, использующим  Package Control Sublime Text 3, советую попробовать перечисленные в этой статье плагины! Если они вам не понравятся, всегда можно удалить их с помощью Package Control: Remove Package.

Активация Sublime Text 3

Чтобы активировать Сублайн текст 3 откройте текстовый документ License Key, скопируйте из него один из ключей, далее запустите Сублайн и перейдите во вкладку «Справка» («Help«) — «Ввести лицензию» («Enter license«) вставляем ключ и жмем «Use License»

Установка Emmet на sublime text 3 и добавление в него Package Control.

Запускаем редактор и нажимаем Ctrl+ или «Вид» — «Показать/скрыть консоль» («View» — «Show console«), после чего снизу откроется панелька для ввода, вставьте в нее нижеприведенный код, нажмите «Enter«, немного подождите и перезапустите редактор.

import urllib.request,os,hashlib; h = 'df21e130d211cfc94d9b0905775a7c0f' + '1e3d39e33b79698005270310898eea76'; pf = 'Package Control.sublime-package'; ipp = sublime.installed_packages_path(); urllib.request.install_opener( urllib.request.build_opener( urllib.request.ProxyHandler()) ); by = urllib.request.urlopen( 'http://packagecontrol.io/' + pf.replace(' ', '%20')).read(); dh = hashlib.sha256(by).hexdigest(); print('Error validating download (got %s instead of %s), please try manual install' % (dh, h)) if dh != h else open(os.path.join( ipp, pf), 'wb' ).write(by)

Теперь заходим во вкладку «Опции» — «Package Control» или нажимаем сочетание клавиш «Ctrl» + «Shift» + «P«, после чего всплывет окошко в котором выбираем «Install Package» (если не ошибаюсь 6 строка).

После чего всплывет еще окошко, в котором необходимо ввести «Emmet«, появится масса предложений, нажимаем на первое (где просто Emmet).

Ждем немного, пока не откроется вкладка с содержимым, что Эммет успешно установлен, закрываем все вкладки и перезапускаем редактор. Все можно пользоваться!

В трех словах, о том, как работает Эммет

Приведу несколько примеров для Emmet. Допустим нам нужно базовый каркас веб-страницы на html5, для этого достаточно ввести «!» и нажать «Tab».

Чтобы быстро построить к примеру блок с классом col-sm-6, необходимо ввести «.col-sm-6» и нажать «Tab», получим «<div class=»col-sm-6″></div>»

Для того чтобы построить вот такую конструкцию:

<div class="row">
	<div class="col-md-3">Lorem ipsum dolor sit amet, consectetur adipisicing elit. Nesciunt natus quidem qui, obcaecati dolorem optio nulla voluptates suscipit eligendi laboriosam quisquam odio provident facilis laudantium. Non, tempora mollitia consequuntur laborum!</div>
	<div class="col-md-3">Incidunt fugiat beatae non voluptatum at iste inventore obcaecati rem tenetur officiis reprehenderit soluta, magnam est consequatur accusantium, fuga aperiam nesciunt exercitationem dignissimos aut, ut. Voluptatibus id explicabo, suscipit porro.</div>
	<div class="col-md-3">Iste magni, nam id a, maxime incidunt aperiam hic, aliquid suscipit aspernatur maiores quaerat sequi asperiores perferendis eum delectus consectetur sint excepturi laboriosam, error. Ratione voluptatum similique sunt sequi maiores!</div>
	<div class="col-md-3">Officiis doloremque cumque ab quae similique totam voluptates? Molestias rerum eos dolor nulla quidem nam pariatur, quisquam reiciendis tenetur. Dolorum, at, illum! Corporis, itaque, impedit repellendus natus accusantium sit sunt.</div>
</div>

достаточно ввести вот такую небольшую строчку «.row>.col-md-3*4>lorem» и нажать «Tab«.

Как вы видите Emmet очень крутое дополнение, которое очень ускоряет процесс верстки, главное уметь правильно им пользоваться) Советую почитать документацию.

На сегодня все!

Что такое копирайтинг?
Сборка на основе Bootstrap 3 >

Description

Provides enhancements to the operations on Sidebar of Files and Folders for Sublime Text. http://www.sublimetext.com/

Notably provides delete as “move to trash”, open with.. and a clipboard.

Close, move, open and restore buffers affected by a rename/move command. (even on folders)

New file/folder, edit, open/run, reveal, find in selected/parent/project, cut, copy, paste, paste in parent, rename, move, delete, refresh….

Copy paths as URIs, URLs, content as UTF8, content as data:uri base64 ( nice for embedding into CSS! ), copy as tags img/a/script/style, duplicate

Preference to control if a buffer should be closed when affected by a deletion operation.

Allows to display “file modified date” and “file size” on statusbar (may be a bit buggy).

Installation

Note with either method, you may need to restart Sublime Text for the plugin to load properly.

Package Control

Installation through package control is recommended. It will handle updating your packages as they become available. To install, do the following.

  • In the Command Palette, enter
  • Search for

Manual

Clone or copy this repository into the packages directory. Ensure it is placed in a folder named . By default, the Packages directories for Sublime Text 2 are located at:

  • OS X: ~/Library/Application Support/Sublime Text 2/Packages/
  • Windows: %APPDATA%/Roaming/Sublime Text 2/Packages/
  • Linux: ~/.config/sublime-text-2/Packages/

By default, the Packages directories for Sublime Text 3 are located at:

  • OS X: ~/Library/Application Support/Sublime Text 3/Packages/
  • Windows: %APPDATA%/Roaming/Sublime Text 3/Packages/
  • Linux: ~/.config/sublime-text-3/Packages/

Generating Your Own Access Token

If you feel uncomfortable giving your GitHub username and password to the plugin, you can generate a GitHub API access token yourself. Just open up a Terminal window/shell (on OS X, Linux or Cygwin), and run:

curl -u username -d '{"scopes":, "note": "sublime-github"}' https://api.github.com/authorizations

where is your GitHub username. You’ll be prompt for your password first. Then you’ll get back a response that includes a 40-digit “token” value (e.g. ). Go to Sublime Text 2 -> Preferences -> Package Settings -> GitHub -> Settings — User, and insert the token there. It should look like:

{
    "github_token": "6423ba8429a152ff4a7279d1e8f4674029d3ef87"
}

Restart Sublime.

That’s it!

3.0 Beta

by wbond
at 5:00pm
on Thursday, December 11th, 2014

After a couple of months of bug fixes and feature development, I‘m excited
to announce the first Package Control 3.0 beta! Over the next few days
I would like to get it in the hands of a bunch of users to work out any
final kinks. Hopefully 3.0 will be a little less eventful than the 2.0
rollout.

A set of full release notes will be displayed via Package Control messages,
however here are some highlights:

  • depedency support
  • an SSL module for Linux
  • error-free theme, color scheme and syntax upgrades
  • improved HTTP support on Windows
  • functionality to sync package removals via the User/ folder

If you are willing to help, perform the following instructions to
upgrade to version 3.0.0-beta. Once upgraded, keep an eye
on the Sublime Text console for Python exceptions. If you experience any
issues, please
open an issue.

  1. Open Preferences> Package Settings
    > Package Control > Settings – User
    and set the install_prereleases setting to true
  2. Run the Add Repository command and enter
    https://sublime.wbond.net/prerelease/packages.json.
  3. Run the Upgrade Package command and choose
    Package Control

Notes on configuring the Open With menu:

Definitions file: (note the extra subfolder levels). To open it, right-click on any file in an open project and select

  • On OSX, the ‘application’ property simply takes the name of an application, to which the file at hand’s full path will be passed as if with , e.g.: “application”: “Google Chrome”
  • On OSX, invoking shell commands is NOT supported.
  • You should change Caption and id of the menu item to be unique.

    //application 1
    {
    “caption”: “Photoshop”,
    “id”: “side-bar-files-open-with-photoshop”,
    “command”: “side_bar_files_open_with”,
    “args”: {
    “paths”: ,
    “application”: “Adobe Photoshop CS5.app”, // OSX
    “extensions”:“psd|png|jpg|jpeg”, //any file with these extensions
    “args”:
    }
    },

Vars on “args” param

  • \$PATH — The full path to the current file, “C:\Files\Chapter1.txt”
  • \$PROJECT — The root directory of the current project.
  • \$DIRNAME — The directory of the current file, “C:\Files”
  • \$NAME — The name portion of the current file, “Chapter1.txt”
  • \$NAME_NO_EXTENSION — The name portion of the current file without the extension, “Chapter1”
  • \$EXTENSION — The extension portion of the current file, “txt”

Plugin Installation

With the Package Control plugin: The easiest way to install
is through Package Control, which can be found at
this site: http://wbond.net/sublime_packages/package_control

Once you install Package Control, restart Sublime Text and bring up the
Command Palette ( on OS X, on
Linux/Windows). Select “Package Control: Install Package”, wait while
Package Control fetches the latest package list, then select
SublimeCodeIntel when the list appears. The advantage of using this
method is that Package Control will automatically keep SublimeCodeIntel
up to date with the latest version.

**Without Git:** Download the latest source from
GitHub and copy
the whole directory into the Packages directory.

**With Git:** Clone the repository in your Sublime Text Packages
directory, located somewhere in user’s “Home” directory:

git clone git://github.com/SublimeCodeIntel/SublimeCodeIntel.git

The “Packages” packages directory is located differently on different
platforms. To access the directory use:

  • OS X:

    Sublime Text -> Preferences -> Browse Packages...
    
  • Linux:

    Preferences -> Browse Packages...
    
  • Windows:

    Preferences -> Browse Packages...
    

Other Commands

Add Channel
Adds another channel that lists repositories. This is uncommon,
but allows users to create a custom channel of repositories to share.
Create Package File
For package developers. Takes a package folder and generates a
.sublime-package file that can be uploaded onto the web and
referenced in the packages.json file for a repository.
Create Binary Package File
For package developers. Creates a .sublime-package file that does not include
the source .py files, but instead the .pyc bytecode
files. This is useful to distribute commercial packages. Be sure
to check the resulting .sublime-package file to ensure that
at least one .py file is included so that Sublime Text will
load the package.
Disable Package
Disables a package, which causes any Python scripts to be unloaded,
and other files such as .sublime-keymap files to be
unloaded also.
Discover Packages
Opens up a web browser to Browse.
Enable Package
Re-enables a package that has been disabled.
Upgrade/Overwrite All Packages
This will upgrade ALL packages, including ones
that were not installed via Package Control. If you are developing
a custom copy of a package, you may not want to use this command.
Upgrade Package
Show a list of packages that are available for upgrade and let the
user pick which they would like to update.
Install Local Dependency
Show a quick panel of folders in the Packages/ that are not
currently installed as dependencies, but have a
.sublime-dependency file. Once a dependency is selected, a
loader will be installed, allowing the dependency to be used for
development, without having to submit it to the default channel
first.
Package Control Settings – Default
Open the default settings file, which can be used as a reference
for changing the User settings. Any changes to this file will
be lost whenever Package Control is automatically or manually
upgraded.
Package Control Settings – User
Opens the user’s settings for Package Control. Any settings changes
should be saved here so they are not overwritten when a new version
of Package Control is released.

Settings

PackageSync provides the following user configurable settings:

  • prompt_for_location
    Decides if the user is asked for providing location to back up to or restore from.
    If set as true, user is prompted every time for a path upon back up or restore operation.
    If set as false, the location specified in settings is used. If no location has been specified in settings, by default user’s desktop is used for backup.

  • zip_backup_path
    The zip file path to use for backing up or restoring package list & user settings.

  • folder_backup_path
    The folder path to use for backing up or restoring package list & user settings.

  • list_backup_path
    The file path to use for backing up or restoring only the package list.

  • ignore_files
    The list of files to ignore when backing up.
    It supports wildcarded file names as well. Supported wildcard entries are ‘*’, ‘?’, » & ». For further details, please see the fnmatch documentation.

  • sync_package_sync_settings
    Toggle to determine whether to synchronize user setting for this package ().

  • include_files
    The list of files to include when backing up.
    Note: ignore_files holds higher priority as compared to include_files. So a file matching both the settings would essentially be ignored, as governed by ignore_files.
    It supports wildcarded file names as well. Supported wildcard entries are ‘*’, ‘?’, » & ». For further details, please see the fnmatch documentation.

  • ignore_dirs
    Directories to ignore when backing up.
    By default, all directories created by other packages are included. Only the directories specified in this list are ignored while syncing.

  • preserve_packages
    Decides if the existing packages are to be preserved while restoring from a backup.
    If set as false, existing packages & their settings are removed during restore operation. Only the packages included in the backup are restored.
    If set as true, PackageSync keeps the existing packages intact. Packages not included in the backup therefore remain unharmed even after restore operation. However, user-settings are overwritten if the backup contains user-settings for the same package.

  • online_sync_enabled
    Toggle to determine if online syncing is enabled or not.
    Turning this toggle ON/OFF requires Online Sync Folder to be setup first.

  • online_sync_folder
    Folder to use for syncing the backup with online syncing services.
    This should be the path to a folder inside the Google Drive, Dropbox or SkyDrive sync folder. Any other online syncing application can be used as well.

  • online_sync_interval
    The frequency (in seconds) at which PackageSync should poll to see if there are any changes in the local folder or in the online sync folder.
    PackageSync will keep your settings up to date across machines by checking regularly at this interval. If you face any performance issues you can increase this time via the settings and a restart of Sublime Text.

  • debug
    Whether or not PackageSync should log to the console. Enable this if you’re having issues and want to see PackageSync’s activity.

Using the External Libraries

(check each license in project pages)

  • “getImageInfo” to get width and height for images from “bfg-pages”. See: http://code.google.com/p/bfg-pages/
  • “desktop” to be able to open files with system handlers. See: http://pypi.python.org/pypi/desktop
  • “send2trash” to be able to send to the trash instead of deleting for ever!. See: http://pypi.python.org/pypi/Send2Trash
  • “hurry.filesize” to be able to format file sizes. See: http://pypi.python.org/pypi/hurry.filesize/
  • “Edit.py” ST2/3 Edit Abstraction. See: http://www.sublimetext.com/forum/viewtopic.php?f=6&t=12551

License

The MIT License (MIT)

Copyright 2013 Victor Alberto Gil

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.

New Package Control Website

by wbond
at 2:32pm
on Friday, August 9th, 2013

The old Community Packages list that was hosted on my website was admittedly
a quick and dirty hack to make it easier for users to try and find packages.
I have always known there were many usability issues and tons of room for
improvement.

When the first alpha of Sublime Text 3 was announced, I knew there was
quite a bit of work ahead of me to adapt the architecture to support
multiple versions of Sublime Text. I also saw this as the opportunity to
converge the codebase from python (for Package Control) and PHP (for the
old Community Packages list) to a single re-usable library.

Along the way of pursuing that goal, I vastly expanded the information that
can be provided by the channel system. This information helps greatly
enhance the new Package Control site to include in-depth information about
every package.

I am sure many of you have already poked around a bit, but here are some
highlights of the new site:

Usage

  • Run Black on the current file:

    Press Ctrl-Alt-B to format the entire file.
    You can also Ctrl-Shift-P (Mac: Cmd-Shift-P) and select Sublack: Format file.

  • Run Black with —diff:

    Press Ctrl-Alt-Shift-B will show diff in a new tab.
    You can also Ctrl-Shift-P (Mac: Cmd-Shift-P) and select Sublack: Diff file.

  • Toggle Black on save for current view :

    Press Ctrl-Shift-P (Mac: Cmd-Shift-P) and select Sublack: Toggle black on save for current view.

  • run Black Format All :

    Press Ctrl-Shift-P (Mac: Cmd-Shift-P) and select Sublack: Format All. Run black against each root folder in a standard way (without taking care of sublack options and configuration). Same thing as running black . being in the folder.

  • Start Blackd Server :

    Press Ctrl-Shift-P (Mac: Cmd-Shift-P) and select Sublack: Start BlackdServer.

  • Stop Blackd Server :

    Press Ctrl-Shift-P (Mac: Cmd-Shift-P) and select Sublack: Stop BlackdServer.

Configuring

For adding additional library paths (Django and extra libs paths for
Python or extra paths to look for .js files for JavaScript for example),
either add those paths as folders to your Sublime Text project or
modify SublimeCodeIntel User settings. User settings can be configured
in the User File Settings:

Do NOT edit the default SublimeCodeIntel settings. Your changes will be
lost when SublimeCodeIntel is updated. ALWAYS edit the user
SublimeCodeIntel settings by selecting “Preferences->Package
Settings->SublimeCodeIntel->Settings — User”. Note that individual
settings you include in your user settings will completely replace
the corresponding default setting, so you must provide that setting in
its entirety.

Available settings:

  • A list of disabled languages can be set using
    “disabled_languages”. Ex.

  • Live autocomplete can be disabled by setting “live” to
    false.
  • Information for more settings is available in the
    file in the package.
Добавить комментарий

Ваш адрес email не будет опубликован. Обязательные поля помечены *

Adblock
detector