Build Reactive Signals for Bluesky's AT Protocol Firehose in Laravel
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

Add GitHub Actions for automated testing and code style checks

+107
+27
.github/workflows/code-style.yml
··· 1 + name: Code Style 2 + 3 + on: 4 + push: 5 + branches: [ main, develop ] 6 + pull_request: 7 + branches: [ main, develop ] 8 + 9 + jobs: 10 + php-cs-fixer: 11 + runs-on: ubuntu-latest 12 + 13 + steps: 14 + - name: Checkout code 15 + uses: actions/checkout@v4 16 + 17 + - name: Setup PHP 18 + uses: shivammathur/setup-php@v2 19 + with: 20 + php-version: 8.3 21 + extensions: gmp, mbstring, json 22 + coverage: none 23 + tools: php-cs-fixer 24 + 25 + - name: Run PHP CS Fixer 26 + run: php-cs-fixer fix --dry-run --diff --verbose 27 + continue-on-error: true
+44
.github/workflows/tests.yml
··· 1 + name: Tests 2 + 3 + on: 4 + push: 5 + branches: [ main, develop ] 6 + pull_request: 7 + branches: [ main, develop ] 8 + 9 + jobs: 10 + test: 11 + runs-on: ubuntu-latest 12 + 13 + strategy: 14 + fail-fast: false 15 + matrix: 16 + php: [8.2, 8.3, 8.4] 17 + laravel: [11.*, 12.*] 18 + dependency-version: [prefer-stable] 19 + include: 20 + - laravel: 11.* 21 + testbench: 9.* 22 + - laravel: 12.* 23 + testbench: 10.* 24 + 25 + name: PHP ${{ matrix.php }} - Laravel ${{ matrix.laravel }} 26 + 27 + steps: 28 + - name: Checkout code 29 + uses: actions/checkout@v4 30 + 31 + - name: Setup PHP 32 + uses: shivammathur/setup-php@v2 33 + with: 34 + php-version: ${{ matrix.php }} 35 + extensions: gmp, mbstring, json 36 + coverage: none 37 + 38 + - name: Install dependencies 39 + run: | 40 + composer require "laravel/framework:${{ matrix.laravel }}" "orchestra/testbench:${{ matrix.testbench }}" --no-interaction --no-update 41 + composer update --${{ matrix.dependency-version }} --prefer-dist --no-interaction 42 + 43 + - name: Execute tests 44 + run: vendor/bin/phpunit
+1
.gitignore
··· 1 1 .phpunit.result.cache 2 + .php-cs-fixer.cache 2 3 composer.lock 3 4 /vendor
+35
.php-cs-fixer.php
··· 1 + <?php 2 + 3 + use PhpCsFixer\Config; 4 + use PhpCsFixer\Finder; 5 + 6 + $finder = Finder::create() 7 + ->in(__DIR__ . '/src') 8 + ->in(__DIR__ . '/tests') 9 + ->name('*.php') 10 + ->notName('*.blade.php') 11 + ->ignoreDotFiles(true) 12 + ->ignoreVCS(true); 13 + 14 + return (new Config()) 15 + ->setRules([ 16 + '@PSR12' => true, 17 + 'array_syntax' => ['syntax' => 'short'], 18 + 'ordered_imports' => ['sort_algorithm' => 'alpha'], 19 + 'no_unused_imports' => true, 20 + 'not_operator_with_successor_space' => true, 21 + 'trailing_comma_in_multiline' => true, 22 + 'phpdoc_scalar' => true, 23 + 'unary_operator_spaces' => true, 24 + 'binary_operator_spaces' => true, 25 + 'blank_line_before_statement' => [ 26 + 'statements' => ['break', 'continue', 'declare', 'return', 'throw', 'try'], 27 + ], 28 + 'phpdoc_single_line_var_spacing' => true, 29 + 'phpdoc_var_without_name' => true, 30 + 'method_argument_space' => [ 31 + 'on_multiline' => 'ensure_fully_multiline', 32 + 'keep_multiple_spaces_after_comma' => true, 33 + ], 34 + ]) 35 + ->setFinder($finder);