[Tool/Web/Other] Eclipse plugin for Pawn
#1

This is Pawn Editor plugin for Eclipse IDE.
Eclipse is an integrated development environment (IDE) for Java apps, but also for many other programming languages.
This plugin extends Eclipse for Pawn editing.

Features
  • Syntax highlighting
  • Auto-complete
  • File outline
  • Code templates
Syntax highlighting
Colors can be changed from menu: Window -> Preferences -> Pawn Editor

Auto-complete
Activate with Ctrl + Space (key binding can be changed in Eclipse preferences)
Includes variables, functions, constants, #defines declared in current file and in #included files.
Auto-completions are cached, so the plugin does not have to parse all the include files every time you open Eclipse. This means that if some include files change, you need to delete the completions.txt file in workspace folder: .metadata/.plugins/ee.jb.pawn/

File outline
Shows overview of current file.
Click on outline item to select it in editor.
If Outline view is not visible, you can fix it using the menu: Window -> Show View -> Outline

Code templates
Activate with Ctrl + Space (key binding can be changed in Eclipse preferences)
Includes common Pawn statements like if, else, for, while etc
Templates can be changed from menu: Window -> Preferences -> Pawn Editor -> Templates

Install

Download Eclipse IDE from https://www.eclipse.org/downloads/eclipse-packages/ (I tested with Eclipse Oxygen.1a (4.7.1a) IDE for Java Developers)
Download Pawn Editor plugin JAR file (ZIP is in attached files, contains plugin and Java source code) and put it to dropins folder.
Start Eclipse IDE.
Create new project from main menu: File -> New -> Project... -> General/Project

Pawn compiler

Configure compiler
Select from main menu: Run -> External Tools -> External Tools Configurations...
Add new launch configuration for Program
Name: Pawn compiler
Location: ${project_loc}/pawno/pawncc.exe
Working Directory: ${container_loc}
Arguments: "${resource_loc}" -; -(

Configure auto-refresh (optional)
Select Refresh tab
Check "Refresh resources upon completion"
Select "The folder containing the selected resource"

Press "Apply" and then "Close"

Run compiler
Select the .pwn file you want to compile (or put cursor inside editor)
Select from main menu: Run -> External Tools -> Pawn compiler

Screenshots






Changelog

1.1.0

Added code templates

1.0.0

Initial release


Any feedback (comments, bugs, suggestions etc) is welcome.
Reply
#2

Although I would prefer an IntelliJ plugin, this is the next best thing. You're awesome. Thanks!
Reply
#3

Well done!
Reply
#4

Good job!
Reply
#5

This is great. I like using eclipse, will surely give it a go.
Reply
#6

New version (1.1.0) released, added code templates.
Before installing the new version, delete the completions.txt file in workspace folder: .metadata/.plugins/ee.jb.pawn/
Reply
#7

Impressive, good work. I thought of doing this too (for either eclipse or intellij) but never made time for it and I use vim for pawn anyways.
Reply
#8

Looks good, GJ.
Reply
#9

Quote:
Originally Posted by Chaser98
View Post
Although I would prefer an IntelliJ plugin, this is the next best thing. You're awesome. Thanks!
+1 on that
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)