Beautiful Jekyll 项目教程

随笔3周前发布
36 0 0

Beautiful Jekyll 项目教程

beautiful-jekyll✨ Build a beautiful and simple website in literally minutes. Demo at https://beautifuljekyll.com项目地址:https://gitcode.com/gh_mirrors/be/beautiful-jekyll

1. 项目的目录结构及介绍

Beautiful Jekyll 是一个基于 Jekyll 的静态网站生成器,其目录结构如下:

  1. beautiful-jekyll/

  2. ├── _config.yml

  3. ├── _data

  4. │ └── authors.yml

  5. ├── _includes

  6. │ ├── footer.html

  7. │ ├── head.html

  8. │ ├── header.html

  9. │ └── scripts.html

  10. ├── _layouts

  11. │ ├── default.html

  12. │ ├── page.html

  13. │ └── post.html

  14. ├── _posts

  15. │ └── 2023-01-01-welcome-to-beautiful-jekyll.md

  16. ├── _sass

  17. │ ├── _base.scss

  18. │ ├── _layout.scss

  19. │ └── _syntax-highlighting.scss

  20. ├── assets

  21. │ ├── css

  22. │ │ └── main.scss

  23. │ ├── img

  24. │ └── js

  25. ├── Gemfile

  26. ├── Gemfile.lock

  27. ├── index.html

  28. └── README.md

目录结构介绍

  • _config.yml: 项目的配置文件。
  • _data/authors.yml: 存储作者信息的文件。
  • _includes/: 包含页面的各个部分,如头部、尾部、脚本等。
  • _layouts/: 定义页面的布局模板。
  • _posts/: 存储博客文章的目录。
  • _sass/: 包含 Sass 文件,用于生成 CSS。
  • assets/: 包含静态资源,如 CSS、图片和 JavaScript 文件。
  • GemfileGemfile.lock: 定义项目依赖的 Gem 文件。
  • index.html: 网站的首页。
  • README.md: 项目的说明文档。

2. 项目的启动文件介绍

Beautiful Jekyll 的启动文件是 index.html,它是网站的首页。这个文件使用了 _layouts/default.html 布局,并包含了网站的主要内容。

  1. ---

  2. layout: page

  3. title: Home

  4. ---

3. 项目的配置文件介绍

项目的配置文件是 _config.yml,它包含了网站的各种配置选项。以下是一些重要的配置项:

  1. title: Beautiful Jekyll

  2. subtitle: "Build a beautiful and simple website in literally minutes. Demo at <https://beautifuljekyll.com>"

  3. baseurl: ""

  4. url: "https://beautifuljekyll.com"

  5. github-username: daattali

  6. email: example@example.com

  7. description: "A flexible two-column Jekyll theme, perfect for building personal sites, blogs, and portfolios."

  8. markdown: kramdown

  9. theme: minima

  10. plugins:

  11. - jekyll-feed

  12. - jekyll-paginate

配置项介绍

  • title: 网站的标题。
  • subtitle: 网站的副标题。
  • baseurl: 网站的基本 URL。
  • url: 网站的完整 URL。
  • github-username: GitHub 用户名。
  • email: 联系邮箱。
  • description: 网站的描述。
  • markdown: 使用的 Markdown 解析器。
  • theme: 使用的主题。
  • plugins: 使用的插件列表。

通过这些配置项,可以自定义网站的外观和行为。

beautiful-jekyll✨ Build a beautiful and simple website in literally minutes. Demo at https://beautifuljekyll.com项目地址:https://gitcode.com/gh_mirrors/be/beautiful-jekyll

© 版权声明

相关文章

暂无评论

您必须登录才能参与评论!
立即登录
暂无评论...