phpstorm 自动格式化代码

打开文件>设置;

搜索“KEYMAP”并打开它;

搜索“Save All”并双击“Save All”;

选择“Remove Ctrl+S”;

双击“Remove Ctrl+S”,并选择“Add Keyboard Shortcut”;

键盘上按“CTRL+ALT+Shift +S”。

确认并退出设置。

编辑>宏>启动宏记录

按下CTRL+ALT+L,然后是CTRL+S。

停止记录宏点击页面右下角的停止按钮。

给这个宏一个名字,比如“Format and Save”

将CTRL+S指定为“Format and Save”方法

打开文件>设置;

搜索“KEYMAP”并打开它;

搜索“Format and Save”,双击“Format and Save”动作;

选择“Add Keyboard Shortcut”;

键盘按“Ctrl +S”。

确认并退出设置。

完成!

猜你喜欢

转载自blog.csdn.net/qq_36798131/article/details/83010352