IntelliJ IDEA Groovy(转)
更新环境变量:
source /etc/profile
验证是否成功:
# groovy -version
Groovy Version: 2.3.6 JVM: 1.7.0_67 Vendor: Oracle Corporation OS: Linux
打开groovyConsole:
4)、使用IDE进行开发(这里以Intellij idea 13.1为例)
1. Enable the plugin
Before you create your first Groovy application make sure Groovy plugin is enabled in Settings → Plugins.
2. Create a new project
Open Project Wizard and select Scala template. Since Groovy requires Java you have to specify the Project SDK.
If you create a Groovy project for the first time IntelliJ IDEA will offer you to create Groovy SDK library. Press Create button and choose directory with a Groovy SDK.
The IDE will create an empty project.
3. Create a new class
The easiest way to create Groovy class or script is to use Ctrl + N shortcut from Project View or Navigation Bar.
Choose between class, interface, enum and annotation with Up and Down arrows.
Let's create a class with a method returning 'Hello, world!' string.
4. Create a new script
Now we can create a script file via Ctrl + N shortcut.
Choose between script and GroovyDSL script with Up and Down arrows.
Now we can create an instance of our class and invoke hello method.
5. Run the project
In order to run the application you can manually create a Run configuration via Run → Edit configurations or run the active script automatically by pressing Ctrl + Shift + F10 shortcut.
使用Groovy Shell :
打开Tools-->Groovy Shell...
使用Groovy Console :
打开Tools-->Groovy Console...
http://www.it165.net/os/html/201409/9276.html
IntelliJ IDEA Groovy(转)的更多相关文章
- Groovy 配置环境变量
转载请标明出处:http://blog.csdn.net/zhaoyanjun6/article/details/70313790 本文出自[赵彦军的博客] 概念 Groovy 配置环境变量 开发工具 ...
- 30分钟groovy快速入门并掌握(ubuntu 14.04+IntelliJ 13)
本文适合于不熟悉 Groovy,但想快速轻松地了解其基础知识的 Java开发人员.了解 Groovy 对 Java 语法的简化变形,学习 Groovy 的核心功能,例如本地集合.内置正则表达式和闭包. ...
- Configuring Groovy SDK within IntelliJ IDEA
一.原因 IntelliJ IDEA期待一个the standard Groovy SDK 二.解决方案: 下载安装Groovy就可以了 官网下载地址: http://groovy-lang ...
- 利用IntelliJ IDEA创建第一个Groovy工程
因为某些原因,需要学习一下Groovy.关于Groovy的入门教程请看这篇文章http://www.ibm.com/developerworks/cn/education/java/j-groovy/ ...
- IntelliJ IDEA 内存优化最佳实践
本文作者在和同事的一次讨论中发现,对 IntelliJ IDEA 内存采用不同的设置方案,会对 IDE 的速度和响应能力产生不同的影响. Don't be a Scrooge and give you ...
- 【IDEA】intellij idea 插件推荐
CSDN 2016博客之星评选结果公布 [系列直播]零基础学习微信小程序! "我的2016"主题征文活动 博客的神秘功能 [IDEA]intellij idea ...
- [转]IntelliJ IDEA 使用心得与常用快捷键
IntelliJ IDEA 使用心得与常用快捷键 那种酸爽,根本说不出来—————————————————————————— by: Jimi没有BondJimi是谁? 就是洒家啊! 刚开始学习写Ja ...
- Atitit intellij idea的使用总结attilax
Atitit intellij idea的使用总结attilax 1. ideaIC-2016.2.4.exe1 1.1. Ij vs eclipse市场份额1 1.2. Ij的优点(方便的支持gro ...
- IntelliJ IDEA 使用总结[zz]
本文转自:http://cowboy-bebop.iteye.com/blog/1035550,仅做稍微整理,转载请注明出处. 1. IDEA内存优化 因机器本身的配置而配置: \IntelliJ I ...
随机推荐
- WordPress的用户系统总结
原文发表自我的个人主页,欢迎大家訪问~转载请保留本段,或注明原文链接:http://www.hainter.com/wordpress-user-module keyword:WordPress,用户 ...
- HDU 4344 随机法判素数(费马小定理
#include <cstdio> #include <ctime> #include <cmath> #include <algorithm> usi ...
- Shell 传递参数
Shell 传递参数 向脚本传递参数,格式为:$n. 向脚本传递三个参数,并分别输出: echo "Shell 传递参数实例!"; echo "第一个参数为:$1&quo ...
- 人事管理系统 c语言版
int menu(){ printf("请按提示输入完毕操作!\n"); printf("1.查询员工信息\n"); printf("2.统计 ...
- Swift - 移除页面视图上的所有元素
下面代码可以遍历移除页面视图上的所有元件 1 2 3 4 5 6 //清空所有子视图 func clearViews() { for v in self.view.subviews as [U ...
- 跟我一起学extjs5(11--自己定义模块的设计)
跟我一起学extjs5(11--自己定义模块的设计) 从这一节開始我们来设计并完毕一个自己定义模块.我们先来确定一个独立的模块的所能定义的一些模块信息. 下面信息仅仅是我自己在开发过程中 ...
- android百度地图打包混淆 用不了No such file or directory (2) com.baidu.mapapi.BMapManager.init(Unknown Source)
调用了百度地图地图开发包是baidumapapi_v2_1_1.jar,定位SDK版本是locSDK_3.3.jar 调试的时候能运行!可是打包签名后就运行不了! baidu google 了好久! ...
- ThinkPhp学习13
原文:ThinkPhp学习13 简单登录验证 创建Login类 <?php class LoginAction extends Action { function index(){ $this- ...
- jquery怎么在点击li标签之后添加一个在class,点击下一个li时删除上一个class?
思路:点击当前li元素后是用removeClass()删除所有兄弟元素(使用siblings()获取)的class样式,然后使用addClass()为当前li添加class. 具体演示如下: 1.HT ...
- HDU 1142 A Walk Through the Forest(dijkstra+记忆化DFS)
题意: 给你一个图,找最短路.但是有个非一般的的条件:如果a,b之间有路,且你选择要走这条路,那么必须保证a到终点的所有路都小于b到终点的一条路.问满足这样的路径条数 有多少,噶呜~~题意是搜了解题报 ...