Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[pull] master from mlocati:master #92

Open
wants to merge 63 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
63 commits
Select commit Hold shift + click to select a range
0d1fa9a
Switch to node 18
mlocati Nov 30, 2022
5039a32
Add Export access key
mlocati Nov 30, 2022
5ad50b6
Remember more export options
mlocati Nov 30, 2022
1218535
Merge pull request #36 from mlocati/export-improvements
mlocati Nov 30, 2022
5fe5b52
[skip ci] Automatic assets rebuilding
mlocati Nov 30, 2022
68873ee
Minor code cleanup
mlocati Nov 30, 2022
7e655a7
Add a bare "PHP array" exporter
mlocati Nov 30, 2022
a7bc8d9
Merge pull request #37 from mlocati/php-array-exporter
mlocati Nov 30, 2022
63adb29
[skip ci] Automatic assets rebuilding
mlocati Nov 30, 2022
23dffd4
Simplify build setup
mlocati Nov 30, 2022
605ee41
Add missing entry in help dialog
mlocati Dec 1, 2022
724f413
Merge pull request #38 from mlocati/simpler-build
mlocati Dec 1, 2022
6f7fd08
Merge pull request #39 from mlocati/help-add-deprecated-info
mlocati Dec 1, 2022
a824211
[skip ci] Automatic assets rebuilding
mlocati Dec 1, 2022
c9e66b0
New PHP-CS-Fixer versions: 3.13.1
mlocati Dec 18, 2022
cbb5f8e
New PHP-CS-Fixer versions: 3.13.2
mlocati Jan 10, 2023
6b5f218
New PHP-CS-Fixer versions: 3.14.3
mlocati Jan 30, 2023
b05ebf4
New PHP-CS-Fixer versions: 3.14.4
mlocati Feb 10, 2023
397e5ab
New PHP-CS-Fixer versions: 3.14.5, 3.15.0
mlocati Mar 13, 2023
0ef880c
New PHP-CS-Fixer versions: 3.15.1
mlocati Mar 14, 2023
5a27b44
New PHP-CS-Fixer versions: 3.16.0
mlocati Apr 3, 2023
5002a0f
New PHP-CS-Fixer versions: 3.17.0
mlocati May 22, 2023
6a7a87d
Simplify docker image
mlocati Jun 20, 2023
3710938
Fix unary_operator_spaces
mlocati Jun 21, 2023
c049da8
Rebuild all data
mlocati Jun 21, 2023
208ea74
New PHP-CS-Fixer versions: 3.18.0
mlocati Jun 21, 2023
a0e39c7
New PHP-CS-Fixer versions: 3.19.0
mlocati Jun 24, 2023
987a6ae
New PHP-CS-Fixer versions: 3.19.1
mlocati Jun 25, 2023
75e55ef
New PHP-CS-Fixer versions: 3.19.2
mlocati Jun 25, 2023
1d72163
New PHP-CS-Fixer versions: 3.20.0
mlocati Jun 27, 2023
f397c01
New PHP-CS-Fixer versions: 3.21.0
mlocati Jul 5, 2023
83144d0
Fix typo in version comparison
mlocati Jul 5, 2023
563ff4d
[skip ci] Automatic assets rebuilding
mlocati Jul 5, 2023
8774b39
New PHP-CS-Fixer versions: 3.21.1
mlocati Jul 5, 2023
2e04358
New PHP-CS-Fixer versions: 3.21.3, 3.22.0
mlocati Jul 17, 2023
b2e3db3
New PHP-CS-Fixer versions: 3.23.0, 3.24.0
mlocati Aug 30, 2023
ede745c
New PHP-CS-Fixer versions: 3.25.1
mlocati Sep 4, 2023
fbf04fa
New PHP-CS-Fixer versions: 3.26.0
mlocati Sep 8, 2023
3b7a04d
New PHP-CS-Fixer versions: 3.26.1
mlocati Sep 8, 2023
188328e
fix: Cannot set custom values for 'blank_lines_before_namespace' (#42)
Sep 11, 2023
e981d9f
[skip ci] Automatic assets rebuilding
mlocati Sep 11, 2023
b442715
New PHP-CS-Fixer versions: 3.27.0
mlocati Sep 17, 2023
e92f631
New PHP-CS-Fixer versions: 3.28.0
mlocati Sep 22, 2023
3f16cdf
New PHP-CS-Fixer versions: 3.29.0
mlocati Sep 26, 2023
514287f
New PHP-CS-Fixer versions: 3.30.0
mlocati Sep 27, 2023
c2f21ae
New PHP-CS-Fixer versions: 3.31.0
mlocati Sep 29, 2023
0f7d58f
New PHP-CS-Fixer versions: 3.32.0
mlocati Sep 29, 2023
0a8e163
Use PHP 8.3 by default
mlocati Sep 29, 2023
4d9019b
New PHP-CS-Fixer versions: 3.33.0, 3.34.0
mlocati Sep 29, 2023
2d285e8
New PHP-CS-Fixer versions: 3.32.1, 3.33.1, 3.34.1
mlocati Oct 4, 2023
cbb5c44
New PHP-CS-Fixer versions: 3.35.1
mlocati Oct 12, 2023
a5d44a6
New PHP-CS-Fixer versions: 3.36.0
mlocati Oct 27, 2023
7972d79
Add new configuration file name and include example (#43)
mlocati Oct 27, 2023
bc693a7
[skip ci] Automatic assets rebuilding
mlocati Oct 27, 2023
547389d
New PHP-CS-Fixer versions: 3.37.0
mlocati Oct 28, 2023
57816ab
New PHP-CS-Fixer versions: 3.37.1
mlocati Oct 29, 2023
ef52651
New PHP-CS-Fixer versions: 3.38.0
mlocati Nov 7, 2023
5bb9b2f
Minor change (#44)
mlocati Nov 7, 2023
6f57950
Fix Style-CI export when no rule is selected (#51)
mlocati Nov 13, 2023
73abc39
[skip ci] Automatic assets rebuilding
mlocati Nov 13, 2023
333779f
Make it clear that we use composer "dynamically" (#52)
mlocati Nov 13, 2023
0a27730
feat: add Laravel pint compatible json export (#50)
Shikachuu Nov 13, 2023
c9c065d
[skip ci] Automatic assets rebuilding
mlocati Nov 13, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ jobs:
- name: Install Node
uses: actions/setup-node@v1
with:
node-version: "14"
node-version: "18"
- name: Install dependencies
run: npm ci
- name: Build
Expand Down
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
/.php_cs
/.php_cs.cache
/composer.json
/composer.lock
/docs/hot
/docs/mix-manifest.json
Expand Down
5 changes: 0 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,18 +17,13 @@ The PHP-CS-Fixer data is extracted by a couple of PHP scripts.

1. install [PHP](https://php.net/)
2. install [Composer](https://getcomposer.org/) and add it to the `PATH` environment variable, so that it can be executed by running `composer`
3. run
```sh
composer install
```

### Updating the data to the most recent versions

```sh
./bin/update-docs-all
```


### (Re)Generate the data for all the versions

```sh
Expand Down
9 changes: 6 additions & 3 deletions bin/update-docs
Original file line number Diff line number Diff line change
Expand Up @@ -51,10 +51,10 @@ function deleteFromFilesystem($path)

try {
if (isset($argv[1])) {
if (is_file(dirname(__DIR__) . '/composer.lock')) {
@unlink(dirname(__DIR__) . '/composer.lock');
}
deleteFromFilesystem(dirname(__DIR__) . '/composer.json');
deleteFromFilesystem(dirname(__DIR__) . '/composer.lock');
deleteFromFilesystem(dirname(__DIR__) . '/vendor');
copy(dirname(__DIR__) . '/composer-template.json', dirname(__DIR__) . '/composer.json');
fwrite(STDOUT, "Installing PHP-CS-Fixer version {$argv[1]}... ");
$cmd = ['composer'];
$cmd[] = '--prefer-lowest';
Expand All @@ -76,6 +76,9 @@ try {
exit($rc);
}
fwrite(STDOUT, "done.\n");
} elseif (!file_exists(__DIR__ . '/vendor/autoload.php')) {
fwrite(STDERR, "Dependencies not installed yet.\nPlease specify the version you want to work on.\n");
exit(1);
}

require_once dirname(__DIR__) . '/php/Patcher.php';
Expand Down
26 changes: 8 additions & 18 deletions bin/update-docs-all
Original file line number Diff line number Diff line change
Expand Up @@ -236,22 +236,12 @@ class PCFCWorker
}
}

public function resetComposerJson()
public function deleteComposerStuff()
{
$rootDir = $this->getRootDir();
$args = [
'composer',
escapeshellarg('--working-dir=' . $rootDir),
'--no-update',
'require', escapeshellarg('friendsofphp/php-cs-fixer:^2 || ^3'),
];
passthru(implode(' ', $args));
if (is_file($rootDir . '/composer.lock')) {
unlink($rootDir . '/composer.lock');
}
if (is_dir($rootDir . '/vendor')) {
$this->unlink($rootDir . '/vendor');
}
$this->unlink("{$rootDir}/composer.json");
$this->unlink("{$rootDir}/composer.lock");
$this->unlink("{$rootDir}/vendor");
}

/**
Expand All @@ -273,7 +263,7 @@ class PCFCWorker
*/
private function unlink($path)
{
if (is_dir($path)) {
if (is_dir($path) && !is_link($path)) {
foreach (scandir($path) as $entry) {
$entryPath = $path . '/' . $entry;
switch ($entry) {
Expand All @@ -286,7 +276,7 @@ class PCFCWorker
}
}
rmdir($path);
} else {
} elseif (is_file($path)) {
unlink($path);
}
}
Expand Down Expand Up @@ -394,8 +384,8 @@ try {
}
} finally {
if ($someVersionParsed) {
fwrite(STDOUT, "Resetting composer.json.\n");
$worker->resetComposerJson();
fwrite(STDOUT, "Deleting composer stuff.\n");
$worker->deleteComposerStuff();
}
}
} catch (RuntimeException $x) {
Expand Down
29 changes: 29 additions & 0 deletions composer-template.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
{
"name": "mlocati/php-cs-fixer-configurator",
"description": "Inspect PHP-CS-Fixer fixers and easily configure it",
"license": "MIT",
"type": "project",
"keywords": ["php-cs-fixer"],
"authors": [
{
"name": "Michele Locati",
"email": "[email protected]",
"homepage": "https://mlocati.github.io",
"role": "Author"
}
],
"homepage": "https://github.com/mlocati/php-cs-fixer-configurator",
"support": {
"issues": "https://github.com/mlocati/php-cs-fixer-configurator/issues",
"source": "https://github.com/mlocati/php-cs-fixer-configurator"
},
"autoload": {
"psr-4": {
"MLocati\\PhpCsFixerConfigurator\\": "php"
}
},
"config": {
"lock": false
},
"$schema": "https://raw.githubusercontent.com/composer/composer/main/res/composer-schema.json"
}
30 changes: 0 additions & 30 deletions composer.json

This file was deleted.

6 changes: 3 additions & 3 deletions docs/css/app.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion docs/data/3.13.0.json → docs/data/3.13.2.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"version": "3.13.0",
"version": "3.13.2",
"indent": " ",
"lineEnding": "\n",
"fixers": {
Expand Down
2 changes: 1 addition & 1 deletion docs/data/3.13.0.min.json → docs/data/3.13.2.min.json

Large diffs are not rendered by default.

Loading