Middleman を実践で採用できるように基礎を中心にデプロイができるまでを目標としたマンツーマンオンライン講座です。
- Middleman の基礎〜デプロイ
- Ruby 環境の用意
set fileencodings=utf-8,ucs-bom,euc-jp,iso-2022-jp,sjis,cp932,utf-16,utf-16le | |
"scriptencoding utf-8 | |
"set verbosefile=~/vimlog | |
call plug#begin('~/.vim/plugged') | |
Plug 'prabirshrestha/async.vim' | |
Plug 'prabirshrestha/asyncomplete.vim' | |
Plug 'prabirshrestha/asyncomplete-lsp.vim' | |
Plug 'prabirshrestha/vim-lsp' |
package main | |
import ( | |
"fmt" | |
"log" | |
"sort" | |
"strings" | |
) | |
type filter struct { |
"gem install slim_lint が必要 | |
function! SlimLint() | |
let slim_lint = "slim-lint" | |
silent cexpr system(slim_lint . " " . shellescape(expand('%'))) | |
copen | |
endfunction | |
"augroupで適当にくくったほうがいい | |
autocmd BufWritePost *.slim call SlimLint() |
package main | |
import ( | |
"encoding/xml" | |
"fmt" | |
"io/ioutil" | |
"net/http" | |
"os" | |
) |
# Middleman Directory API test | |
# Ruby v1.9.3-p551 (rbenv) | |
require 'open-uri' | |
require 'json' | |
amicus = 'https://directory.middlemanapp.com/api/amicus.json' | |
uri = ::URI.parse(amicus) | |
p uri.read |
<div class="sample"> | |
<?php if ($hoge === true):?> | |
<div class="inner"> | |
<p> | |
hogehoge | |
</p> | |
<p> | |
<?php echo $hoge;?> | |
</p> | |
</div> |
Feature: Middleman-Typescript | |
Scenario: Middleman build | |
Given a fixture app "basic-app" | |
And a file named "config.rb" with: | |
""" | |
ignore "source/typescripts/*" | |
activate :typescript | |
""" | |
And a successfully built app at "basic-app" |
doctype html | |
html | |
head | |
meta charset="utf-8" | |
meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" | |
title | |
== current_page.data.title || 'VirtKick, a 1-Click Cloud Management Center' | |
meta name="description" content="A simple yet powerful cloud management center. Use on your laptop, home server or in the data center! 100% open source." | |
meta name="viewport" content="width=device-width" | |
link rel="shortcut icon" href="/favicon.ico" |