128 changed files with 892 additions and 652 deletions
-
80.ci/rector.php
-
36.ci/rector.sh
-
11app/Console/AutoImports.php
-
10app/Console/Commands/UpgradeImportConfigurations.php
-
2app/Console/HaveAccess.php
-
12app/Console/Kernel.php
-
3app/Console/VerifyJSON.php
-
4app/Exceptions/AgreementExpiredException.php
-
4app/Exceptions/ApiException.php
-
4app/Exceptions/ApiHttpException.php
-
7app/Exceptions/Handler.php
-
4app/Exceptions/ImportException.php
-
4app/Exceptions/ImporterErrorException.php
-
4app/Exceptions/ImporterHttpException.php
-
4app/Exceptions/RateLimitException.php
-
4app/Exceptions/SpectreErrorException.php
-
4app/Exceptions/SpectreHttpException.php
-
3app/Http/Controllers/AutoImportController.php
-
3app/Http/Controllers/AutoUploadController.php
-
7app/Http/Controllers/DebugController.php
-
12app/Http/Controllers/Import/AuthenticateController.php
-
14app/Http/Controllers/Import/ConfigurationController.php
-
27app/Http/Controllers/Import/ConversionController.php
-
8app/Http/Controllers/Import/DownloadController.php
-
7app/Http/Controllers/Import/DuplicateCheckController.php
-
33app/Http/Controllers/Import/MapController.php
-
3app/Http/Controllers/Import/Nordigen/SelectionController.php
-
5app/Http/Controllers/Import/Spectre/ConnectionController.php
-
8app/Http/Controllers/Import/SubmitController.php
-
11app/Http/Controllers/Import/UploadController.php
-
12app/Http/Controllers/ServiceController.php
-
15app/Http/Controllers/TokenController.php
-
2app/Http/Kernel.php
-
2app/Http/Middleware/Authenticate.php
-
3app/Http/Middleware/IsReadyForStep.php
-
3app/Http/Middleware/RedirectIfAuthenticated.php
-
2app/Http/Request/ConfigurationPostRequest.php
-
3app/Http/Request/Request.php
-
2app/Http/Request/RolesPostRequest.php
-
2app/Http/Request/SelectionRequest.php
-
43app/Jobs/ProcessImportSubmissionJob.php
-
3app/Mail/ImportReportMail.php
-
6app/Providers/AppServiceProvider.php
-
3app/Rules/Iban.php
-
3app/Services/CSV/Configuration/ConfigFileProcessor.php
-
14app/Services/CSV/Conversion/Routine/CSVFileProcessor.php
-
11app/Services/CSV/Conversion/Routine/ColumnValueConverter.php
-
2app/Services/CSV/Conversion/Routine/LineProcessor.php
-
3app/Services/CSV/Conversion/RoutineManager.php
-
16app/Services/CSV/Conversion/Task/Accounts.php
-
14app/Services/CSV/Converter/Amount.php
-
2app/Services/CSV/Converter/AmountNegated.php
-
2app/Services/CSV/Converter/BankDebitCredit.php
-
3app/Services/CSV/Converter/ConverterService.php
-
12app/Services/CSV/Converter/Date.php
-
2app/Services/CSV/Converter/Description.php
-
7app/Services/CSV/Converter/Iban.php
-
2app/Services/CSV/Converter/TagsComma.php
-
2app/Services/CSV/Converter/TagsSpace.php
-
4app/Services/CSV/Mapper/ExpenseRevenueAccounts.php
-
26app/Services/CSV/Mapper/MapperService.php
-
21app/Services/CSV/Roles/RoleService.php
-
5app/Services/Camt/Conversion/RoutineManager.php
-
5app/Services/Camt/Conversion/TransactionConverter.php
-
5app/Services/Camt/Conversion/TransactionExtractor.php
-
24app/Services/Camt/Conversion/TransactionMapper.php
-
80app/Services/Camt/Transaction.php
-
16app/Services/Enums/AuthenticationStatus.php
-
8app/Services/Nordigen/Authentication/SecretManager.php
-
10app/Services/Nordigen/AuthenticationValidator.php
-
6app/Services/Nordigen/Conversion/Routine/GenerateTransactions.php
-
18app/Services/Nordigen/Conversion/Routine/TransactionProcessor.php
-
3app/Services/Nordigen/Conversion/RoutineManager.php
-
27app/Services/Nordigen/Model/Transaction.php
-
2app/Services/Nordigen/Request/GetRequisitionRequest.php
-
7app/Services/Nordigen/Request/PostNewTokenRequest.php
-
13app/Services/Nordigen/Request/Request.php
-
5app/Services/Nordigen/Response/ArrayResponse.php
-
4app/Services/Nordigen/Response/GetTransactionsResponse.php
-
4app/Services/Nordigen/Response/ListAccountsResponse.php
-
4app/Services/Nordigen/Response/ListBanksResponse.php
-
5app/Services/Nordigen/Response/TokenSetResponse.php
-
9app/Services/Nordigen/TokenManager.php
-
6app/Services/Shared/Configuration/Configuration.php
-
2app/Services/Shared/Conversion/CombinedProgressInformation.php
-
6app/Services/Shared/Conversion/GeneratesIdentifier.php
-
40app/Services/Shared/Conversion/RoutineStatusManager.php
-
5app/Services/Shared/File/FileContentSherlock.php
-
29app/Services/Shared/Import/Routine/ApiSubmitter.php
-
4app/Services/Shared/Import/Routine/RoutineManager.php
-
38app/Services/Shared/Import/Status/SubmissionStatusManager.php
-
6app/Services/Shared/Submission/GeneratesIdentifier.php
-
30app/Services/SimpleFIN/Conversion/AccountMapper.php
-
43app/Services/SimpleFIN/Conversion/RoutineManager.php
-
45app/Services/SimpleFIN/Conversion/TransactionTransformer.php
-
25app/Services/SimpleFIN/Model/Account.php
-
25app/Services/SimpleFIN/Model/Transaction.php
-
2app/Services/SimpleFIN/Request/SimpleFINRequest.php
-
2app/Services/SimpleFIN/Response/PostAccountResponse.php
-
4app/Services/SimpleFIN/Response/SimpleFINResponse.php
@ -0,0 +1,80 @@ |
|||
<?php |
|||
|
|||
|
|||
/* |
|||
* rector.php |
|||
* Copyright (c) 2025 james@firefly-iii.org. |
|||
* |
|||
* This file is part of Firefly III (https://github.com/firefly-iii). |
|||
* |
|||
* This program is free software: you can redistribute it and/or modify |
|||
* it under the terms of the GNU Affero General Public License as |
|||
* published by the Free Software Foundation, either version 3 of the |
|||
* License, or (at your option) any later version. |
|||
* |
|||
* This program is distributed in the hope that it will be useful, |
|||
* but WITHOUT ANY WARRANTY; without even the implied warranty of |
|||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
|||
* GNU Affero General Public License for more details. |
|||
* |
|||
* You should have received a copy of the GNU Affero General Public License |
|||
* along with this program. If not, see https://www.gnu.org/licenses/. |
|||
*/ |
|||
|
|||
declare(strict_types=1); |
|||
|
|||
use Rector\Config\RectorConfig; |
|||
use Rector\EarlyReturn\Rector\If_\ChangeOrIfContinueToMultiContinueRector; |
|||
use Rector\Transform\Rector\String_\StringToClassConstantRector; |
|||
use RectorLaravel\Set\LaravelLevelSetList; |
|||
|
|||
|
|||
return RectorConfig::configure() |
|||
->withSkip([ |
|||
ChangeOrIfContinueToMultiContinueRector::class, |
|||
StringToClassConstantRector::class => [ |
|||
__DIR__ . '/../app/Http/Controllers/Auth/LoginController.php', |
|||
], |
|||
__DIR__.'/../bootstrap/cache/*' |
|||
]) |
|||
->withPaths([ |
|||
__DIR__ . '/../app', |
|||
__DIR__ . '/../bootstrap', |
|||
__DIR__ . '/../config', |
|||
__DIR__ . '/../public', |
|||
__DIR__ . '/../resources/lang/en', |
|||
__DIR__ . '/../routes', |
|||
__DIR__ . '/../tests', |
|||
]) |
|||
->withSets([ |
|||
LaravelLevelSetList::UP_TO_LARAVEL_120, |
|||
]) |
|||
// ->withConfiguredRule(ReplaceServiceContainerCallArgRector::class, [
|
|||
// new ReplaceServiceContainerCallArg('log', new ClassConstFetch(new Name('Illuminate\Support\Facades\Log'), 'class')),
|
|||
// ])
|
|||
// uncomment to reach your current PHP version
|
|||
->withPhpSets() |
|||
->withPreparedSets( |
|||
codingStyle: false, // leave false
|
|||
privatization: false, // leave false.
|
|||
naming: false, // leave false
|
|||
instanceOf: true, |
|||
earlyReturn: true, |
|||
strictBooleans: true, |
|||
carbon: true, |
|||
rectorPreset: true, |
|||
phpunitCodeQuality: true, |
|||
doctrineCodeQuality: true, |
|||
symfonyCodeQuality: true, |
|||
symfonyConfigs: true |
|||
|
|||
) |
|||
->withComposerBased( |
|||
twig: true, |
|||
doctrine: true, |
|||
phpunit: true, |
|||
symfony: true) |
|||
->withTypeCoverageLevel(0) |
|||
->withDeadCodeLevel(0) |
|||
->withCodeQualityLevel(0) |
|||
->withImportNames(removeUnusedImports: true);// import statements instead of full classes.
|
@ -0,0 +1,36 @@ |
|||
#!/usr/bin/env bash |
|||
|
|||
# |
|||
# phpstan.sh |
|||
# Copyright (c) 2021 james@firefly-iii.org |
|||
# |
|||
# This file is part of Firefly III (https://github.com/firefly-iii). |
|||
# |
|||
# This program is free software: you can redistribute it and/or modify |
|||
# it under the terms of the GNU Affero General Public License as |
|||
# published by the Free Software Foundation, either version 3 of the |
|||
# License, or (at your option) any later version. |
|||
# |
|||
# This program is distributed in the hope that it will be useful, |
|||
# but WITHOUT ANY WARRANTY; without even the implied warranty of |
|||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
|||
# GNU Affero General Public License for more details. |
|||
# |
|||
# You should have received a copy of the GNU Affero General Public License |
|||
# along with this program. If not, see <https://www.gnu.org/licenses/>. |
|||
# |
|||
|
|||
# Install composer packages |
|||
#composer install --no-scripts --no-ansi |
|||
|
|||
SCRIPT_DIR="$( cd -- "$( dirname -- "${BASH_SOURCE[0]}" )" &> /dev/null && pwd )" |
|||
|
|||
echo $1 |
|||
|
|||
if [ "$1" == "--dry-run" ]; then |
|||
echo "Running rector in dry run." |
|||
$SCRIPT_DIR/../vendor/bin/rector --config $SCRIPT_DIR/rector.php --dry-run |
|||
exit $? |
|||
fi |
|||
|
|||
$SCRIPT_DIR/../vendor/bin/rector --config $SCRIPT_DIR/rector.php |
Some files were not shown because too many files changed in this diff
Write
Preview
Loading…
Cancel
Save
Reference in new issue