Docsyのバージョンを0.12.0へアップグレードしてみました
Docsyのバージョンを0.12.0へアップグレードしてみました。
hugoのバージョンもv0.147.6くらいまで上げてみました。
やったこと
Moduleのアップデート
hugo mod get -u
Hugoのアップグレード
ついでにHugoのアップグレードをしました。
v0.125.4→v0.147.6
choco upgrade hugo-extended
config.tomlの編集
sidebar_menu_truncateという項目がないと、アラートが出ていた。
そのため、とりあえず追加しました。
あまり意味は分かっていないです。
サイドメニューの項目数に関係すると思う。
その証拠にサイドメニューが大量に表示される様になりました。
sidebar_menu_truncate = 9999
ショートコード対応(twitterをxに変更)
ショートコードの書き方が変わったので、変更しました。
hugoの内部でtwitterでもxでも両対応して欲しい気持ちはある。
# 変更前
twitter user="" id=""
# 変更後
x user="" id=""
コンテナレジストリ廃止に対する対応
GitLabに登録されているコンテナのイメージが非推奨になっていたので、.gitlab-ci.ymlの中身を編集しました。
ちなみに、GitLab上でHugoのREADME.mdを見て、気が付きました。
As of 2025-01-16 (MR), this project relies on the Docker image of https://docker.hugomods.com.
The last version of Hugo uploaded in the
container registry
is 0.140.2. You're advised to replace registry.gitlab.com/pages/hugo/hugo_extended:latest
with hugomods/hugo:exts.
# 変更前
image: registry.gitlab.com/pages/hugo/hugo_extended:latest
# 変更後
image: hugomods/hugo:exts
関連記事
[https://github.com/google/docsy/releases/tag/v0.12.0](https://github.com/google/docsy/releases/tag/v0.12.0)
[Docsyのバージョンを0.10.0へアップグレードしてみました
2024/05/02](https://miajimyu.com/blog/2024/05/02/docsy%E3%81%AE%E3%83%90%E3%83%BC%E3%82%B8%E3%83%A7%E3%83%B3%E3%82%920.10.0%E3%81%B8%E3%82%A2%E3%83%83%E3%83%97%E3%82%B0%E3%83%AC%E3%83%BC%E3%83%89%E3%81%97%E3%81%A6%E3%81%BF%E3%81%BE%E3%81%97%E3%81%9F/)