From 27f6496700a1f99c8a3c8e2e1898277fa72b4ef8 Mon Sep 17 00:00:00 2001 From: yart Date: Tue, 18 Jun 2024 10:32:28 +0300 Subject: [PATCH 01/14] fix(nokogiri): bundler version --- .github/workflows/build.yml | 3 ++- Dockerfile | 4 ++-- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 0e2c1c8..8ae4dc8 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -30,7 +30,8 @@ jobs: # necessary to get ruby 2.3 to work nicely with bundler vendor/bundle cache # can remove once ruby 2.3 is no longer supported - - run: gem update --system 3.4.22 + # - run: gem update --system 3.4.22 + - run: gem install bundler -v 2.4.22 - run: bundle config set deployment 'true' - run: bundle install diff --git a/Dockerfile b/Dockerfile index 33b80ca..5777f8e 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,4 +1,4 @@ -FROM ruby:2.6-slim +FROM ruby:2.7-slim WORKDIR /srv/slate @@ -11,7 +11,7 @@ RUN apt-get update \ && apt-get install -y --no-install-recommends \ build-essential \ nodejs \ - && gem install bundler \ + && gem install bundler -v 2.4.22\ && bundle install \ && apt-get remove -y build-essential \ && apt-get autoremove -y \ From 38b00c97143af0a1e2bfa74daf0fff6238483e61 Mon Sep 17 00:00:00 2001 From: yart Date: Tue, 18 Jun 2024 10:44:09 +0300 Subject: [PATCH 02/14] fix(nokigiri): added build-essential libs to ubuntu --- .github/workflows/build.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 8ae4dc8..5504663 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -31,6 +31,8 @@ jobs: # necessary to get ruby 2.3 to work nicely with bundler vendor/bundle cache # can remove once ruby 2.3 is no longer supported # - run: gem update --system 3.4.22 + - run: apt-get update + - run: apt-get install -y --no-install-recommends build-essential nodejs - run: gem install bundler -v 2.4.22 - run: bundle config set deployment 'true' From cacec1005ea445c1879a890d0bbfa5a26d58b254 Mon Sep 17 00:00:00 2001 From: yart Date: Tue, 18 Jun 2024 10:51:45 +0300 Subject: [PATCH 03/14] fix(nokogiri): excluded apt-get update --- .github/workflows/build.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 5504663..2e88ec0 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -31,7 +31,7 @@ jobs: # necessary to get ruby 2.3 to work nicely with bundler vendor/bundle cache # can remove once ruby 2.3 is no longer supported # - run: gem update --system 3.4.22 - - run: apt-get update + # - run: apt-get update - run: apt-get install -y --no-install-recommends build-essential nodejs - run: gem install bundler -v 2.4.22 From d6de09e922c46ee36ed6c3300042051ad7062fb8 Mon Sep 17 00:00:00 2001 From: yart Date: Tue, 18 Jun 2024 10:54:12 +0300 Subject: [PATCH 04/14] fix(nokogiri): sudo added to commands --- .github/workflows/build.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 2e88ec0..1110be9 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -31,8 +31,8 @@ jobs: # necessary to get ruby 2.3 to work nicely with bundler vendor/bundle cache # can remove once ruby 2.3 is no longer supported # - run: gem update --system 3.4.22 - # - run: apt-get update - - run: apt-get install -y --no-install-recommends build-essential nodejs + - run: sudo apt-get update + - run: sudo apt-get install -y --no-install-recommends build-essential nodejs - run: gem install bundler -v 2.4.22 - run: bundle config set deployment 'true' From 9f245dd6c2949b71267e60e989852dff125bb8b5 Mon Sep 17 00:00:00 2001 From: yart Date: Tue, 18 Jun 2024 11:07:39 +0300 Subject: [PATCH 05/14] fix(nokogiri): changed ubuntu to debian --- .github/workflows/build.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 1110be9..8e33dfe 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -10,7 +10,7 @@ on: jobs: test: - runs-on: ubuntu-latest + runs-on: debian-bookworm-slim strategy: matrix: From 7af2d61ad7bc1981a8d8539a998b70a1a3a28a89 Mon Sep 17 00:00:00 2001 From: yart Date: Tue, 18 Jun 2024 11:15:56 +0300 Subject: [PATCH 06/14] fix(nokogiri): changed from ubuntu-latest to ubuntu-20.04 --- .github/workflows/build.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 8e33dfe..6a6c8e0 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -10,7 +10,7 @@ on: jobs: test: - runs-on: debian-bookworm-slim + runs-on: ubuntu-20.04 strategy: matrix: From a98062b2c30c79c732e14f9525fd95cd3e716e46 Mon Sep 17 00:00:00 2001 From: yart Date: Tue, 18 Jun 2024 12:14:00 +0300 Subject: [PATCH 07/14] fix(nokogiri): try for --use-system-libraries --- .github/workflows/build.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 6a6c8e0..46a0a9c 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -36,6 +36,7 @@ jobs: - run: gem install bundler -v 2.4.22 - run: bundle config set deployment 'true' + - run: bundle config build.nokogiri --use-system-libraries - run: bundle install - run: bundle exec middleman build From ce0324df7cc222d6d0a4423154ae7bd40b422692 Mon Sep 17 00:00:00 2001 From: yart Date: Tue, 18 Jun 2024 12:21:27 +0300 Subject: [PATCH 08/14] fix(nokogiri): try for bundler-cache --- .github/workflows/build.yml | 51 ++++++++++++++++++++----------------- 1 file changed, 27 insertions(+), 24 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 46a0a9c..2a3d23b 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -10,33 +10,36 @@ on: jobs: test: - runs-on: ubuntu-20.04 + runs-on: ubuntu-latest - strategy: - matrix: - ruby-version: [2.7] + # strategy: + # matrix: + # ruby-version: [2.7] steps: - - uses: actions/checkout@v2 - - name: Set up Ruby - uses: ruby/setup-ruby@v1 + - uses: actions/checkout@v4 + # - name: Set up Ruby + - uses: ruby/setup-ruby@v1 with: - ruby-version: ${{ matrix.ruby-version }} - - - uses: actions/cache@v1 - with: - path: vendor/bundle - key: gems-${{ runner.os }}-${{ matrix.ruby-version }}-${{ hashFiles('**/Gemfile.lock') }} - - # necessary to get ruby 2.3 to work nicely with bundler vendor/bundle cache - # can remove once ruby 2.3 is no longer supported - # - run: gem update --system 3.4.22 - - run: sudo apt-get update - - run: sudo apt-get install -y --no-install-recommends build-essential nodejs - - run: gem install bundler -v 2.4.22 - - - run: bundle config set deployment 'true' - - run: bundle config build.nokogiri --use-system-libraries - - run: bundle install + ruby-version: '2.7' + bundler-cache: true + # with: + # ruby-version: ${{ matrix.ruby-version }} + # + # - uses: actions/cache@v1 + # with: + # path: vendor/bundle + # key: gems-${{ runner.os }}-${{ matrix.ruby-version }}-${{ hashFiles('**/Gemfile.lock') }} + # + # # necessary to get ruby 2.3 to work nicely with bundler vendor/bundle cache + # # can remove once ruby 2.3 is no longer supported + # # - run: gem update --system 3.4.22 + # - run: sudo apt-get update + # - run: sudo apt-get install -y --no-install-recommends build-essential nodejs + # - run: gem install bundler -v 2.4.22 + # + # - run: bundle config set deployment 'true' + # - run: bundle config build.nokogiri --use-system-libraries + # - run: bundle install - run: bundle exec middleman build From f0c803e942781cb3e6b0abf97edb22b010cdbdb2 Mon Sep 17 00:00:00 2001 From: yart Date: Tue, 18 Jun 2024 13:05:56 +0300 Subject: [PATCH 09/14] fix(nokogiri): try ruby 2.7.0 (was 2.7.8) --- .github/workflows/build.yml | 50 ++++++++++++++++--------------------- 1 file changed, 22 insertions(+), 28 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 2a3d23b..e0e8a1f 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -3,43 +3,37 @@ name: Build on: push: branches: [ '*' ] - paths-ignore: [ '**.md' ] + paths-ignore: [ 'README.md', '**.html.md', '**.md.erb' ] pull_request: branches: [ '*' ] - paths-ignore: [ '**.md' ] + paths-ignore: [ 'README.md', '**.html.md', '**.md.erb' ] jobs: test: runs-on: ubuntu-latest - # strategy: - # matrix: - # ruby-version: [2.7] + strategy: + matrix: + ruby-version: [ '2.7.0' ] steps: - - uses: actions/checkout@v4 - # - name: Set up Ruby - - uses: ruby/setup-ruby@v1 + - uses: actions/checkout@v2 + - name: Set up Ruby + uses: ruby/setup-ruby@v1 with: - ruby-version: '2.7' - bundler-cache: true - # with: - # ruby-version: ${{ matrix.ruby-version }} - # - # - uses: actions/cache@v1 - # with: - # path: vendor/bundle - # key: gems-${{ runner.os }}-${{ matrix.ruby-version }}-${{ hashFiles('**/Gemfile.lock') }} - # - # # necessary to get ruby 2.3 to work nicely with bundler vendor/bundle cache - # # can remove once ruby 2.3 is no longer supported - # # - run: gem update --system 3.4.22 - # - run: sudo apt-get update - # - run: sudo apt-get install -y --no-install-recommends build-essential nodejs - # - run: gem install bundler -v 2.4.22 - # - # - run: bundle config set deployment 'true' - # - run: bundle config build.nokogiri --use-system-libraries - # - run: bundle install + ruby-version: ${{ matrix.ruby-version }} + + - uses: actions/cache@v1 + with: + path: vendor/bundle + key: gems-${{ runner.os }}-${{ matrix.ruby-version }}-${{ hashFiles('**/Gemfile.lock') }} + + # - run: gem update --system 3.4.22 + - run: sudo apt-get install -y --no-install-recommends build-essential nodejs + - run: gem install bundler -v 2.4.22 + + - run: bundle config set deployment 'true' + - run: bundle config build.nokogiri --use-system-libraries + - run: bundle install - run: bundle exec middleman build From 24305c9ef9d10a7078b406080f92484f2db4aac7 Mon Sep 17 00:00:00 2001 From: yart Date: Tue, 18 Jun 2024 13:07:39 +0300 Subject: [PATCH 10/14] fix(nokogiri): w/o reinstall nodejs --- .github/workflows/build.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index e0e8a1f..9356061 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -29,7 +29,7 @@ jobs: key: gems-${{ runner.os }}-${{ matrix.ruby-version }}-${{ hashFiles('**/Gemfile.lock') }} # - run: gem update --system 3.4.22 - - run: sudo apt-get install -y --no-install-recommends build-essential nodejs + - run: sudo apt-get install -y --no-install-recommends build-essential - run: gem install bundler -v 2.4.22 - run: bundle config set deployment 'true' From 0fafaf52334304e1c3fc822df2a2af0653fd14bf Mon Sep 17 00:00:00 2001 From: yart Date: Tue, 18 Jun 2024 13:14:57 +0300 Subject: [PATCH 11/14] fix(nokogiri): try with docker --- .github/workflows/build.yml | 57 +++++++++++++++++++------------------ 1 file changed, 30 insertions(+), 27 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 9356061..184fb92 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -10,30 +10,33 @@ on: jobs: test: - runs-on: ubuntu-latest - - strategy: - matrix: - ruby-version: [ '2.7.0' ] - - steps: - - uses: actions/checkout@v2 - - name: Set up Ruby - uses: ruby/setup-ruby@v1 - with: - ruby-version: ${{ matrix.ruby-version }} - - - uses: actions/cache@v1 - with: - path: vendor/bundle - key: gems-${{ runner.os }}-${{ matrix.ruby-version }}-${{ hashFiles('**/Gemfile.lock') }} - - # - run: gem update --system 3.4.22 - - run: sudo apt-get install -y --no-install-recommends build-essential - - run: gem install bundler -v 2.4.22 - - - run: bundle config set deployment 'true' - - run: bundle config build.nokogiri --use-system-libraries - - run: bundle install - - - run: bundle exec middleman build + -runs: + using: 'docker' + image: 'Dockerfile' + # runs-on: ubuntu-latest + # + # strategy: + # matrix: + # ruby-version: [ '2.7.0' ] + # + # steps: + # - uses: actions/checkout@v2 + # - name: Set up Ruby + # uses: ruby/setup-ruby@v1 + # with: + # ruby-version: ${{ matrix.ruby-version }} + # + # - uses: actions/cache@v1 + # with: + # path: vendor/bundle + # key: gems-${{ runner.os }}-${{ matrix.ruby-version }}-${{ hashFiles('**/Gemfile.lock') }} + # + # # - run: gem update --system 3.4.22 + # - run: sudo apt-get install -y --no-install-recommends build-essential + # - run: gem install bundler -v 2.4.22 + # + # - run: bundle config set deployment 'true' + # - run: bundle config build.nokogiri --use-system-libraries + # - run: bundle install + # + # - run: bundle exec middleman build From 8edec0fcb20d28c03cb85b19818d684a537506e7 Mon Sep 17 00:00:00 2001 From: yart Date: Tue, 18 Jun 2024 13:53:50 +0300 Subject: [PATCH 12/14] fix(nokogiri): docker and old ignores --- .github/workflows/build.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 184fb92..a50e1f2 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -3,10 +3,10 @@ name: Build on: push: branches: [ '*' ] - paths-ignore: [ 'README.md', '**.html.md', '**.md.erb' ] + paths-ignore: [ '**.md' ] pull_request: branches: [ '*' ] - paths-ignore: [ 'README.md', '**.html.md', '**.md.erb' ] + paths-ignore: [ '**.md' ] jobs: test: From 434462b8dd19d762f129e4a3c48a5502a4e8de69 Mon Sep 17 00:00:00 2001 From: yart Date: Tue, 18 Jun 2024 13:56:20 +0300 Subject: [PATCH 13/14] fix(nokogiri): changed md.erb for test actions --- source/includes/_intro.md.erb | 1 - 1 file changed, 1 deletion(-) diff --git a/source/includes/_intro.md.erb b/source/includes/_intro.md.erb index 7856759..e546435 100644 --- a/source/includes/_intro.md.erb +++ b/source/includes/_intro.md.erb @@ -10,4 +10,3 @@ We provide examples as: - Javascript (web) - Swift (iOS) - Kotlin (Android) - From bb9db48205d6e19fa2a345d97d48bf0b45bddd6f Mon Sep 17 00:00:00 2001 From: yart Date: Tue, 18 Jun 2024 13:57:37 +0300 Subject: [PATCH 14/14] fix(nokogiri): changed rb file for test actions --- lib/toc_data.rb | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/toc_data.rb b/lib/toc_data.rb index 4a04efe..924a6e9 100644 --- a/lib/toc_data.rb +++ b/lib/toc_data.rb @@ -29,3 +29,4 @@ def toc_data(page_content) end headers end +