Thread Tools Display Modes
04/15/14, 12:36 PM   #1
Cpsgames
Join Date: Apr 2014
Posts: 5
ESOLua - Sublime Text 3 Language File

ESOLua for Sublime Text 3

Hello!

I love to use Sublime Text 3 for just about anything and when I noticed there wasn't a language file for ESO's lua, I decided to make one! It's simple and to the point, but it works for those who like the extra syntax highlighting on API functions, globals, etc..

Installation
Via Package Control:
The easiest method to install ESOLua is to use Package Control from within Sublime Text and search for "ESOLua". It'll quickly download, install, and keep it up to date for you!

Manual:
Download it and extract it into your packages folder. Or clone it from the BitBucket repo.

If you find anything wrong with the language file feel free to send me a message, start an issue on the repo, or send a pull request!

Thanks!

Last edited by Cpsgames : 04/15/14 at 10:12 PM. Reason: Rewording
  Reply With Quote
04/15/14, 09:25 PM   #2
Saucy
 
Saucy's Avatar
Join Date: Apr 2014
Posts: 20
Saw it on Reddit as well, many thanks Cpsgames!
  Reply With Quote
04/15/14, 10:13 PM   #3
Cpsgames
Join Date: Apr 2014
Posts: 5
Thanks! I hope you can find it useful.
  Reply With Quote
04/16/14, 07:36 AM   #4
BadVolt
AddOn Author - Click to view addons
Join Date: Apr 2014
Posts: 74
Originally Posted by Cpsgames View Post
ESOLua for Sublime Text 3

Hello!

I love to use Sublime Text 3 for just about anything and when I noticed there wasn't a language file for ESO's lua, I decided to make one! It's simple and to the point, but it works for those who like the extra syntax highlighting on API functions, globals, etc..

Installation
Via Package Control:
The easiest method to install ESOLua is to use Package Control from within Sublime Text and search for "ESOLua". It'll quickly download, install, and keep it up to date for you!

Manual:
Download it and extract it into your packages folder. Or clone it from the BitBucket repo.

If you find anything wrong with the language file feel free to send me a message, start an issue on the repo, or send a pull request!

Thanks!
Thanks! Very useful!
  Reply With Quote
04/16/14, 09:44 AM   #5
Ruimuuv
AddOn Author - Click to view addons
Join Date: Mar 2014
Posts: 5
Wonderful, thank you!
  Reply With Quote
04/25/14, 08:35 PM   #6
LilBudyWizer
AddOn Author - Click to view addons
Join Date: Apr 2014
Posts: 32
It isn't working for me for some reason with Sublime Text 3, but is with Sublime Text 2. I installed package control, added the repository, added the package, but I'm not getting the highlighting. Basically the same thing I did in Sublime Text 2 except the install of Package control is pasting a different string into the console. Since you refer to Sublime Text 3 I have to assume that's what you're using and it's working just fine for you. Perhaps it's having both 2 and 3 installed at the same time?
  Reply With Quote
04/25/14, 09:17 PM   #7
Saucy
 
Saucy's Avatar
Join Date: Apr 2014
Posts: 20
If you open a .lua file, look at the bottom right of Sublime Text. It probably say "Lua", no? Click on it and change to ESOLua.

Another way is to open your .lua file if not already, then go: View -> Syntax -> Open all current extension as... (and choose ESOLua).

Last edited by Saucy : 04/25/14 at 09:34 PM.
  Reply With Quote
04/25/14, 09:31 PM   #8
Saucy
 
Saucy's Avatar
Join Date: Apr 2014
Posts: 20
On another note, if you're using SublimeLinter with the SublimeLinter-lua plugin.

You can add ESOLua to the syntax_map (so it runs the lua-linter in ESOLua language file as well).

If you have both installed (easiest done by Package Control), go to the settings:
  1. Preferences -> Package Settings -> SublimeLinter -> Settings-User
  2. Inside the "syntax_map object, add to the list:
    Code:
    "esolua": "lua"
  3. Restarting Sublime Text might be needed
  Reply With Quote
04/26/14, 03:46 AM   #9
LilBudyWizer
AddOn Author - Click to view addons
Join Date: Apr 2014
Posts: 32
Yep, that was it. Sublime is a lot to take in, but easy to use. That makes it a whole lot easier to read the code.
  Reply With Quote
04/26/14, 10:20 AM   #10
LilBudyWizer
AddOn Author - Click to view addons
Join Date: Apr 2014
Posts: 32
Personally, I thank you as much for pointing me towards Sublime Text 3 as for the language file. There's a lot to learn to fully use it, but it seems a great boon knowing nothing about it. It's intuitive to start. I particularly like that open directory feature. I was using SciTE which works well enough, but this is a whole lot better. One thing that would be better is seeing the parameter list on functions. Since I don't get it on the string and table libraries I assume that's just not something Sublime Text 3 does, or at least not for LUA.
  Reply With Quote
04/26/14, 01:08 PM   #11
Saucy
 
Saucy's Avatar
Join Date: Apr 2014
Posts: 20
I've been looking for something similar, but haven't found any plugins that let you view the parameters of functions.
If I can't remember the functions params I run CTRL+R (Goto -> Goto Symbol), and it lets me search through all functions I've written.

About the string and table libraries; the closest I've found is Lua Love plugin. I haven't played with it much, but it seems to have most functions in there. Don't forget to change language file to "Lua (Love)", but I some functions work with ESOLua.

If all else fails, you can always define your own snippets.

*Edit: btw, I made snippets for LibAddonMenu for Sublime, located here: https://github.com/Saucyboy/sublime-ESO-LibAddonMenu

Last edited by Saucy : 06/15/14 at 03:24 PM. Reason: corrected url for snippets
  Reply With Quote
04/28/14, 01:17 PM   #12
LilBudyWizer
AddOn Author - Click to view addons
Join Date: Apr 2014
Posts: 32
I put out a simple addon, EPA, for checking for inadvertent creation of globals. Someone pointed out you can use luac to do that. Being new to sublime I don't know if you can get sublimelinter-lua to highlight global creation, but it seems it would certainly be possible in a package. Since you already created a package perhaps you would be interested in doing this. Perhaps even a sublimelinter-ESOlua that warns about calls to private/protected functions as well.
  Reply With Quote
04/28/14, 02:58 PM   #13
Seerah
Fishing Trainer
 
Seerah's Avatar
WoWInterface Super Mod
AddOn Author - Click to view addons
Join Date: Feb 2014
Posts: 648
http://www.wowinterface.com/download...OTANADDON.html

  Reply With Quote
04/30/14, 10:46 AM   #14
Cpsgames
Join Date: Apr 2014
Posts: 5
Whoops, I was a bit late! I'm glad that you got the issues sorted, LilBudyWizer!
  Reply With Quote
05/11/14, 03:47 PM   #15
stjobe
 
stjobe's Avatar
AddOn Author - Click to view addons
Join Date: Apr 2014
Posts: 60
Sublime Text 3 + EsoLua + SublimeLinter just replaced Notepad++ for my ESO addon writing.

Thank you all for letting me know about ESOLua and SublimeLinter (ST3 was slowly replacing NP++ anyway, but this made the transition much easier and faster).
  Reply With Quote
05/22/14, 09:24 PM   #16
syndicated
 
syndicated's Avatar
Join Date: May 2014
Posts: 4
This is fantastic, thanks!
  Reply With Quote
05/25/14, 07:41 PM   #17
Cpsgames
Join Date: Apr 2014
Posts: 5
Thanks! Glad it could be of use!
  Reply With Quote
07/29/15, 09:44 AM   #18
haggen
 
haggen's Avatar
AddOn Author - Click to view addons
Join Date: Jul 2015
Posts: 137
Originally Posted by Cpsgames View Post
ESOLua for Sublime Text 3

Hello!

I love to use Sublime Text 3 for just about anything and when I noticed there wasn't a language file for ESO's lua, I decided to make one! It's simple and to the point, but it works for those who like the extra syntax highlighting on API functions, globals, etc..

Installation
Via Package Control:
The easiest method to install ESOLua is to use Package Control from within Sublime Text and search for "ESOLua". It'll quickly download, install, and keep it up to date for you!

Manual:
Download it and extract it into your packages folder. Or clone it from the BitBucket repo.

If you find anything wrong with the language file feel free to send me a message, start an issue on the repo, or send a pull request!

Thanks!
I hope you don't mind, but I ported your excellent work to Atom.

Source: https://github.com/haggen/language-eso-lua
Atom package: https://atom.io/packages/language-eso-lua

And of course I gave you your deserved credits, is that okay ?

Last edited by haggen : 07/29/15 at 11:01 AM.
  Reply With Quote
08/08/15, 03:59 PM   #19
Cpsgames
Join Date: Apr 2014
Posts: 5
Glad you were able to do something with it! Just a heads up, the version of the API I based this on is pretty out of date by now. I'm not sure how much the API has changed since then. I should probably update this...

I do not need any credit, I really don't mind! If you absolutely must give credit I'd prefer it if you just linked to the repo itself. I haven't used that Twitter account in ages. :P
  Reply With Quote

ESOUI » Developer Discussions » Dev Tools » ESOLua - Sublime Text 3 Language File

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off