From 605af810e0097613bc3e9740f6f053ae74313774 Mon Sep 17 00:00:00 2001 From: Jack Greiner Date: Mon, 13 May 2024 22:21:34 -0400 Subject: [PATCH 1/5] Nuke gemfile.lock and pin ruby to 3.3 (Can be bumped later if needed. --- .ruby-version | 1 + Gemfile.lock | 200 -------------------------------------------------- 2 files changed, 1 insertion(+), 200 deletions(-) create mode 100644 .ruby-version delete mode 100644 Gemfile.lock diff --git a/.ruby-version b/.ruby-version new file mode 100644 index 0000000..eb39e53 --- /dev/null +++ b/.ruby-version @@ -0,0 +1 @@ +3.3 diff --git a/Gemfile.lock b/Gemfile.lock deleted file mode 100644 index 46b4ec8..0000000 --- a/Gemfile.lock +++ /dev/null @@ -1,200 +0,0 @@ -GEM - remote: https://rubygems.org/ - specs: - activesupport (7.1.3.2) - base64 - bigdecimal - concurrent-ruby (~> 1.0, >= 1.0.2) - connection_pool (>= 2.2.5) - drb - i18n (>= 1.6, < 2) - minitest (>= 5.1) - mutex_m - tzinfo (~> 2.0) - addressable (2.8.6) - public_suffix (>= 2.0.2, < 6.0) - adsf (1.5.0) - rack (>= 1.0.0, < 4.0.0) - rackup (~> 2.1) - base64 (0.2.0) - bigdecimal (3.1.7) - builder (3.2.4) - coderay (1.1.3) - colored (1.2) - concurrent-ruby (1.2.3) - connection_pool (2.4.1) - cri (2.15.11) - ddmetrics (1.1.0) - ddplugin (1.0.3) - diff-lcs (1.5.1) - drb (2.2.1) - execjs (2.9.1) - ffi (1.16.3) - i18n (1.14.4) - concurrent-ruby (~> 1.0) - image_size (3.4.0) - immutable-ruby (0.1.0) - concurrent-ruby (~> 1.1) - sorted_set (~> 1.0) - json (2.7.1) - json_schema (0.21.0) - kramdown (2.4.0) - rexml - libv8-node (18.16.0.0) - libv8-node (18.16.0.0-aarch64-linux) - libv8-node (18.16.0.0-aarch64-linux-musl) - libv8-node (18.16.0.0-arm64-darwin) - libv8-node (18.16.0.0-x86_64-darwin) - libv8-node (18.16.0.0-x86_64-linux) - libv8-node (18.16.0.0-x86_64-linux-musl) - memo_wise (1.8.0) - method_source (1.0.0) - mini_portile2 (2.8.5) - mini_racer (0.8.0) - libv8-node (~> 18.16.0.0) - minitest (5.22.3) - mutex_m (0.2.0) - nanoc (4.12.20) - addressable (~> 2.5) - colored (~> 1.2) - nanoc-checking (~> 1.0, >= 1.0.2) - nanoc-cli (= 4.12.20) - nanoc-core (= 4.12.20) - nanoc-deploying (~> 1.0) - parallel (~> 1.12) - tty-command (~> 0.8) - tty-which (~> 0.4) - nanoc-checking (1.0.3) - nanoc-cli (~> 4.12, >= 4.12.5) - nanoc-core (~> 4.12, >= 4.12.5) - nanoc-cli (4.12.20) - cri (~> 2.15) - diff-lcs (~> 1.3) - nanoc-core (= 4.12.20) - pry - zeitwerk (~> 2.1) - nanoc-core (4.12.20) - base64 (~> 0.2) - concurrent-ruby (~> 1.1) - ddmetrics (~> 1.0) - ddplugin (~> 1.0) - immutable-ruby (~> 0.1) - json_schema (~> 0.19) - memo_wise (~> 1.5) - psych (>= 4.0, < 6.0) - slow_enumerator_tools (~> 1.0) - tty-platform (~> 0.2) - zeitwerk (~> 2.1) - nanoc-deploying (1.0.2) - nanoc-checking (~> 1.0) - nanoc-cli (~> 4.11, >= 4.11.15) - nanoc-core (~> 4.11, >= 4.11.15) - nanoc-javascript-concatenator (0.0.2) - nanoc (>= 3.3.0) - nokogiri (1.16.3) - mini_portile2 (~> 2.8.2) - racc (~> 1.4) - nokogiri (1.16.3-aarch64-linux) - racc (~> 1.4) - nokogiri (1.16.3-arm-linux) - racc (~> 1.4) - nokogiri (1.16.3-arm64-darwin) - racc (~> 1.4) - nokogiri (1.16.3-x86-linux) - racc (~> 1.4) - nokogiri (1.16.3-x86_64-darwin) - racc (~> 1.4) - nokogiri (1.16.3-x86_64-linux) - racc (~> 1.4) - nokogiri-pretty (0.1.0) - nokogiri - oyster (0.9.5) - packr (3.2.1) - oyster (>= 0.9.5) - parallel (1.24.0) - pastel (0.8.0) - tty-color (~> 0.5) - pry (0.14.2) - coderay (~> 1.1) - method_source (~> 1.0) - psych (5.1.2) - stringio - public_suffix (5.0.4) - pygments.rb (2.4.1) - racc (1.7.3) - rack (3.0.10) - rackup (2.1.0) - rack (>= 3) - webrick (~> 1.8) - rainpress (1.0.1) - rb-fsevent (0.11.2) - rb-inotify (0.10.1) - ffi (~> 1.0) - rbtree (0.4.6) - rexml (3.2.6) - rubypants (0.7.1) - sass (3.7.4) - sass-listen (~> 4.0.0) - sass-listen (4.0.0) - rb-fsevent (~> 0.9, >= 0.9.4) - rb-inotify (~> 0.9, >= 0.9.7) - set (1.1.0) - slow_enumerator_tools (1.1.0) - sorted_set (1.0.3) - rbtree - set (~> 1.0) - stringio (3.1.0) - terser (1.2.0) - execjs (>= 0.3.0, < 3) - tty-color (0.6.0) - tty-command (0.10.1) - pastel (~> 0.8) - tty-platform (0.3.0) - tty-which (0.5.0) - typogruby (1.0.18) - rubypants - tzinfo (2.0.6) - concurrent-ruby (~> 1.0) - uglifier (4.2.0) - execjs (>= 0.3.0, < 3) - w3c_validators (1.3.7) - json (>= 1.8) - nokogiri (~> 1.6) - rexml (~> 3.2) - webrick (1.8.1) - zeitwerk (2.6.13) - -PLATFORMS - aarch64-linux - aarch64-linux-musl - arm-linux - arm64-darwin - ruby - x86-linux - x86_64-darwin - x86_64-linux - x86_64-linux-musl - -DEPENDENCIES - activesupport - adsf - builder - image_size - kramdown - mini_racer - nanoc (>= 4.0) - nanoc-javascript-concatenator - nokogiri - nokogiri-pretty - packr - pygments.rb - rainpress - sass - terser - typogruby - uglifier - w3c_validators - webrick - -BUNDLED WITH - 2.5.3 From eaf8080f9bb5458df29f473c4639ed6d9d45dc78 Mon Sep 17 00:00:00 2001 From: Jack Greiner Date: Mon, 13 May 2024 22:24:42 -0400 Subject: [PATCH 2/5] Update workflow to setup ruby. --- .github/workflows/website_check.yml | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/.github/workflows/website_check.yml b/.github/workflows/website_check.yml index e7e14c2..d78831e 100644 --- a/.github/workflows/website_check.yml +++ b/.github/workflows/website_check.yml @@ -16,17 +16,21 @@ jobs: - name: Checkout Naev Website Repository uses: actions/checkout@v3 + - name: Setup Ruby + uses: ruby/setup-ruby@v1 + with: + bundler-cache: true + - name: Build and Check Website run: | make check - name: Upload Crash Log uses: actions/upload-artifact@v3 - if: failure() with: name: naev-website-${{ github.sha }}-crashlog - path: ${{ github.workspace }}/crash.log - if-no-files-found: error + path: ${{ github.workspace }}/*.log + if-no-files-found: warn - name: Upload Website Artifacts uses: actions/upload-artifact@v3 From 35d81900ba11c9026d6843c92999fb16c90cf63d Mon Sep 17 00:00:00 2001 From: Jack Greiner Date: Mon, 13 May 2024 22:27:39 -0400 Subject: [PATCH 3/5] Try and force action to pretend that we are a normal image. --- .github/workflows/website_check.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/website_check.yml b/.github/workflows/website_check.yml index d78831e..2257507 100644 --- a/.github/workflows/website_check.yml +++ b/.github/workflows/website_check.yml @@ -19,6 +19,7 @@ jobs: - name: Setup Ruby uses: ruby/setup-ruby@v1 with: + self-hosted: false bundler-cache: true - name: Build and Check Website From 38e13d6403a8f0acbd9a78980ea041e96416db16 Mon Sep 17 00:00:00 2001 From: Jack Greiner Date: Mon, 13 May 2024 22:40:44 -0400 Subject: [PATCH 4/5] Fully use Github Actions image for building the website. --- .github/workflows/website_check.yml | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/.github/workflows/website_check.yml b/.github/workflows/website_check.yml index 2257507..5b2d989 100644 --- a/.github/workflows/website_check.yml +++ b/.github/workflows/website_check.yml @@ -9,17 +9,20 @@ jobs: permissions: contents: read runs-on: ubuntu-latest - container: - image: "ghcr.io/naev/naev-docs:latest" steps: - name: Checkout Naev Website Repository uses: actions/checkout@v3 + - name: Setup APT Packages + uses: awalsh128/cache-apt-pkgs-action@latest + with: + packages: graphicsmagick optipng tidy + version: website_1.0 + - name: Setup Ruby uses: ruby/setup-ruby@v1 with: - self-hosted: false bundler-cache: true - name: Build and Check Website From 66c9fdd011033cf485d288fe3e240a17d8e7bac7 Mon Sep 17 00:00:00 2001 From: Jack Greiner Date: Mon, 13 May 2024 23:09:30 -0400 Subject: [PATCH 5/5] Merge main into upcoming. --- .github/workflows/website_check.yml | 4 ++-- .gitignore | 1 + README.md | 6 +++++- 3 files changed, 8 insertions(+), 3 deletions(-) diff --git a/.github/workflows/website_check.yml b/.github/workflows/website_check.yml index 5b2d989..4954b5e 100644 --- a/.github/workflows/website_check.yml +++ b/.github/workflows/website_check.yml @@ -33,12 +33,12 @@ jobs: uses: actions/upload-artifact@v3 with: name: naev-website-${{ github.sha }}-crashlog - path: ${{ github.workspace }}/*.log + path: ./*.log if-no-files-found: warn - name: Upload Website Artifacts uses: actions/upload-artifact@v3 with: name: naev-website-${{ github.sha }} - path: ${{ github.workspace }}/output/* + path: ./output/* if-no-files-found: error diff --git a/.gitignore b/.gitignore index 9d4592c..e4a24e4 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,4 @@ +Gemfile.lock crash.log output/ tmp/ diff --git a/README.md b/README.md index b124e46..4a72446 100644 --- a/README.md +++ b/README.md @@ -46,4 +46,8 @@ The writing is down using [markdown](https://daringfireball.net/projects/markdow If you wish to use images you have to separately put them in `content/imgs/blarg/` and you can reference them in the post with the inline ruby code `<%= @items['/imgs/blarg/FILENAME'].path %>` where `FILENAME` is replaced by the name of the file. This expression will be converted to the file path when compiling. -For Blarg posts please try and follow the convention in [`content/content/imgs/blarg`](https://github.com/naev/naev-website/tree/main/content/imgs/blarg) to keep things organized. (`content/content/imgs/blarg/YYYY/MM`) +For Blarg posts please try and follow the convention in [`content/content/imgs/blarg`](./content/imgs/blarg) to keep things organized. (`content/content/imgs/blarg/YYYY/MM`) + +### Maintenance + +If you'd like to bump the version of ruby that the site is built with, change the version in [.ruby-version](./.ruby-version) to a supported version of ruby as mentioned on this [documentation page](https://github.com/ruby/setup-ruby?tab=readme-ov-file#supported-version-syntax).