joplin-notes/joplin notion extension/Web Development/Extras/jekyll/Deployment.md
2026-11-04 00:33:23 +05:30

1.6 KiB

Deployment

  • Before deployment there is something called collections which can be defined in _config.yml in root of site so there is site.data, site.posts which are predefined so for more like site.authors type following in _config.yml
collections:
  authors:
    output: true

By default it wont output to page so using this when clicked on author it will redirect to its page More refer to https://jekyllrb.com/docs/step-by-step/09-collections/

  • Now going back to root of project so type cd ... as jekyll is installed and all the versions are locked so in order to serve or build with those versions instead of system ones use bundle exec jekyll serve instead of jekyll serve. this will restrict the enviroment to use gems set in Gemfile.
  • Some other important plugins
    • jekyll-sitemap - Creates a sitemap file to help search engines index content
    • jekyll-feed - Creates an RSS feed for your posts
    • jekyll-seo-tag - Adds meta tags to help with SEO
  • in Gemfile
source 'https://rubygems.org'

gem "jekyll"

group :jekyll_plugins do
  gem "jekyll-sitemap"
  gem "jekyll-feed"
  gem "jekyll-seo-tag"
end
  • in _config.yml
plugins:
  - jekyll-feed
  - jekyll-sitemap
  - jekyll-seo-tag

now install by bundle update in _layouts/default.html add these tags

<!doctype html>
<html>
  <head>
    <meta charset="utf-8">
    <title>{{ page.title }}</title>
    <link rel="stylesheet" href="/assets/css/styles.css">
    {% feed_meta %}
    {% seo %}
  </head>
  <body>
    {% include navigation.html %}
    {{ content }}
  </body>
</html>