Jekyll Last Modified At 插件使用教程

Jekyll Last Modified At 插件使用教程

jekyll-last-modified-atA Jekyll plugin to show the last_modified_at time of a post.项目地址:https://gitcode.com/gh_mirrors/je/jekyll-last-modified-at

项目目录结构及介绍

jekyll-last-modified-at/
├── _plugins/
│   └── jekyll-last-modified-at.rb
├── lib/
│   ├── jekyll-last-modified-at/
│   │   ├── executor.rb
│   │   ├── git_metadata_generator.rb
│   │   └── version.rb
│   └── jekyll-last-modified-at.rb
├── spec/
│   ├── executor_spec.rb
│   ├── git_metadata_generator_spec.rb
│   └── spec_helper.rb
├── .gitignore
├── .rubocop.yml
├── .ruby-version
├── CHANGELOG.md
├── Gemfile
├── LICENSE.txt
├── README.md
├── Rakefile
└── jekyll-last-modified-at.gemspec
  • _plugins/: 存放插件的主要文件 jekyll-last-modified-at.rb
  • lib/: 包含插件的核心逻辑文件。
  • spec/: 包含测试文件。
  • .gitignore: Git 忽略文件配置。
  • .rubocop.yml: RuboCop 配置文件。
  • .ruby-version: Ruby 版本配置。
  • CHANGELOG.md: 更新日志。
  • Gemfile: Ruby 依赖管理文件。
  • LICENSE.txt: 许可证文件。
  • README.md: 项目说明文档。
  • Rakefile: Rake 任务配置文件。
  • jekyll-last-modified-at.gemspec: 插件的 gemspec 文件。

项目的启动文件介绍

项目的启动文件是 _plugins/jekyll-last-modified-at.rb,该文件负责加载插件并注册到 Jekyll 中。

require 'jekyll-last-modified-at'

项目的配置文件介绍

插件不需要在 _config.yml 中进行特殊配置,只需确保插件文件 jekyll-last-modified-at.rb 位于 _plugins 目录下即可自动加载。

# _config.yml
# 无需特殊配置

通过以上配置,插件会自动检测并显示每个页面的最后修改时间。

jekyll-last-modified-atA Jekyll plugin to show the last_modified_at time of a post.项目地址:https://gitcode.com/gh_mirrors/je/jekyll-last-modified-at

  • 4
    点赞
  • 8
    收藏
    觉得还不错? 一键收藏
  • 打赏
    打赏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

牧微言

你的鼓励将是我创作的最大动力

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值