Skip to content

chore(ci): Migrate from Travis to GH actions#367

Draft
dividedmind wants to merge 3 commits intomasterfrom
chore/gh-actions
Draft

chore(ci): Migrate from Travis to GH actions#367
dividedmind wants to merge 3 commits intomasterfrom
chore/gh-actions

Conversation

@dividedmind
Copy link
Contributor

Travis hasn't worked for a while. This pull request migrates CI to GitHub actions.

For release it uses releasebot app to obtain GH token for release and commit, and uses trusted publishing for rubygems.

Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Migrates the project’s CI pipeline from Travis CI to GitHub Actions, updating release/token handling and documentation accordingly.

Changes:

  • Remove legacy Travis CI configuration.
  • Add GitHub Actions workflow to run the Ruby test matrix and perform releases on master.
  • Update release wrapper and CI documentation to use GitHub Actions environment variables and releasebot + RubyGems trusted publishing.

Reviewed changes

Copilot reviewed 5 out of 5 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
release.sh Switches repo detection from TRAVIS_REPO_SLUG to GITHUB_REPOSITORY for semantic-release.
README_CI.md Documents new release credentials flow (GitHub App token + RubyGems OIDC) and updates env var name.
README.md Replaces Travis build badge with GitHub Actions badge.
.travis.yml Removes Travis CI configuration.
.github/workflows/ci.yml Introduces GitHub Actions workflow for tests + release job.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.


env:
PGPORT: 5432
PGUSER: travis
Copy link

Copilot AI Mar 21, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The Rails fixture apps' config/database.yml doesn't specify a host, so libpq will default to a local Unix socket when DATABASE_URL is unset. In GitHub Actions the Postgres service runs in a container, so connections must go over TCP; please set PGHOST=localhost (or set DATABASE_URL to include localhost and the mapped port) so tests can actually reach the service container.

Suggested change
PGUSER: travis
PGUSER: travis
PGHOST: localhost

Copilot uses AI. Check for mistakes.
Comment on lines +5 to 9
if [ ! -z "$GITHUB_REPOSITORY" ]; then
RELEASE_FLAGS="-r git+https://github.com/${GITHUB_REPOSITORY}.git"
fi

if [ ! -z "$GEM_ALTERNATIVE_NAME" ]; then
Copy link

Copilot AI Mar 21, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Consider using a more robust/idiomatic env var check here, e.g. -n "${GITHUB_REPOSITORY:-}", to avoid edge cases with unset variables and to satisfy common shell linters (ShellCheck warns about ! -z).

Suggested change
if [ ! -z "$GITHUB_REPOSITORY" ]; then
RELEASE_FLAGS="-r git+https://github.com/${GITHUB_REPOSITORY}.git"
fi
if [ ! -z "$GEM_ALTERNATIVE_NAME" ]; then
if [ -n "${GITHUB_REPOSITORY:-}" ]; then
RELEASE_FLAGS="-r git+https://github.com/${GITHUB_REPOSITORY}.git"
fi
if [ -n "${GEM_ALTERNATIVE_NAME:-}" ]; then

Copilot uses AI. Check for mistakes.
variable if its defined (otherwise git url is taken from `package.json`,
Bash wrapper script is used merely as a launcher of `semantic-release`
with extra logic to explicitly determine git url from `GITHUB_REPOSITORY` \
variable if its defined (otherwise git url is taken from `package.json`,
Copy link

Copilot AI Mar 21, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Grammar: its should be it's in "variable if its defined".

Suggested change
variable if its defined (otherwise git url is taken from `package.json`,
variable if it’s defined (otherwise git url is taken from `package.json`,

Copilot uses AI. Check for mistakes.
@dividedmind dividedmind marked this pull request as draft March 21, 2026 22:42
Newer concurrent-ruby causes error: uninitialized constant
ActiveSupport::LoggerThreadSafeLevel::Logger
- Add mutex_m as an explicit dependency;
- modify expected sequel to match what AR now generates.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants