Skip to content

Commit

Permalink
resolve conflicts
Browse files Browse the repository at this point in the history
  • Loading branch information
cycomachead committed Jun 18, 2024
2 parents ffc3489 + 82377bb commit 8193e26
Show file tree
Hide file tree
Showing 10 changed files with 124 additions and 41 deletions.
4 changes: 4 additions & 0 deletions .github/CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,10 @@ TODO write docs for staff here

TODO Info here about workflows and links

Most of the linters in `.github/workflows/linters.yml` are powered by [reviewdog](https://github.com/reviewdog/reviewdog).

Run `bundle exec rubocop` to run [Rubocop](https://rubocop.org/). To autocorrect certain errors, run `bundle exec rubocop --autocorrect`.

## Testing

To run tests, run `bundle exec rspec`
Expand Down
14 changes: 0 additions & 14 deletions .github/workflows/axe-linter.yml

This file was deleted.

Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
name: reviewdog
name: Linters
on: [pull_request]
permissions:
contents: read
pull-requests: write
jobs:
pylint:
name: runner / pylint
Expand All @@ -15,6 +18,8 @@ jobs:
# GitHub Status Check won't become failure with warning.
level: warning
glob_pattern: "**/*.py"
filter_mode: nofilter
fail_on_error: true

black:
name: runner / black
Expand All @@ -26,11 +31,13 @@ jobs:
id: action_black
with:
black_args: "."
fail_on_error: true
- name: Annotate diff changes using reviewdog
if: steps.action_black.outputs.is_formatted == 'true'
uses: reviewdog/action-suggester@v1
with:
tool_name: blackfmt
# NOTE: the reviewdog filter_mode is diff_context - this is the only thing supported by GitHub suggestions

markdownlint:
name: runner / markdownlint
Expand All @@ -42,3 +49,24 @@ jobs:
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
reporter: github-pr-check
filter_mode: nofilter
fail_on_error: true

rubocop:
name: runner / rubocop
runs-on: ubuntu-latest
env:
BUNDLE_ONLY: rubocop
steps:
- uses: actions/checkout@v4
- uses: ruby/setup-ruby@v1
with:
ruby-version: '3.3'
bundler-cache: true
- uses: reviewdog/action-rubocop@v2
with:
reporter: github-pr-check
skip_install: true
use_bundler: true
filter_mode: nofilter
fail_on_error: true
4 changes: 2 additions & 2 deletions .github/workflows/rspec.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name: Run rspec tests
name: Run all page tests

on: [pull_request]
on: [pull_request, push]

jobs:
build:
Expand Down
2 changes: 2 additions & 0 deletions .rubocop.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
AllCops:
NewCops: enable
18 changes: 12 additions & 6 deletions Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,18 @@ source 'https://rubygems.org'
gem 'github-pages', group: :jekyll_plugins
gem 'jekyll-sitemap'
gem 'webrick'
gem 'just-the-docs'

Check warning on line 5 in Gemfile

View workflow job for this annotation

GitHub Actions / runner / rubocop

[rubocop] reported by reviewdog 🐶 Gems should be sorted in an alphabetical order within their section of the Gemfile. Gem `just-the-docs` should appear before `webrick`. Raw Output: Gemfile:5:1: C: Bundler/OrderedGems: Gems should be sorted in an alphabetical order within their section of the Gemfile. Gem `just-the-docs` should appear before `webrick`.

group :development, :test do
gem "rspec"
gem "selenium-webdriver"
gem "capybara"
gem "rack-jekyll"
gem "axe-core-rspec"
gem "axe-core-capybara"
gem 'axe-core-capybara'
gem 'axe-core-rspec'
gem 'capybara'
gem 'rack-jekyll'
gem 'rspec'
gem 'selenium-webdriver'
end

group :development, :rubocop do
gem 'rubocop', require: false
gem 'rubocop-rspec', require: false
end
31 changes: 31 additions & 0 deletions Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ GEM
tzinfo (~> 2.0)
addressable (2.8.5)
public_suffix (>= 2.0.2, < 6.0)
ast (2.4.2)
axe-core-api (4.8.0)
dumb_delegator
virtus
Expand Down Expand Up @@ -237,6 +238,12 @@ GEM
gemoji (>= 3, < 5)
html-pipeline (~> 2.2)
jekyll (>= 3.0, < 5.0)
json (2.7.2)
just-the-docs (0.8.2)
jekyll (>= 3.8.5)
jekyll-include-cache
jekyll-seo-tag (>= 2.0)
rake (>= 12.3.1)
kramdown (2.4.0)
rexml
kramdown-parser-gfm (1.1.0)
Expand Down Expand Up @@ -265,6 +272,10 @@ GEM
octokit (4.25.1)
faraday (>= 1, < 3)
sawyer (~> 0.9)
parallel (1.25.1)
parser (3.3.3.0)
ast (~> 2.4.1)
racc
pathutil (0.16.2)
forwardable-extended (~> 2.6)
public_suffix (4.0.7)
Expand All @@ -275,6 +286,8 @@ GEM
rack
rack-test (2.1.0)
rack (>= 1.3)
rainbow (3.1.1)
rake (13.2.1)
rb-fsevent (0.11.2)
rb-inotify (0.11.1)
ffi (~> 1.0)
Expand All @@ -294,6 +307,21 @@ GEM
diff-lcs (>= 1.2.0, < 2.0)
rspec-support (~> 3.12.0)
rspec-support (3.12.1)
rubocop (1.42.0)
json (~> 2.3)
parallel (~> 1.10)
parser (>= 3.1.2.1)
rainbow (>= 2.2.2, < 4.0)
regexp_parser (>= 1.8, < 3.0)
rexml (>= 3.2.5, < 4.0)
rubocop-ast (>= 1.24.1, < 2.0)
ruby-progressbar (~> 1.7)
unicode-display_width (>= 1.4.0, < 3.0)
rubocop-ast (1.31.3)
parser (>= 3.3.1.0)
rubocop-rspec (3.0.0)
rubocop (~> 1.40)
ruby-progressbar (1.13.0)
rubyzip (2.3.2)
safe_yaml (1.0.5)
sass (3.7.4)
Expand Down Expand Up @@ -338,8 +366,11 @@ DEPENDENCIES
capybara
github-pages
jekyll-sitemap
just-the-docs
rack-jekyll
rspec
rubocop
rubocop-rspec
selenium-webdriver
webrick

Expand Down
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,8 @@ To run the site locally, run:
bundle exec jekyll serve
```

Search throughout the repository for TODO items called `TODO(setup)` and complete them to customize the site for your course.

## Deployment

The easiest way to deploy your site is with [GitHub Pages](https://docs.github.com/en/pages/setting-up-a-github-pages-site-with-jekyll/about-github-pages-and-jekyll).
Expand Down
49 changes: 31 additions & 18 deletions _config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,30 +13,36 @@
# you will see them accessed via {{ site.title }}, {{ site.github_repo }}, and so on.
# You can create any custom variable you would like, and they will be accessible
# in the templates via {{ site.myvariable }}.
title: Just the Class

title: Berkeley Class Site
tagline: A Jekyll template for course websites
description: A modern, highly customizable, responsive Jekyll template for course websites
author: Kevin Lin
# TODO (template): this should be built from the staff list...
author: Various Bears

# TODO: This should be the semester, ideally. (faXX / spXX / suXX / wiXX )
# TODO(setup): Set this to the semester, e.g. /sp24, (faXX / spXX / suXX / wiXX )
baseurl: '/berkeley-class-site' # the subpath of your site, e.g. /blog
url: 'https://phrdang.github.io' # the base hostname & protocol for your site, e.g. http://example.com
# TODO(setup): Set this to your course's domain
url: 'https://berkeley-eecs.github.io' # the base hostname & protocol for your site, e.g. http://example.com

# Common Jekyll Plugins, which should also be in the Gemfile
plugins:
- jekyll-sitemap

# Theme settings
# TODO: (Su24): Ensure this is updated to most recent (v0.8+)
remote_theme: just-the-docs/[email protected]
color_scheme: light
search_enabled: true
# Course variables
# TODO(setup): Set all of these course variables
course_email: [email protected]
gradescope_course_id: 123456 # you can find this in the Gradescope URL after /courses

# TODO(setup): Set these auxiliary links as oyu wish - they show up on the top right
aux_links:
Kevin Lin:
- 'https://kevinl.info'
Just the Class on GitHub:
- 'https://github.com/kevinlin1/just-the-class'
footer_content:
Ed:
- 'https://edstem.org'
OH Queue:
- 'https://oh.c88c.org'
Berkeley Class Site on GitHub:
- 'https://github.com/berkeley-eecs/berkeley-class-site'
# TODO(setup): Set copyright/licensing or any other footer content
footer_content: "Copyright &copy; 2024 UC Berkeley"

# Collections for website data
collections:
Expand Down Expand Up @@ -107,6 +113,10 @@ gradescope_course_id: 693229
#######
# Just the Docs / Berkeley Class Site Common Config
# Options below here will likely not need to be configured..
# Theme settings
theme: just-the-docs
color_scheme: light
search_enabled: true
heading_anchors: true
permalink: pretty

Expand All @@ -118,11 +128,14 @@ compress_html:
blanklines: false
profile: false

# Files excluded from the Jekyll build
exclude:
- .*
- Gemfile
- Gemfile.lock
- vendor/
- node_modules/
- vendor
- README.md
- CONTRIBUTING.md
- .*
- tmp/
- spec/
- docs/
11 changes: 11 additions & 0 deletions resources.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
---
layout: page
title: Resources
description: >-
Course resources
nav_order: 5
---

# Resources

Add links to course resources here

0 comments on commit 8193e26

Please sign in to comment.