Nanoc starter using Tailwind CSS: A Comprehensive Guide

Nanoc + TailwindCSS

Starter kit for static sites on nanoc with TailwindCSS styling.

Initial setup

It is assumed you already have Ruby with Bundler and Node present.

./bin/setup

Build for production

One-time processing with optimizations.

./bin/build

Build for development

Starts in foreground, live reloads HTML and CSS changes.

./bin/server
open http://localhost:3000/

Unpacking latest release into current directory

curl -s https://api.github.com/repos/arkency/nanoc-tailwind-starter/releases/latest |\
  grep tarball_url |\
  cut -d'"' -f4 |\
  xargs -n 1 curl -sSL |\
  tar -xz --strip-components=1

.gitignore

output/
tmp/nanoc/
crash.log
node_modules/

Gemfile

# frozen_string_literal: true

source "https://rubygems.org"

gem "nanoc"
gem "adsf"
gem "adsf-live"
gem "webrick"

group :nanoc do
  gem "guard-nanoc"
end

Gemfile.lock

GEM
  remote: https://rubygems.org/
  specs:
    addressable (2.8.1)
      public_suffix (>= 2.0.2, < 6.0)
    adsf (1.4.6)
      rack (>= 1.0.0, < 3.0.0)
    adsf-live (1.4.6)
      adsf (~> 1.3)
      em-websocket (~> 0.5)
      eventmachine (~> 1.2)
      listen (~> 3.0)
      rack-livereload (~> 0.3)
    coderay (1.1.3)
    colored (1.2)
    concurrent-ruby (1.1.10)
    cri (2.15.11)
    ddmetrics (1.0.1)
    ddplugin (1.0.3)
    diff-lcs (1.5.0)
    em-websocket (0.5.3)
      eventmachine (>= 0.12.9)
      http_parser.rb (~> 0)
    eventmachine (1.2.7)
    ffi (1.15.5)
    formatador (1.1.0)
    guard (2.18.0)
      formatador (>= 0.2.4)
      listen (>= 2.7, < 4.0)
      lumberjack (>= 1.0.12, < 2.0)
      nenv (~> 0.1)
      notiffany (~> 0.0)
      pry (>= 0.13.0)
      shellany (~> 0.0)
      thor (>= 0.18.1)
    guard-compat (1.2.1)
    guard-nanoc (2.1.9)
      guard (~> 2.8)
      guard-compat (~> 1.0)
      nanoc-cli (~> 4.11, >= 4.11.14)
      nanoc-core (~> 4.11, >= 4.11.14)
    hamster (3.0.0)
      concurrent-ruby (~> 1.0)
    http_parser.rb (0.8.0)
    json_schema (0.21.0)
    listen (3.7.1)
      rb-fsevent (~> 0.10, >= 0.10.3)
      rb-inotify (~> 0.9, >= 0.9.10)
    lumberjack (1.2.8)
    memo_wise (1.7.0)
    method_source (1.0.0)
    nanoc (4.12.12)
      addressable (~> 2.5)
      colored (~> 1.2)
      nanoc-checking (~> 1.0, >= 1.0.2)
      nanoc-cli (= 4.12.12)
      nanoc-core (= 4.12.12)
      nanoc-deploying (~> 1.0)
      parallel (~> 1.12)
      tty-command (~> 0.8)
      tty-which (~> 0.4)
    nanoc-checking (1.0.2)
      nanoc-cli (~> 4.12, >= 4.12.4)
      nanoc-core (~> 4.12, >= 4.12.4)
    nanoc-cli (4.12.12)
      cri (~> 2.15)
      diff-lcs (~> 1.3)
      nanoc-core (= 4.12.12)
      zeitwerk (~> 2.1)
    nanoc-core (4.12.12)
      concurrent-ruby (~> 1.1)
      ddmetrics (~> 1.0)
      ddplugin (~> 1.0)
      hamster (~> 3.0)
      json_schema (~> 0.19)
      memo_wise (~> 1.5)
      psych (~> 4.0)
      slow_enumerator_tools (~> 1.0)
      tty-platform (~> 0.2)
      zeitwerk (~> 2.1)
    nanoc-deploying (1.0.2)
      nanoc-checking (~> 1.0)
      nanoc-cli (~> 4.11, >= 4.11.15)
      nanoc-core (~> 4.11, >= 4.11.15)
    nenv (0.3.0)
    notiffany (0.1.3)
      nenv (~> 0.1)
      shellany (~> 0.0)
    parallel (1.22.1)
    pastel (0.8.0)
      tty-color (~> 0.5)
    pry (0.14.1)
      coderay (~> 1.1)
      method_source (~> 1.0)
    psych (4.0.6)
      stringio
    public_suffix (5.0.0)
    rack (2.2.4)
    rack-livereload (0.3.17)
      rack
    rb-fsevent (0.11.2)
    rb-inotify (0.10.1)
      ffi (~> 1.0)
    shellany (0.0.1)
    slow_enumerator_tools (1.1.0)
    stringio (3.0.2)
    thor (1.2.1)
    tty-color (0.6.0)
    tty-command (0.10.1)
      pastel (~> 0.8)
    tty-platform (0.3.0)
    tty-which (0.5.0)
    webrick (1.7.0)
    zeitwerk (2.6.6)

PLATFORMS
  ruby

DEPENDENCIES
  adsf
  adsf-live
  guard-nanoc
  nanoc
  webrick

BUNDLED WITH
   2.2.29

Guardfile

# A sample Guardfile
# More info at https://github.com/guard/guard#readme

## Uncomment and set this to only include directories you want to watch
# directories %w(app lib config test spec features) \
#  .select{|d| Dir.exist?(d) ? d : UI.warning("Directory #{d} does not exist")}

## Note: if you are using the `directories` clause above and you are not
## watching the project directory ('.'), then you will want to move
## the Guardfile to a watched dir and symlink it back, e.g.
#
#  $ mkdir config
#  $ mv Guardfile config/
#  $ ln -s config/Guardfile .
#
# and, you'll have to watch "config/Guardfile" instead of "Guardfile"

# frozen_string_literal: true

guard 'nanoc' do
  watch('nanoc.yaml') # Change this to config.yaml if you use the old config file name
  watch('Rules')
  watch(%r{^(content|layouts|lib)/.*$})
  ignore(%r{^content/main\.(js|css|js\.map|css\.map)})
end

Download details:

Author: arkency
Source: https://github.com/arkency/nanoc-tailwind-starter

#tailwindcss 

Nanoc starter using Tailwind CSS: A Comprehensive Guide
1.00 GEEK