Skip to content

Commit 0091b91

Browse files
committed
Add config file for CircleCI
Reason for Change ================= * Continuous integration is a good way to ensure the app is building properly and the test suite is green Changes ======= * Add a `.circleci/config.yml` file. Minor ===== * Fix remaining master > main corrections * Add a note about draft PRs
1 parent a75fc93 commit 0091b91

File tree

3 files changed

+59
-3
lines changed

3 files changed

+59
-3
lines changed

Diff for: .circleci/config.yml

+56
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,56 @@
1+
version: 2.1
2+
3+
orbs:
4+
ruby: circleci/[email protected]
5+
node: circleci/node@2
6+
7+
jobs:
8+
build:
9+
docker:
10+
- image: cimg/ruby:2.7.5
11+
steps:
12+
- checkout
13+
- ruby/install-deps
14+
- node/install-packages:
15+
pkg-manager: yarn
16+
cache-key: "yarn.lock"
17+
test:
18+
# parallelism: 3
19+
docker:
20+
- image: cimg/ruby:2.7.5
21+
- image: circleci/postgres:9.5-alpine
22+
environment:
23+
POSTGRES_USER: circleci-demo-ruby
24+
POSTGRES_DB: rails_blog_test
25+
POSTGRES_PASSWORD: ""
26+
environment:
27+
BUNDLE_JOBS: "3"
28+
BUNDLE_RETRY: "3"
29+
PGHOST: 127.0.0.1
30+
PGUSER: circleci-demo-ruby
31+
PGPASSWORD: ""
32+
RAILS_ENV: test
33+
steps:
34+
- checkout
35+
- ruby/install-deps
36+
- node/install-packages:
37+
pkg-manager: yarn
38+
cache-key: "yarn.lock"
39+
- run:
40+
name: Wait for DB
41+
command: dockerize -wait tcp://localhost:5432 -timeout 1m
42+
- run:
43+
name: Database setup
44+
command: bundle exec rails db:schema:load --trace
45+
# Run rspec in parallel
46+
- ruby/rspec-test
47+
- ruby/rubocop-check
48+
49+
workflows:
50+
version: 2
51+
build_and_test:
52+
jobs:
53+
- build
54+
- test:
55+
requires:
56+
- build

Diff for: CONTRIBUTING.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ Guidelines for bug reports:
3232
reported.
3333

3434
2. **Check if the issue has been fixed** — try to reproduce it using the
35-
latest `master` or development branch in the repository.
35+
latest `main` or development branch in the repository.
3636

3737
3. **Isolate the problem** — create a [reduced test
3838
case](http://css-tricks.com/6263-reduced-test-cases/) and a live example.
@@ -136,7 +136,7 @@ project:
136136
```
137137

138138
7. [Open a Pull Request](https://help.github.com/articles/using-pull-requests/)
139-
with a clear title and description.
139+
with a clear title and description. NOTE: please avoid opening Pull Requests for Work-in-Progress or draft code. Opening a PR sends many notifications to followers and we want to conserve their attention span.
140140

141141
**IMPORTANT**: By submitting a patch, you agree to allow the project owner to
142142
license your work under the same license as that used by the project.

Diff for: README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ The CFP App does not provide a public facing website for your conference, though
2323
* PostgreSQL 14.1
2424
* Google Chrome browser must be installed to run tests
2525

26-
Make sure you have Ruby and Postgres installed in your environment. Double check in the [Gemfile](../blob/master/Gemfile) for the exact supported version. This is a Rails 6 app and uses bundler to install all required gems. We are also making the assumption that you're familiar with how Rails apps are setup and deployed. If this is not the case then you'll want to refer to documentation that will bridge any gaps in the instructions below.
26+
Make sure you have Ruby and Postgres installed in your environment. Double check in the [Gemfile](../blob/main/Gemfile) for the exact supported version. This is a Rails 6 app and uses bundler to install all required gems. We are also making the assumption that you're familiar with how Rails apps are setup and deployed. If this is not the case then you'll want to refer to documentation that will bridge any gaps in the instructions below.
2727

2828
Run [bin/setup](bin/setup) script to install gem dependencies and setup database for development.
2929

0 commit comments

Comments
 (0)