Java Software Development

Micro-services Kubernetes Others

Let's talk!

  

Emacs Grails Mode additions on GitHub!

Posted at December 10th, 2012
Posted by yves
Tags: Tags: ,
Categories: emacs

Introduction

GNU Emacs is a great text editor. If you lookup videos on Youtube, you see some amazing things.

By using useful plugins with decent keybindings, we can type less and try avoiding the famous RSI(Repetitive strain injury).

There are not many packages or modes available for Grails development with Emacs. With couple of Lisp files combinations, you get mainly syntax highlighting and easy navigation between files.

The goal of the Emacs Grails Mode Extensions is to provide the ability of running Grails command for a given project. It is a one time effort to make life easier when working on Grails applications, as I don’t know much about Lisp in general. There are likely couple of issues with the code, but hopefully an Lisp hacker can take it from there to build something more useful…

Are Emacs Grails additions useful?

On a typical day, most developers spend time jumping between files and running couple of commands, while adding few lines of code here and there. Several applications are involved in a development workflow (Web Browsing, Command prompt as needed, IDE and/or text editor, etc.). The existing Emacs Grails Mode doesn’t provide lots of features in addition to file navigation.

With the Emacs Grails mode extensions, you can:

  • Browse documentation (wiki, reference guide and api documentation)
  • Run Grails scripts (run-app, install-plugin, etc.) on a project. A dedicated *Grails* buffer contains the result of commands that are run asynchronously.

Switching between many applications while working is no fun and if we can do most of the work with only ONE tool, that’s great!

Available functions

All commands start with grails/

Click <mouse-2> on a completion to select it.
In this buffer, type RET to select the completion near point.

Possible completions are:
grails/browse-api-docs  
grails/browse-latest-guide
grails/browse-wiki-docs
grails/create-controller
grails/create-domain
grails/create-service
grails/create-taglib
grails/icommand
grails/install-plugin
grails/package-plugin
grails/refresh-dependencies
grails/uninstall-plugin

To create a domain class we would use the following command M-x grails/create-domain.

Grails mode menubar contributions

The extension inject few additional menu items in the existing Grails menu.

grails-menu.png

Grails menu screenshot

Share this post
Facebook Twitter Digg Plusone Reddit Stumbleupon



© 2012-2024, Rimero Solutions Inc.

Slideshare presentations

Grails and build tools


Recent Blog posts

Micro-services – Service mesh


Latest tweets

Added maven plugin support to maven-wrapper.


Brand-new screen-casts

Introduction to ant-wrapper and maven-wrapper


Github activity

Apache Ant Git tasks