Skip to content

Instantly share code, notes, and snippets.

@arthuralvim
Created June 1, 2012 15:13
Show Gist options
  • Save arthuralvim/2852859 to your computer and use it in GitHub Desktop.
Save arthuralvim/2852859 to your computer and use it in GitHub Desktop.

Revisions

  1. Arthur Alvim revised this gist Jun 1, 2012. 2 changed files with 4 additions and 0 deletions.
    2 changes: 2 additions & 0 deletions Default (OSX).sublime-keymap
    Original file line number Diff line number Diff line change
    @@ -4,6 +4,8 @@
    // and overwrite it. Set the shortcuts the way you want.

    [

    { "keys": ["ctrl+shift+b"], "command": "run_build", "args":{"build_system":"Packages/User/Bibtex.sublime-build"}},
    { "keys": ["ctrl+shift+l"], "command": "run_build", "args":{"build_system":"Packages/User/CleanTexFiles.sublime-build"}}

    ]
    2 changes: 2 additions & 0 deletions RunBuild.py
    Original file line number Diff line number Diff line change
    @@ -1,3 +1,5 @@
    # It's saved under path_to_Packages/User/

    import sublime
    import sublime_plugin

  2. Arthur Alvim revised this gist Jun 1, 2012. 4 changed files with 12 additions and 4 deletions.
    4 changes: 3 additions & 1 deletion Bibtex.sublime-build
    Original file line number Diff line number Diff line change
    @@ -1,6 +1,8 @@
    // It's saved under path_to_Packages/User/

    {
    "cmd": ["bibtex", "$file_base_name"],
    "path": "$PATH:/usr/texbin:/usr/local/bin",
    "file_regex": "^(...*?):([0-9]+): ([0-9]*)([^\\.]+)",
    "selector": "text.tex.latex"
    }
    }
    4 changes: 3 additions & 1 deletion CleanTexFiles.sublime-build
    Original file line number Diff line number Diff line change
    @@ -1,6 +1,8 @@
    // It's saved under path_to_Packages/User/

    {
    "cmd": ["latexmk","-CA","$file"],
    "path": "$PATH:/usr/texbin:/usr/local/bin",
    "file_regex": "^(...*?):([0-9]+): ([0-9]*)([^\\.]+)",
    "selector": "text.tex.latex"
    }
    }
    3 changes: 3 additions & 0 deletions Default (OSX).sublime-keymap
    Original file line number Diff line number Diff line change
    @@ -1,5 +1,8 @@
    // KeyBindings - User

    // You should add the lines above without brackets to your keybindings (user) file or only download the file
    // and overwrite it. Set the shortcuts the way you want.

    [
    { "keys": ["ctrl+shift+b"], "command": "run_build", "args":{"build_system":"Packages/User/Bibtex.sublime-build"}},
    { "keys": ["ctrl+shift+l"], "command": "run_build", "args":{"build_system":"Packages/User/CleanTexFiles.sublime-build"}}
    5 changes: 3 additions & 2 deletions RunBuild.py
    Original file line number Diff line number Diff line change
    @@ -1,8 +1,9 @@
    import sublime, sublime_plugin
    import sublime
    import sublime_plugin

    class RunBuildCommand(sublime_plugin.WindowCommand):
    def run(self, build_system):
    self.window.run_command( "set_build_system", {"file": build_system } )
    self.window.run_command( "build" )

    # all credits for theses guys http://www.bit-101.com/blog/?p=3439. =)
    # all credits for these guys http://www.bit-101.com/blog/?p=3439. =)
  3. Arthur Alvim revised this gist Jun 1, 2012. 2 changed files with 4 additions and 3 deletions.
    2 changes: 1 addition & 1 deletion Default (OSX).sublime-keymap
    Original file line number Diff line number Diff line change
    @@ -1,4 +1,4 @@
    // KeyBindings - User
    // KeyBindings - User

    [
    { "keys": ["ctrl+shift+b"], "command": "run_build", "args":{"build_system":"Packages/User/Bibtex.sublime-build"}},
    5 changes: 3 additions & 2 deletions RunBuild.py
    Original file line number Diff line number Diff line change
    @@ -1,7 +1,8 @@

    import sublime, sublime_plugin

    class RunBuildCommand(sublime_plugin.WindowCommand):
    def run(self, build_system):
    self.window.run_command( "set_build_system", {"file": build_system } )
    self.window.run_command( "build" )
    self.window.run_command( "build" )

    # all credits for theses guys http://www.bit-101.com/blog/?p=3439. =)
  4. Arthur Alvim created this gist Jun 1, 2012.
    6 changes: 6 additions & 0 deletions Bibtex.sublime-build
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,6 @@
    {
    "cmd": ["bibtex", "$file_base_name"],
    "path": "$PATH:/usr/texbin:/usr/local/bin",
    "file_regex": "^(...*?):([0-9]+): ([0-9]*)([^\\.]+)",
    "selector": "text.tex.latex"
    }
    6 changes: 6 additions & 0 deletions CleanTexFiles.sublime-build
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,6 @@
    {
    "cmd": ["latexmk","-CA","$file"],
    "path": "$PATH:/usr/texbin:/usr/local/bin",
    "file_regex": "^(...*?):([0-9]+): ([0-9]*)([^\\.]+)",
    "selector": "text.tex.latex"
    }
    6 changes: 6 additions & 0 deletions Default (OSX).sublime-keymap
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,6 @@
    // KeyBindings - User

    [
    { "keys": ["ctrl+shift+b"], "command": "run_build", "args":{"build_system":"Packages/User/Bibtex.sublime-build"}},
    { "keys": ["ctrl+shift+l"], "command": "run_build", "args":{"build_system":"Packages/User/CleanTexFiles.sublime-build"}}
    ]
    7 changes: 7 additions & 0 deletions RunBuild.py
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,7 @@

    import sublime, sublime_plugin

    class RunBuildCommand(sublime_plugin.WindowCommand):
    def run(self, build_system):
    self.window.run_command( "set_build_system", {"file": build_system } )
    self.window.run_command( "build" )