zoukankan      html  css  js  c++  java
  • idea 安装热部署插件

     jrebel(http://zeroturnaround.com/)的作用就是当你的代码改变时,你不需要重启服务,节省了时间。代码的改变有很多种,比如增加class、在class中增加方法等等。下面介绍一下 java 开发利器 intellij idea 怎样安装 jrebel。

    1.安装 jrebel 插件

        在 intellij idea 中,打开 File - Settings(ctrl + alt + s),点击弹出的对话框中的 plugins。 
     
     
        点击对话框底部中间的按钮 Browse repositories...,在弹出的对话框中可以搜索你需要的插件。我们搜索 jrebel。
     
        搜索后,会显示两个 jrebel 的插件。我们安装 JRebel for Intellij,选中此插件,对话框右边有个绿色的 install plugin 按钮。点击安装即可。 安装完成之后,需要重启 intellij idea。
     
        安装好后,在 intellij idea 的右上角,有两个 jrebel 的图标。一个是正常启动模式,一个是 debug 模式。
     

    2.破解 jrebel

        jrebel唯一不好的地方就是收费的大笑。对于我等屌丝的话,只能默默破解了。我现在jrebel使用的版本是6.2.5。点击这里,下载jrebel破解版。解压破解文件后,将
            jrebel.lic 复制到 C:Users你的用户名.jrebel 下
            jrebel.jar 复制到 C:Users你的用户名.IntelliJIdea14configpluginsjr-ide-idealibjrebel 下
        
        打开 intellij idea(如果破解的时候,你的 intellij idea 是打开的,则需要重启),点击 File - Settings(ctrl + alt + s),点击 弹出对话框的 JRebel。右边的 License 显示 VALID,表示破解成功。恭喜!
     

    3.使用 JRebel

        打开 intellij idea 左下角的 JRebel 选项卡,这里可以看到你的项目。如果你的项目想使用jrebel,勾选项目下的复选框即可。
     
        设置 tomcat 选项,点击 intellij idea 右上角。
     
        在 弹出的对话框 中,修改 红色框的内容,保存即可。
     
        点击  中的一个,启动服务吧。
     
        服务启动后,当你修改一个class 后,控制台 显示  JRebel: Reloading class ...,说明 jrebel 已经发挥作用了。
     
     
    --------------------------------------------------------------------------------------------------------------------------------------------------------------------
    2015-10-20 更新
     
    如果修改了 class,jrebel 没有自动部署。那就设置一下 代码编译 后的输出目录。
    1.打开 项目结构(ctrl + shfit + alt + s) 对话框,修改 class 的输出目录到 web 的 classes 下。
     
    2.生成 jrebel 配置文件。在项目上右键 - jrebel - jrebel.xml。
     
    3.重启服务即可。
    版权声明:本文为博主原创文章,未经博主允许不得转载。
    qq_18897163
     
    masuwen
     
     
     
  • 相关阅读:
    共轭梯度法
    OpenGLGLUT教程(十一) GLUT子菜单
    怎样让函数返回数组
    OpenGLGLUT教程(九) GLUT鼠标
    OpenGLGLUT教程(七) GLUT高级键盘控制
    OpenGLGLUT教程(六) GLUT场景漫游
    OpenGLGLUT教程(五) GLUT键盘控制
    OpenGLGLUT教程(八) GLUT场景漫游II
    dos指令 批处理文件
    新的启程!
  • 原文地址:https://www.cnblogs.com/a8457013/p/7866579.html
Copyright © 2011-2022 走看看