Skip to content

Commit

Permalink
Merge pull request #2416 from openwebwork/WeBWorK-2.19
Browse files Browse the repository at this point in the history
WeBWorK 2.19 Release Candidate
  • Loading branch information
drgrice1 authored Aug 6, 2024
2 parents 2ff9800 + 73f2cae commit 9efc45d
Show file tree
Hide file tree
Showing 710 changed files with 106,610 additions and 65,746 deletions.
17 changes: 17 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
root = true

[*]
charset = utf-8
end_of_line = lf
insert_final_newline = true
max_line_length = 120
trim_trailing_whitespace = true
indent_style = tab
indent_size = 4

[*.yml]
indent_style = space
indent_size = 2

[*.pg]
trim_trailing_whitespace = false
44 changes: 44 additions & 0 deletions .github/workflows/check-formats.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
---
name: Check Formatting of Code Base

defaults:
run:
shell: bash

on:
push:
branches-ignore: [main, develop]
pull_request:

jobs:
perltidy:
name: Check Perl file formatting with perltidy
runs-on: ubuntu-22.04
container:
image: perl:5.34
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Install dependencies
run: cpanm -n Perl::Tidy@20220613
- name: Run perltidy
shell: bash
run: |
git config --global --add safe.directory "$GITHUB_WORKSPACE"
shopt -s extglob globstar nullglob
perltidy --pro=./.perltidyrc -b -bext='/' ./**/*.p[lm] ./**/*.t && git diff --exit-code
prettier:
name: Check JavaScript, style, and HTML file formatting with prettier
runs-on: ubuntu-22.04
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Install Node
uses: actions/setup-node@v4
with:
node-version: '20'
- name: Install Dependencies
run: cd htdocs && npm ci --ignore-scripts
- name: Check formatting with prettier
run: cd htdocs && npm run prettier-check
32 changes: 0 additions & 32 deletions .github/workflows/linter.yml

This file was deleted.

8 changes: 8 additions & 0 deletions .prettierrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
{
"arrowParens": "always",
"bracketSpacing": true,
"printWidth": 120,
"semi": true,
"singleQuote": true,
"trailingComma": "none"
}
25 changes: 15 additions & 10 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ RUN echo Cloning branch $PG_BRANCH branch from $PG_GIT_URL \

# We need to change FROM before setting the ENV variables.

FROM ubuntu:22.04
FROM ubuntu:24.04

