Setting up Sublime Text 3

On Windows, fetch and launch the installer from the web site.

On GNU/Linux, either install the additional repo channel and install the newly available package,

wget -qO - https://download.sublimetext.com/sublimehq-pub.gpg | apt-key add -
echo "deb https://download.sublimetext.com/ apt/stable/" >> /etc/apt/sources.list
apt update
apt install sublime-text

–or– grab the binary and install it manually

cd /opt/
tar xjf ...
cd /usr/local/bin
ln -s /opt/sublime_text_3/sublime_text

Plugins / Packages

show the console during configuration,

View > Show Console (^`)

install the Markdown package helper,

Ctrl+Shift+P
install Package Control

then install the following,

Ctrl+Shift+P
install Package

Markdown Extended
Material Theme
#gone? Simple Print Function
#gone? Pandoc
LPrint

MD to PDF with Pandoc

pip install printing

and eventually the enscript helper for printing text,

apt install enscript

note. not using those:

#good but redundant with Ext -- MarkdownHighlighting
#default styling is white: MarkdownEditing
#this breaks the shift+tab feature to unindent: SmartMarkdown
#SFTP

Settings

you can now choose the styling and tune your font of choice

Preferences -> Color Scheme -> Material Theme...
Preferences -> Theme -> Material Theme...
Preferences -> Settings

"default_font_size": 9,
"font_size": 9,
"tab_size": 8,
"translate_tabs_to_spaces": false

//"font_face": "DejaVu Sans Mono",
//"theme": "Default.sublime-theme",
//"color_scheme": "Packages/Color Scheme - Default/Mariana.sublime-color-scheme",

key bindings

{ "keys": ["ctrl+0"], "command": "reset_font_size" }

just for the reference even if I don’t use all those

"overlay_scroll_bars": "enabled",

"always_show_minimap_viewport": true,
"bold_folder_labels": true,
"color_scheme": "Packages/Material Theme/schemes/Material-Theme.tmTheme",
"font-face": "Fira Code",
"font_options":
[
    "gray_antialias",
    "subpixel_antialias"
],
"font_size": 10,
"ignored_packages":
[
    "Vintage"
],
"indent_guide_options":
[
    "draw_normal",
    "draw_active"
],
"line_padding_bottom": 3,
"line_padding_top": 3,
"material_theme_tree_headings": true,
"overlay_scroll_bars": "enabled",
"tab_size": 8,
"theme": "Default.sublime-theme"

(obsolete) Pandoc MD to PDF convertion

Obsolete: when PDF is needed, I just use discount HTML rendering with nice CSS then print to PDF from the browser.

On Windows desktops, you will also need Miktex.

On Linux desktops, you also need a Latex processor,

sudo apt install pandoc texlive texlive-xetex texlive-luatex fonts-lmodern lmodern

Then, to convert MD to PDF,

Ctrl-Shift-P
Pandoc
PDF

Or from the command line on Linux desktops,

doc=input.md
pandoc -V papersize:a4paper -o ${doc%\.md}.pdf $doc
unset doc

(obsolete) SFTP

Obsolete: if possible, simply use GIT instead.

Otherwise here’s how to proceed. The SFTP sublime package checks the time changes so,

To avoid typing a password, also,

create a folder e.g. on desktop or \~/dev/ and setup your connection params,

right click on folder > SFTP > edit remote mappings...

{
    // The tab key will cycle through the settings when first created
    // Visit http://wbond.net/sublime_packages/sftp/settings for help

    // sftp, ftp or ftps
    "type": "sftp",

    "save_before_upload": **true**,
    "upload_on_save": true,
    "sync_down_on_open": false,
    "sync_skip_deletes": false,
    "sync_same_age": true,
    "confirm_downloads": false,
    "confirm_sync": true,
    "confirm_overwrite_newer": **true**,

    "host": "host.example.com",
    "user": "SSHUSER",
    //"password": "password",
    "port": "SOMEPORT",

    "remote_path": "/home/SSHUSER/dev/path/",
    "ignore_regexes": [
        "\\.sublime-(project|workspace)", "sftp-config(-alt\\d?)?\\.json",
        "sftp-settings\\.json", "/venv/", "\\.svn/", "\\.hg/", "\\.git/",
        "\\.bzr", "_darcs", "CVS", "\\.DS_Store", "Thumbs\\.db", "desktop\\.ini"
    ],

    "connect_timeout": 30,
    "ssh_key_file": "~/.ssh/...",
    //"ssh_key_file": "C:/Users/USERNAME/Desktop/ssh/private_key.id_rsa",
    "preserve_modification_times": **true**,
}

note. remove ** around hilighted true accordingly

now sync Remote > Local

ref. https://wbond.net/sublime_packages/sftp/settings#Plugin_Settings

References

Installation https://sublime-text-unofficial-documentation.readthedocs.io/en/latest/getting_started/install.html

pandoc plugin

A Sublime Text plugin that uses Pandoc to convert text from one markup format into another https://github.com/tbfisher/sublimetext-Pandoc

Convert Markdown to PDF in Sublime Text https://levlaz.org/convert-markdown-to-pdf-in-sublime-text/

printing

Simple print function for Sublime Text. Handles printing current file, selection, or clipboard https://github.com/svenax/SublimePrint

How do you print in Sublime Text 2 https://stackoverflow.com/questions/16004842/how-do-you-print-in-sublime-text-2

appearance

https://packagecontrol.io/packages/Material%20Theme

zoom control

Reset Zoom to Default via “Ctrl+0” https://forum.sublimetext.com/t/reset-zoom-to-default-via-ctrl-0/18319/2


HOME | GUIDES | BENCHMARKS | html