idea总结

1、Intellij IDEA启动时怎么选择项目?

按下【Ctrl+Alt+S】,在设置界面选择【System Settings】,把右边面版中Reopen last project on startup前面的勾去掉,保存。

 

2、tomcat启动的情况下,修改了jsp文件,怎么热部署jsp文件?

Intellij IDEA默认文件是自动保存的,但是手头有个项目jsp文件改动后,在tomcat中不能立即响应变化。要jsp文件改动后立刻看到变化,有个配置。
在idea tomcat 中server的配置里,有个on frame deactivation,选择update classes and resources。另外有个配置on update action,就是手动操作的时候采取什么动作,可以重启服务器,也可以像上面一样更新类和资源文件,我选的是Redeploy。 可是当前项目没有update classes and resources这个选项,有个Hot Swap classes。
这是由于服务器添加的Artifact类型问题,一般一个module对应两种类型的Artifact,一种是war,一种是war explored。
war就是已war包形式发布,当前项目是这种形式,在这种形式下on frame deactivation配置没有update classes and resources选项。war explored是发布文件目录,选择这种形式,on frame deactivation中就出现update classes and resources选项了。

 

3、intellij idea 注释行如何自动缩进?

进入 Settings -> Code Style -> Java ,在右边选择 “Code Generation” Tab,然后找到 Comment Code 那块,把 【Line comment at first column】、【Block comment at first column】两个前面的复选框去掉就可以了。

4、执行 archetype:generate 的时候,会产生[INFO] Generating project in Batch mode,然后就一直阻塞在这里?
原因是:网速问题,如何在idea里设置maven参数:

5、IDEA调试Android应用,提示

Cannot debug application xx.xxx.xxx.app on device huawei-huawei_g7_tl00.
This application does not have the debuggable attribute enabled in its manifest.
If you have manually set it in the manifest, then remove it and let the IDE automatically assign it.
If you are using Gradle, make sure that your current variant is debuggable.

提示比较明显,要设置debuggable开关,但忘了在哪个标签内了。。GG

解决:<application android:debuggable="true"></application>
加上以后AndroidManifest.xml会有红线提示,release版本时删掉

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值