Upgrade to Pro — share decks privately, control downloads, hide ads and more …

みんなもMiddlemanで技術ブログ作って幸せになろう!

ikuwow
June 12, 2015

 みんなもMiddlemanで技術ブログ作って幸せになろう!

@HTML5minutes

ikuwow

June 12, 2015
Tweet

More Decks by ikuwow

Other Decks in Programming

Transcript

  1. ࣗݾ঺հ • ग़઒ ز෉ʢσΨϫ ΠΫΦʣ • 2015೥4݄ϨόϨδʔζ৽ଔೖࣾ • teratail։ൃνʔϜ ΤϯδχΞ

    • PHPͷਓ • झຯɿαʔόʔࣗಈԽ • ͠Ό΂Δͷۤखɻͨ·ʹ͕࣌ࢭ·Δɻ @ikuwow
  2. ϒϩά͕௒؆୯ʹ࡞ΕΔ • middleman-blogͱ͍ ͏ެࣜϓϥάΠϯ͕௒ ༏ल • λά෇͚ɺԼॻ͖ɺ URL੔ܗɺΞʔΧΠ ϒɺ… $

    middleman init —template=blog $ middleman serve ## config.rb activate :blog do |blog| # ϒϩάػೳͷΦϓγϣϯΛઃఆ end
  3. σΟϨΫτϦߏ੒ • Jekyllʹൺ΂ͯ
 ௒γϯϓϧ myblog/ +-- .gitignore +-- Gemfile +--

    Gemfile.lock +-- config.rb +-- source/ +-- images/ ¦ +-- background.png ¦ +-- middleman.png +-- index.html.erb +-- javascripts/ ¦ +-- all.js +-- layouts/ ¦ +-- layout.erb +-- stylesheets/ +-- all.css +-- normalize.css +-- build/
  4. RailsͷViewͬΆ͘ॻ͚Δ <% wrap_layout :layout do %> <h1><%= current_article.title unless current_article.nil?

    %></h1> <p class="post-meta""> <% if !current_article.nil? %> <% current_article.tags.each do |tag| %> <%= link_to tag, tag_path(tag), :class => "post-category post-category-design"%> <% end %> <% end %> </p> <div class="social-buttons-box"> <%= partial "social_buttons" %> </div> <%= link_to ‘ϗʔϜ’, ‘http://ikuwow.website' %> <% end %>