ENV WEBWORK_URL=/webwork2 \
WEBWORK_ROOT_URL=http://localhost::8080 \
Expand Down Expand Up @@ -71,6 +71,7 @@ RUN apt-get update \
imagemagick \
iputils-ping \
jq \
libarchive-extract-perl \
libarchive-zip-perl \
libarray-utils-perl \
libc6-dev \
Expand All @@ -94,9 +95,11 @@ RUN apt-get update \
libextutils-helpers-perl \
libextutils-installpaths-perl \
libextutils-xsbuilder-perl \
libfile-copy-recursive-perl \
libfile-find-rule-perl-perl \
libfile-sharedir-install-perl \
libfuture-asyncawait-perl \
libgd-barcode-perl \
libgd-perl \
libhtml-scrubber-perl \
libhtml-template-perl \
Expand All @@ -107,10 +110,9 @@ RUN apt-get update \
libjson-perl \
libjson-xs-perl \
liblocale-maketext-lexicon-perl \
libmail-sender-perl \
libmail-sender-perl \
libmariadb-dev \
libmath-random-secure-perl \
libmime-base32-perl \
libmime-tools-perl \
libminion-backend-sqlite-perl \
libminion-perl \
Expand All @@ -124,13 +126,12 @@ RUN apt-get update \
libnet-oauth-perl \
libossp-uuid-perl \
libpadwalker-perl \
libpandoc-wrapper-perl \
libpath-class-perl \
libpath-tiny-perl \
libpandoc-wrapper-perl \
libphp-serialization-perl \
libpod-wsdl-perl \
libsoap-lite-perl \
libsql-abstract-classic-perl \
libsql-abstract-perl \
libstring-shellquote-perl \
libsub-uplevel-perl \
Expand Down Expand Up @@ -176,15 +177,19 @@ RUN apt-get update \
texlive-xetex \
tzdata \
zip $ADDITIONAL_BASE_IMAGE_PACKAGES \
&& curl -fsSL https://deb.nodesource.com/setup_16.x | bash - \
&& curl -fsSL https://deb.nodesource.com/setup_20.x | bash - \
&& apt-get install -y --no-install-recommends --no-install-suggests nodejs \
&& apt-get clean \
&& rm -fr /var/lib/apt/lists/* /tmp/*

# ==================================================================
# Phase 4 - Install additional Perl modules from CPAN that are not packaged for Ubuntu or are outdated in Ubuntu.

RUN cpanm install Statistics::R::IO DBD::MariaDB Mojo::[email protected] Perl::Tidy@20220613 \
RUN cpanm install -n \
Statistics::R::IO \
DBD::MariaDB \
Perl::Tidy@20220613 \
Archive::Zip::SimpleZip \
&& rm -fr ./cpanm /root/.cpanm /tmp/*

# ==================================================================
Expand All @@ -211,7 +216,7 @@ COPY --from=base /opt/base/pg $APP_ROOT/pg
# 7. Apply patches

# Patch files that are applied below
COPY docker-config/imagemagick-allow-pdf-read.patch /tmp
COPY docker-config/pgfsys-dvisvmg-bbox-fix.patch /tmp

RUN echo "PATH=$PATH:$APP_ROOT/webwork2/bin" >> /root/.bashrc \
&& mkdir /run/webwork2 /etc/ssl/local \
Expand All @@ -228,8 +233,8 @@ RUN echo "PATH=$PATH:$APP_ROOT/webwork2/bin" >> /root/.bashrc \
&& npm install \
&& cd $PG_ROOT/htdocs \
&& npm install \
&& patch -p1 -d / < /tmp/imagemagick-allow-pdf-read.patch \
&& rm /tmp/imagemagick-allow-pdf-read.patch
&& patch -p1 -d / < /tmp/pgfsys-dvisvmg-bbox-fix.patch \
&& rm /tmp/pgfsys-dvisvmg-bbox-fix.patch

# ==================================================================
# Phase 7 - Final setup and prepare docker-entrypoint.sh
Expand Down
17 changes: 11 additions & 6 deletions DockerfileStage1
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# This is the Stage 1 Dockerfile, which builds a base OS image (webwork-base)
# on top of which the WeBWorK parts will be installed by the Stage 2 Dockerfile.

FROM ubuntu:22.04
FROM ubuntu:24.04

# ==================================================================
# Phase 1 - Set base OS image install stage ENV variables
Expand Down Expand Up @@ -33,6 +33,7 @@ RUN apt-get update \
imagemagick \
iputils-ping \
jq \
libarchive-extract-perl \
libarchive-zip-perl \
libarray-utils-perl \
libc6-dev \
Expand All @@ -56,9 +57,11 @@ RUN apt-get update \
libextutils-helpers-perl \
libextutils-installpaths-perl \
libextutils-xsbuilder-perl \
libfile-copy-recursive-perl \
libfile-find-rule-perl-perl \
libfile-sharedir-install-perl \
libfuture-asyncawait-perl \
libgd-barcode-perl \
libgd-perl \
libhtml-scrubber-perl \
libhtml-template-perl \
Expand All @@ -69,10 +72,9 @@ RUN apt-get update \
libjson-perl \
libjson-xs-perl \
liblocale-maketext-lexicon-perl \
libmail-sender-perl \
libmail-sender-perl \
libmariadb-dev \
libmath-random-secure-perl \
libmime-base32-perl \
libmime-tools-perl \
libminion-backend-sqlite-perl \
libminion-perl \
Expand All @@ -92,7 +94,6 @@ RUN apt-get update \
libphp-serialization-perl \
libpod-wsdl-perl \
libsoap-lite-perl \
libsql-abstract-classic-perl \
libsql-abstract-perl \
libstring-shellquote-perl \
libsub-uplevel-perl \
Expand Down Expand Up @@ -138,15 +139,19 @@ RUN apt-get update \
texlive-xetex \
tzdata \
zip $ADDITIONAL_BASE_IMAGE_PACKAGES \
&& curl -fsSL https://deb.nodesource.com/setup_16.x | bash - \
&& curl -fsSL https://deb.nodesource.com/setup_20.x | bash - \
&& apt-get install -y --no-install-recommends --no-install-suggests nodejs \
&& apt-get clean \
&& rm -fr /var/lib/apt/lists/* /tmp/*

# ==================================================================
# Phase 3 - Install additional Perl modules from CPAN that are not packaged for Ubuntu or are outdated in Ubuntu.

RUN cpanm install -n Statistics::R::IO DBD::MariaDB Mojo::[email protected] Perl::Tidy@20220613 \
RUN cpanm install -n \
Statistics::R::IO \
DBD::MariaDB \
Perl::Tidy@20220613 \
Archive::Zip::SimpleZip \
&& rm -fr ./cpanm /root/.cpanm /tmp/*

# ==================================================================
8 changes: 4 additions & 4 deletions DockerfileStage2
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ RUN echo Cloning branch $PG_BRANCH branch from $PG_GIT_URL \

# We need to change FROM before setting the ENV variables.

FROM webwork-base:forWW218
FROM webwork-base:forWW219

ENV WEBWORK_URL=/webwork2 \
WEBWORK_ROOT_URL=http://localhost::8080 \
Expand Down Expand Up @@ -74,7 +74,7 @@ COPY --from=base /opt/base/pg $APP_ROOT/pg
# 7. Apply patches

# Patch files that are applied below
COPY docker-config/imagemagick-allow-pdf-read.patch /tmp
COPY docker-config/pgfsys-dvisvmg-bbox-fix.patch /tmp

RUN echo "PATH=$PATH:$APP_ROOT/webwork2/bin" >> /root/.bashrc \
&& mkdir /run/webwork2 /etc/ssl/local \
Expand All @@ -91,8 +91,8 @@ RUN echo "PATH=$PATH:$APP_ROOT/webwork2/bin" >> /root/.bashrc \
&& npm install \
&& cd $PG_ROOT/htdocs \
&& npm install \
&& patch -p1 -d / < /tmp/imagemagick-allow-pdf-read.patch \
&& rm /tmp/imagemagick-allow-pdf-read.patch
&& patch -p1 -d / < /tmp/pgfsys-dvisvmg-bbox-fix.patch \
&& rm /tmp/pgfsys-dvisvmg-bbox-fix.patch

# ==================================================================
# Phase 5 - Final setup and prepare docker-entrypoint.sh
Expand Down
2 changes: 1 addition & 1 deletion LICENSE
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
Online Homework Delivery System
Version 2.*

Copyright 2000-2023, The WeBWorK Project
Copyright 2000-2024, The WeBWorK Project

All rights reserved.

Expand Down
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@
Version 2.*
Branch: github.com/openwebwork

https://webwork.maa.org/wiki/Release_notes_for_WeBWorK_2.18
Copyright 2000-2023, The WeBWorK Project
https://webwork.maa.org/wiki/Release_notes_for_WeBWorK_2.19
Copyright 2000-2024, The WeBWorK Project
https://openwebwork.org/
All rights reserved.

Expand Down
4 changes: 2 additions & 2 deletions VERSION
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
$WW_VERSION = '2.18';
$WW_COPYRIGHT_YEARS = '1996-2023';
$WW_VERSION = '2.19';
$WW_COPYRIGHT_YEARS = '1996-2024';

1;
Loading

0 comments on commit 9efc45d

Please sign in to comment.