File tree Expand file tree Collapse file tree 4 files changed +32
-0
lines changed Expand file tree Collapse file tree 4 files changed +32
-0
lines changed Original file line number Diff line number Diff line change 6060 composer update --no-progress --no-interaction --prefer-dist --optimize-autoloader
6161 fi
6262
63+ - name : Rector Cache
64+ uses : actions/cache@v4
65+ with :
66+ path : /tmp/rector
67+ key : ${{ runner.os }}-rector-${{ github.run_id }}
68+ restore-keys : ${{ runner.os }}-rector-
69+
70+ - run : mkdir -p /tmp/rector
71+
6372 - name : Analyze for refactoring
6473 run : vendor/bin/rector process --dry-run --no-progress-bar
Original file line number Diff line number Diff line change 22
33declare (strict_types=1 );
44
5+ use Rector \Caching \ValueObject \Storage \FileCacheStorage ;
56use Rector \CodeQuality \Rector \BooleanAnd \SimplifyEmptyArrayCheckRector ;
67use Rector \CodeQuality \Rector \Class_ \CompleteDynamicPropertiesRector ;
78use Rector \CodeQuality \Rector \Empty_ \SimplifyEmptyCheckOnEmptyArrayRector ;
5051
5152 $ rectorConfig ->parallel ();
5253
54+ // Github action cache
55+ $ rectorConfig ->cacheClass (FileCacheStorage::class);
56+ if (is_dir ('/tmp ' )) {
57+ $ rectorConfig ->cacheDirectory ('/tmp/rector ' );
58+ }
59+
5360 // The paths to refactor (can also be supplied with CLI arguments)
5461 $ rectorConfig ->paths ([
5562 __DIR__ . '/src/ ' ,
Original file line number Diff line number Diff line change 6060 composer update --no-progress --no-interaction --prefer-dist --optimize-autoloader
6161 fi
6262
63+ - name : Rector Cache
64+ uses : actions/cache@v4
65+ with :
66+ path : /tmp/rector
67+ key : ${{ runner.os }}-rector-${{ github.run_id }}
68+ restore-keys : ${{ runner.os }}-rector-
69+
70+ - run : mkdir -p /tmp/rector
71+
6372 - name : Analyze for refactoring
6473 run : vendor/bin/rector process --dry-run --no-progress-bar
Original file line number Diff line number Diff line change 22
33declare (strict_types=1 );
44
5+ use Rector \Caching \ValueObject \Storage \FileCacheStorage ;
56use Rector \CodeQuality \Rector \BooleanAnd \SimplifyEmptyArrayCheckRector ;
67use Rector \CodeQuality \Rector \Class_ \CompleteDynamicPropertiesRector ;
78use Rector \CodeQuality \Rector \Empty_ \SimplifyEmptyCheckOnEmptyArrayRector ;
5051
5152 $ rectorConfig ->parallel ();
5253
54+ // Github action cache
55+ $ rectorConfig ->cacheClass (FileCacheStorage::class);
56+ if (is_dir ('/tmp ' )) {
57+ $ rectorConfig ->cacheDirectory ('/tmp/rector ' );
58+ }
59+
5360 // The paths to refactor (can also be supplied with CLI arguments)
5461 $ rectorConfig ->paths ([
5562 __DIR__ . '/app/ ' ,
You can’t perform that action at this time.
0 commit comments