Skip to content

Commit

Permalink
Merge branch 'release/v0.2.0'
Browse files Browse the repository at this point in the history
  • Loading branch information
hesstobi committed Nov 14, 2014
2 parents 7eefcef + bed2366 commit e1cb995
Show file tree
Hide file tree
Showing 4 changed files with 70 additions and 5 deletions.
39 changes: 36 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,37 @@
Sublime Gnuplot
===============
# Sublime Gnuplot

This package aims to provide a support for creating nice figures with gnuplot in Sublime-Text. So far, various features have been implemented, including:
* Syntax hilighting
* Script execution -- pressing `cmd+b` on Mac OS X, `ctrl+b` on Linux/Windows
* Toggle Comments -- pressing `cmd+/` on Mac OS X, `ctrl+/` on Linux/Windows [Leandro Heck](/~https://github.com/leoheck)

# Installation

Sublime Gnuplot can be installed via [Package Controll](https://sublime.wbond.net/installation) or from source. I recommend that you use Package Control! Not only does it ease installation, but more importantly it automatically updates the plugins it installs, which ensures you will get the latest features and bug fixes.

## Installing via Package Control

To install SublimeLinter via [Package Controll](https://sublime.wbond.net/installation), follow these steps:

1. Open the Command Palette (`cmd+shift+p` on Mac OS X, `ctrl+shift+p` on Linux/Windows).
2. Type `install` and select `Package Control: Install Package` from the Command Palette. There will be a pause of a few seconds while Package Control finds the available packages.
3. When the list of available packages appears, type `gnuplot` and select `Gnuplot`.
4. After a few seconds Sublime Gnuplot will be installed and loaded.

## Installing from source

I very strongly discourage you from installing from source. There is no advantage to installing from source vs. using Package Control. In fact, there are several disadvantages, including no automatic updates, no update messages, etc.

If you insist on installing from source, please do not do so unless you are comfortable with the command line and know what you are doing. To install Sublime Gnuplot from source, do the following:

1. Quit Sublime Text.
2. If you have a previous source installation at `Packages/Gnuplot`, delete it.
3. Type in a terminal:
```
cd '/path/to/Sublime Text 3/Packages'
git clone /~https://github.com/hesstobi/sublime_gnuplot.git Gnuplot
```
4. Restart Sublime Text 3.



Simple package to provide syntax higlighting and a build command for gnuplot
7 changes: 7 additions & 0 deletions gnuplot-comments.YAML-tmPreferences
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@

name: Gnuplot Comments
scope: source.gnuplot
settings:
shellVariables:
- {name: TM_COMMENT_START, value: '# '}
uuid: 38DBCCE5-2005-410C-B7D7-013097751AC8
24 changes: 24 additions & 0 deletions gnuplot-comments.tmPreferences
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>name</key>
<string>Gnuplot Comments</string>
<key>scope</key>
<string>source.gnuplot</string>
<key>settings</key>
<dict>
<key>shellVariables</key>
<array>
<dict>
<key>name</key>
<string>TM_COMMENT_START</string>
<key>value</key>
<string># </string>
</dict>
</array>
</dict>
<key>uuid</key>
<string>38DBCCE5-2005-410C-B7D7-013097751AC8</string>
</dict>
</plist>
5 changes: 3 additions & 2 deletions gnuplot.tmLanguage
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
<string>gnuplot</string>
<string>gnu</string>
<string>plot</string>
<string>plt</string>
</array>
<key>keyEquivalent</key>
<string>^~G</string>
Expand Down Expand Up @@ -44,9 +45,9 @@
</dict>
</dict>
<key>comment</key>
<string>gnuplot iteration statement.
<string>gnuplot iteration statement.
There are two forms:
numeric [n = 1:2{:inc}]
numeric [n = 1:2{:inc}]
string based [str in "x y z"]
but both can also iterate over lists etc, so this is kept loose.</string>
<key>end</key>
Expand Down

0 comments on commit e1cb995

Please sign in to comment.