Skip to content

Commit ea8a586

Browse files
committed
moving obfuscate to bin and including in composer.json
1 parent be1584b commit ea8a586

File tree

3 files changed

+10
-4
lines changed

3 files changed

+10
-4
lines changed

README.md

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,9 +15,11 @@ It is compatible with PHP up to and including 5.5.
1515
After cloning this repository (`git clone https://github.com/naneau/php-obfuscator`), run the following command to obfuscate a directory of PHP files:
1616

1717
```bash
18-
./obfuscate obfuscate /input/directory /output/directory
18+
./bin/obfuscate obfuscate /input/directory /output/directory
1919
```
2020

21+
If you've installed this package through [Composer](https://getcomposer.org), you'll find the `obfuscate` command in the relevant [bin dir](https://getcomposer.org/doc/articles/vendor-binaries.md).
22+
2123
### Configuration
2224

2325
You may find that you'll need to prevent certain variables and methods from being renamed. In this case you can create a simple YAML configuration file
@@ -41,5 +43,5 @@ parameters:
4143
You can run the obfuscator with a configuration file through
4244
4345
```bash
44-
./obfuscate obfuscate /input/directory /output/directory --config=/foo/bar/config.yml
46+
./bin/obfuscate obfuscate /input/directory /output/directory --config=/foo/bar/config.yml
4547
```

obfuscate renamed to bin/obfuscate

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
#!/usr/bin/env php
22
<?php
33

4-
include __DIR__ . '/vendor/autoload.php';
4+
include __DIR__ . '/../vendor/autoload.php';
55

66
ini_set('xdebug.max_nesting_level', 2000);
77

composer.json

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,11 @@
22
"name": "naneau/php-obfuscator",
33
"description": "A basic but functional PHP obfuscator for object oriented PHP",
44
"license": "MIT",
5-
"minimum-stability": "dev",
5+
"minimum-stability": "dev", // Dev for php-parser ~1
6+
7+
"bin": [
8+
"bin/obfuscate"
9+
],
610

711
"autoload": {
812
"psr-4": {

0 commit comments

Comments
 (0)