File tree Expand file tree Collapse file tree 4 files changed +65
-67
lines changed Expand file tree Collapse file tree 4 files changed +65
-67
lines changed Original file line number Diff line number Diff line change 1+ .gitattributes export-ignore
2+ .gitignore export-ignore
3+ .github export-ignore
4+ phpstan.neon export-ignore
Original file line number Diff line number Diff line change 1+ name : Code analysis
2+
3+ on :
4+ push :
5+ pull_request :
6+
7+ # Cancels all previous workflow runs for the same branch that have not yet completed.
8+ concurrency :
9+ # The concurrency group contains the workflow name and the branch name.
10+ group : ${{ github.workflow }}-${{ github.ref }}
11+ cancel-in-progress : true
12+
13+ jobs :
14+ static-analysis :
15+ strategy :
16+ fail-fast : false
17+ matrix :
18+ php :
19+ - " 7.2"
20+ - " 7.3"
21+ - " 7.4"
22+ - " 8.0"
23+ - " 8.1"
24+ - " 8.2"
25+ - " 8.3"
26+ name : PHPStan at PHP ${{ matrix.php }}
27+ runs-on : ubuntu-latest
28+
29+ steps :
30+ - name : Checkout repository
31+ uses : actions/checkout@v3
32+
33+ - name : Install PHP
34+ uses : shivammathur/setup-php@v2
35+ with :
36+ php-version : ${{ matrix.php }}
37+ coverage : none
38+
39+ - name : Get Composer cache directory
40+ id : composer-cache
41+ run : echo "dir=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT
42+
43+ - name : Cache dependencies
44+ uses : actions/cache@v3
45+ with :
46+ path : ${{ steps.composer-cache.outputs.dir }}
47+ key : ${{ runner.os }}-composer-${{ hashFiles('composer.json') }}
48+ restore-keys : ${{ runner.os }}-composer-
49+
50+ - name : Install Composer dependencies
51+ run : composer update --no-progress
52+
53+ - name : Statically analyze code (PHPStan)
54+ run : composer run phpstan -- --ansi
Load Diff This file was deleted.
Original file line number Diff line number Diff line change 11{
22 "name" : " jakubboucek/esc-pos" ,
33 "description" : " Native ESC-POS drivers" ,
4- "type" : " library" ,
54 "license" : " MIT" ,
5+ "type" : " library" ,
66 "authors" : [
77 {
88 "name" : " Jakub Bouček" ,
1111 ],
1212 "require" : {
1313 "php" : " >=7.2" ,
14- "composer-runtime-api" : " ^2.0" ,
15- "ext-sockets" : " *" ,
16- "ext-iconv" : " *"
14+ "ext-iconv" : " *" ,
15+ "ext-sockets" : " *"
1716 },
1817 "require-dev" : {
19- "phpstan/phpstan" : " ^0.12.89 "
18+ "phpstan/phpstan" : " ^1.10 "
2019 },
2120 "autoload" : {
2221 "psr-4" : {
2322 "JakubBoucek\\ EscPos\\ " : " src/"
2423 }
2524 },
25+ "config" : {
26+ "sort-packages" : true
27+ },
2628 "scripts" : {
2729 "phpstan" : " phpstan analyze src -c phpstan.neon --level 6"
2830 }
You can’t perform that action at this time.
0 commit comments