Update workshop_default image and set bookmark default image (#308) #128
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Publish Coverage Badge | |
| on: | |
| push: | |
| branches: [ main ] | |
| permissions: | |
| contents: write # required for gh-pages branch writes | |
| jobs: | |
| publish-badge: | |
| runs-on: ubuntu-latest | |
| services: | |
| mysql: | |
| image: mysql:8.0 | |
| env: | |
| MYSQL_ROOT_PASSWORD: '' | |
| MYSQL_ALLOW_EMPTY_PASSWORD: 'yes' | |
| MYSQL_DATABASE: awbw_test | |
| ports: | |
| - 3306:3306 | |
| options: --health-cmd="mysqladmin ping" --health-interval=10s --health-timeout=5s --health-retries=3 | |
| steps: | |
| - uses: actions/checkout@v5 | |
| - uses: ruby/setup-ruby@v1 | |
| with: | |
| bundler-cache: true | |
| - uses: actions/setup-node@v6 | |
| with: | |
| node-version: 22 | |
| - run: npm ci | |
| - name: Setup database | |
| run: | | |
| bundle exec rake db:create db:schema:load | |
| env: | |
| RAILS_ENV: test | |
| # AWS credentials | |
| AWS_REGION: ${{ vars.AWS_REGION }} | |
| AWS_S3_BUCKET: ${{ vars.AWS_S3_BUCKET }} | |
| AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }} | |
| AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }} | |
| # SMTP settings | |
| SMTP_SERVER: ${{ secrets.SMTP_SERVER }} | |
| SMTP_PORT: ${{ secrets.SMTP_PORT }} | |
| SMTP_USERNAME: ${{ secrets.SMTP_USERNAME }} | |
| SMTP_PASSWORD: ${{ secrets.SMTP_PASSWORD }} | |
| - name: Run RSpec (SimpleCov JSON + summary via at_exit) | |
| env: | |
| RAILS_ENV: test | |
| CI: "true" | |
| run: bundle exec rspec | |
| - name: Generate coverage badge | |
| run: ruby bin/coverage_badge.rb coverage/summary.json coverage_badge.svg | |
| - name: Publish badge to gh-pages | |
| uses: peaceiris/actions-gh-pages@v4 | |
| with: | |
| github_token: ${{ secrets.GITHUB_TOKEN }} | |
| publish_branch: gh-pages | |
| publish_dir: . | |
| publish_files: coverage_badge.svg | |
| destination_dir: badges/main | |
| keep_files: true |