Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
49 changes: 49 additions & 0 deletions .github/workflows/copilot-setup-steps.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
name: Setup Development Environment for GitHub Copilot


# Automatically run the setup steps when they are changed to allow for easy validation, and
# allow manual testing through the repository's "Actions" tab
on:
workflow_dispatch:
push:
paths:
- .github/workflows/copilot-setup-steps.yml
pull_request:
paths:
- .github/workflows/copilot-setup-steps.yml

jobs:
# The job MUST be called `copilot-setup-steps` or it will not be picked up by Copilot.
copilot-setup-steps:
runs-on: ubuntu-latest

# Only let github read the repository contents
permissions:
contents: read

steps:
- name: Checkout repository
uses: actions/checkout@v5
with:
fetch-depth: 30 # Fetch past 30 commits, so reasonable amount of commit context is included

- name: Setup Ruby
uses: ruby/setup-ruby@v1
with:
bundler-cache: true

- name: Run bin/setup
run: bin/setup --skip-server

- name: Validate setup
run: |
echo "Testing database connectivity..."
bundle exec rails runner \
"puts 'Database connection: OK'; \
puts 'User count: ' + User.count.to_s"

echo "Running code style validation..."
bundle exec standardrb

echo "Running test suite..."
bundle exec rake test
6 changes: 5 additions & 1 deletion db/seeds.rb
Original file line number Diff line number Diff line change
Expand Up @@ -451,4 +451,8 @@
Rake::Task["backfill:speaker_participation"].invoke
Rake::Task["backfill:event_involvements"].invoke
Rake::Task["speakerdeck:set_usernames_from_slides_url"].invoke
Rake::Task["contributors:fetch"].invoke
begin
Rake::Task["contributors:fetch"].invoke
rescue ApplicationClient::Unauthorized => e
puts "Skipping fetching contributors: #{e.message}"
end
6 changes: 3 additions & 3 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -815,9 +815,9 @@ camelcase-css@^2.0.1:
integrity sha512-QOSvevhslijgYwRx6Rv7zKdMF8lbRmx+uQGx2+vDc+KI/eBnsy9kit5aj23AgGu3pa4t9AgwbnXWqS+iOY+2aA==

caniuse-lite@^1.0.30001688, caniuse-lite@^1.0.30001702:
version "1.0.30001707"
resolved "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001707.tgz"
integrity sha512-3qtRjw/HQSMlDWf+X79N206fepf4SOOU6SQLMaq/0KkZLmSjPxAkBOQQ+FxbHKfHmYLZFfdWsO3KA90ceHPSnw==
version "1.0.30001759"
resolved "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001759.tgz"
integrity sha512-Pzfx9fOKoKvevQf8oCXoyNRQ5QyxJj+3O0Rqx2V5oxT61KGx8+n6hV/IUyJeifUci2clnmmKVpvtiqRzgiWjSw==

chalk@^4.0.0:
version "4.1.2"
Expand Down