diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 160db7c..d44ff59 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -27,6 +27,15 @@ jobs: with: php-version: ${{ matrix.version }} coverage: xdebug2 + - name: Get composer cache directory + id: composer-cache + run: echo "dir=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT + - name: Cache dependencies + uses: actions/cache@v3 + with: + path: ${{ steps.composer-cache.outputs.dir }} + key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.json') }} + restore-keys: ${{ runner.os }}-composer- - run: composer update --prefer-dist --no-interaction ${{ matrix.flags }} - run: bin/atoum @@ -44,5 +53,14 @@ jobs: with: php-version: ${{ matrix.version }} coverage: xdebug2 + - name: Get composer cache directory + id: composer-cache + run: echo "dir=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT + - name: Cache dependencies + uses: actions/cache@v3 + with: + path: ${{ steps.composer-cache.outputs.dir }} + key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.json') }} + restore-keys: ${{ runner.os }}-composer- - run: composer update --prefer-dist --no-interaction ${{ matrix.flags }} - run: bin/phpstan \ No newline at end of file