Add support for ocp-indent as an executable and Docker image docs

This commit is contained in:
Steven Zeck 2017-11-11 13:45:30 -06:00
parent 3dd3a2b9e9
commit b3c9c3c2ab
4 changed files with 53 additions and 3 deletions

View File

@ -97,7 +97,7 @@ Some of the supported beautifiers are developed for Node.js and are automaticall
| Lua beautifier | :white_check_mark: | :ok_hand: Not necessary | :smiley: Nothing! |
| Marko Beautifier | :white_check_mark: | :ok_hand: Not necessary | :smiley: Nothing! |
| Nginx Beautify | :white_check_mark: | :ok_hand: Not necessary | :smiley: Nothing! |
| ocp-indent | :warning: Manual installation | :construction: Not an executable | :page_facing_up: Go to https://www.typerex.org/ocp-indent.html and follow the instructions. |
| ocp-indent | :warning: 1 executable | :white_check_mark: :100:% of executables | :whale: With [Docker](https://www.docker.com/):<br/>1. Install [ocp-indent (`ocp-indent`)](https://www.typerex.org/ocp-indent.html) with `docker pull unibeautify/ocp-indent`<br/><br/>:bookmark_tabs: Manually:<br/>1. Install [ocp-indent (`ocp-indent`)](https://www.typerex.org/ocp-indent.html) by following https://www.typerex.org/ocp-indent.html#installation<br/> |
| Perltidy | :warning: Manual installation | :construction: Not an executable | :page_facing_up: Go to http://perltidy.sourceforge.net/ and follow the instructions. |
| PHP-CS-Fixer | :warning: 2 executables | :warning: Only 1 of 2 executables | :whale: With [Docker](https://www.docker.com/):<br/>1. Install [PHP-CS-Fixer (`php-cs-fixer`)](https://github.com/FriendsOfPHP/PHP-CS-Fixer) with `docker pull unibeautify/php-cs-fixer`<br/><br/>:bookmark_tabs: Manually:<br/>1. Install [PHP (`php`)](http://php.net/) by following http://php.net/manual/en/install.php<br/>2. Install [PHP-CS-Fixer (`php-cs-fixer`)](https://github.com/FriendsOfPHP/PHP-CS-Fixer) by following https://github.com/FriendsOfPHP/PHP-CS-Fixer#installation<br/> |
| PHPCBF | :warning: 2 executables | :warning: Only 1 of 2 executables | :whale: With [Docker](https://www.docker.com/):<br/>1. Install [PHPCBF (`phpcbf`)](https://github.com/squizlabs/PHP_CodeSniffer) with `docker pull unibeautify/phpcbf`<br/><br/>:bookmark_tabs: Manually:<br/>1. Install [PHP (`php`)](http://php.net/) by following http://php.net/manual/en/install.php<br/>2. Install [PHPCBF (`phpcbf`)](https://github.com/squizlabs/PHP_CodeSniffer) by following https://github.com/squizlabs/PHP_CodeSniffer#installation<br/> |

View File

@ -283,6 +283,23 @@ Options for isort executable.
2. Go into *Packages* and search for "*Atom Beautify*" package.
3. Find the option "*isort*" and change it to your desired configuration.
##### [ocp-indent](#ocp-indent)
**Important**: This option is only configurable from within Atom Beautify's setting panel.
**Type**: `object`
**Description**:
Options for ocp-indent executable.
**How to Configure**
1. You can open the [Settings View](https://github.com/atom/settings-view) by navigating to
*Edit > Preferences (Linux)*, *Atom > Preferences (OS X)*, or *File > Preferences (Windows)*.
2. Go into *Packages* and search for "*Atom Beautify*" package.
3. Find the option "*ocp-indent*" and change it to your desired configuration.
##### [PHP](#php)
**Important**: This option is only configurable from within Atom Beautify's setting panel.

View File

@ -8,7 +8,24 @@ Beautifier = require('./beautifier')
module.exports = class OCPIndent extends Beautifier
name: "ocp-indent"
link: "https://www.typerex.org/ocp-indent.html"
isPreInstalled: false
executables: [
{
name: "ocp-indent"
cmd: "ocp-indent"
homepage: "https://www.typerex.org/ocp-indent.html"
installation: "https://www.typerex.org/ocp-indent.html#installation"
version: {
parse: (text) ->
try
text.match(/version (\d+\.\d+\.\d+)/)[1]
catch
text.match(/version (\d+\.\d+)/)[1] + ".0"
}
docker: {
image: "unibeautify/ocp-indent"
}
}
]
options: {
OCaml: true
@ -21,4 +38,4 @@ module.exports = class OCPIndent extends Beautifier
help: {
link: "https://www.typerex.org/ocp-indent.html"
}
})
})

View File

@ -9320,6 +9320,22 @@
}
}
},
"ocp-indent": {
"key": "ocp-indent",
"title": "ocp-indent",
"type": "object",
"collapsed": true,
"description": "Options for ocp-indent executable.",
"properties": {
"path": {
"key": "path",
"title": "Binary/Script Path",
"type": "string",
"default": "",
"description": "Absolute path to the \"ocp-indent\" executable's binary/script."
}
}
},
"php": {
"key": "php",
"title": "PHP",