この文書の現在のバージョンと選択したバージョンの差分を表示します。
両方とも前のリビジョン 前のリビジョン | |||
aws_cloud9 [2018/02/08 11:01] fifi |
aws_cloud9 [2018/02/08 11:02] (現在) fifi |
||
---|---|---|---|
ライン 1: | ライン 1: | ||
## PHPのFormatter | ## PHPのFormatter | ||
+ | |||
+ | [PHP Beautifier / Formatter for cloud9 IDE - Stack Overflow](https://stackoverflow.com/questions/40972683/php-beautifier-formatter-for-cloud9-ide) | ||
+ | |||
``` | ``` | ||
- | var_dump($row1); | + | $ wget https://github.com/FriendsOfPHP/PHP-CS-Fixer/releases/download/v2.0.0/php-cs-fixer.phar -O ~/php-cs-fixer |
+ | $ mkdir ~/bin; mv ~/php-cs-fixer ~/bin | ||
+ | $ chmod a+x ~/bin/php-cs-fixer | ||
+ | ``` | ||
+ | |||
+ | code formatterに以下を指定する | ||
+ | ``` | ||
+ | php-cs-fixer fix "$file" --rules=@Symfony,@PSR2 | ||
+ | |||
+ | ``` | ||
+ | |||
+ | |||
+ | |||
## 雑多なメモ | ## 雑多なメモ |