我最近升級到 macOS 12.3,這破壞了我的 jekyll 網站。當我在升級后第一次嘗試建立我的網站時,我的電腦(帶有 Intel 芯片的 Macbook Air)會崩潰。
到目前為止,我已經升級了自制軟體并解決了所有警告:
$ brew -v
Homebrew 3.4.3
Homebrew/homebrew-core (git revision 0d76941ceaf; last commit 2022-03-26)
$ brew doctor
Your system is ready to brew.
我已經使用 rbenv 安裝了 ruby?? 3.0.2 版:
$ ruby -v
ruby 3.0.2p107 (2021-07-07 revision 0db68f0233) [x86_64-darwin21]
我按照https://jekyllrb.com/tutorials/using-jekyll-with-bundler/中概述的步驟創建了一個新站點,以便將其與使我的計算機崩潰的舊站點進行比較。我努力確保舊站點目錄的內容與新站點目錄匹配。新站點構建,但是當我嘗試構建舊站點時出現以下錯誤:
$ bundle exec jekyll s -t
Generating...
bundler: failed to load command: jekyll (/Users/hepting/Sites/dhhepting.github.io/vendor/bundle/ruby/3.0.0/bin/jekyll)
/Users/hepting/.rbenv/versions/3.0.2/lib/ruby/3.0.0/fileutils.rb:1466:in `unlink': Operation not permitted @ apply2files - /Users/hepting/Sites/dhhepting.github.io/_site/research/works (Errno::EPERM)
杰基爾在那里:
$ /Users/hepting/Sites/dhhepting.github.io/vendor/bundle/ruby/3.0.0/bin/jekyll -v
jekyll 4.2.2
這是我舊網站的“研究/作業”目錄:
$ ls -l research/works
total 8
drwxr-xr-x 4 hepting staff 128 23 Oct 2018 0_nonweb
-rw-r--r-- 1 hepting staff 798 21 Jan 2020 index.md
這個 index.md 檔案包含(部分):
---
layout: w_collection
title: Collected Works
redirect_from:
- /research/works.html
breadcrumb: Collected Works
collection: works
---
I have the following defined in my _config.yml for research/works. I didn't think that the problem was here since it has worked fine for years. On the web, the page is at http://www2.cs.uregina.ca/~hepting/research/works/
collections:
- works
collections:
works:
output: true
permalink: /research/:collection/:title:output_ext
Here's the Gemfile that I use for both sites:
source "https://rubygems.org"
# When you want to use a different version, change it below, save the
# file and run `bundle install`. Run Jekyll with `bundle exec`, like so:
#
# bundle exec jekyll serve
#
# This will help ensure the proper Jekyll version is running.
gem "jekyll", "~> 4.2.2"
gem "minima", "~> 2.5"
gem "webrick", "~> 1.7"
gem "nokogiri", '>= 1.12.5'
gem 'html-proofer', '>= 3.15.3'
group :jekyll_plugins do
gem 'jekyll-seo-tag'
gem 'jekyll-sitemap'
gem 'jekyll-redirect-from'
end
I have the following .bundle/config:
---
BUNDLE_PATH: "vendor/bundle"
When I do "bundle install" (in the old site directory):
$ bundle install
Using public_suffix 4.0.6
Using addressable 2.8.0
Using bundler 2.3.10
Using colorator 1.1.0
Using concurrent-ruby 1.1.10
Using eventmachine 1.2.7
Using http_parser.rb 0.8.0
Using em-websocket 0.5.3
Using ffi 1.15.5
Using ethon 0.15.0
Using forwardable-extended 2.6.0
Using mercenary 0.4.0
Using mini_portile2 2.8.0
Using racc 1.6.0
Using nokogiri 1.13.3 (x86_64-darwin)
Using parallel 1.22.1
Using rainbow 3.1.1
Using typhoeus 1.4.0
Using yell 2.2.2
Using html-proofer 3.19.3
Using i18n 1.10.0
Using sassc 2.4.0
Using jekyll-sass-converter 2.2.0
Using rb-fsevent 0.11.1
Using rb-inotify 0.10.1
Using listen 3.7.1
Using jekyll-watch 2.2.1
Using rexml 3.2.5
Using kramdown 2.3.2
Using kramdown-parser-gfm 1.1.0
Using liquid 4.0.3
Using pathutil 0.16.2
Using rouge 3.28.0
Using safe_yaml 1.0.5
Using unicode-display_width 1.8.0
Using terminal-table 2.0.0
Using jekyll 4.2.2
Using jekyll-feed 0.16.0
Using jekyll-redirect-from 0.16.0
Using jekyll-seo-tag 2.8.0
Using jekyll-sitemap 1.4.0
Using minima 2.5.1
Using webrick 1.7.0
Bundle complete! 8 Gemfile dependencies, 43 gems now installed.
Bundled gems are installed into `./vendor/bundle`
When I do "bundle install" (in the new site directory):
Bundle complete! 8 Gemfile dependencies, 42 gems now installed.
Bundled gems are installed into `./vendor/bundle`
The difference appears to be "mini_portile2 2.8.0". I've tried to remove it but it gets pulled back in with "bundle install".
Any suggestions about how to resolve my problem building my old site? Any information that I didn't provide?
Best regards, Daryl
uj5u.com熱心網友回復:
我能夠通過隱藏與“研究/作品”(一個集合)相關的內容來構建網站,這感覺像是一個不完整的答案。
我認為我的答案現在更完整了:似乎子目錄現在會在集合中引起問題(至少是那些有輸出的)。我洗掉了子目錄,以便我的 _works 集合中的所有專案都直接包含在 _works 目錄中,并且我的網站現在正在像以前一樣構建。
轉載請註明出處,本文鏈接:https://www.uj5u.com/qukuanlian/455227.html
上一篇:單行按尾隨數字后綴排序
