Haml is a markup language that’s used to cleanly and simply describe the XHTML of any web document, without the use of inline code. Haml functions as a replacement for inline page templating systems such as PHP, ERB, and ASP. However, Haml avoids the need for explicitly coding XHTML into the template, because it is actually an abstract description of the XHTML, with some code to generate dynamic c
始め Haml の紹介記事を読んだ時、要素の属性の書き方がいけてない (HTML で普通に書くより長いし、あと http-equiv があるときとか) あたりが気に入らなかったのだけど、Haml 2.2 からは HTML と同様に書けると知った (via Haml レシピブック 11の技 - ursmの日記) ので試しに atomos のテンプレートを Haml を使うよう切り替えてみた。 最低限の使い方をメモ。 基本 %h1 What is the Best Template Engine on Ruby? %p The answer is %strong Haml ↓ <h1>What is the Best Template Engine on Ruby?</h1> <p> The answer is <strong>Haml</strong> </p> %{タグ名} で表された要素
Configuring Settings Sinatra includes a number of built-in settings that control whether certain features are enabled. Settings are application-level variables that are modified using one of the set, enable, or disable methods and are available within the request context via the settings object. Applications are free to set custom settings as well as the default, built-in settings provided by the
必要なもの xmlstarlet curl スクリプト #! /bin/bash SCREENNAME=oogatta; targetID=`curl -s "http://api.twitter.com/1/users/show.xml?screen_name=$1" | xmlstarlet sel -t -v 'user/id'`; curl -s "http://api.twitter.com/1/followers/ids.xml?screen_name=$SCREENNAME&cursor=-1" | xmlstarlet sel -t -m 'id_list/ids/id' -v '.' -n | grep "^$targetID$"; 実行例 むこうもフォローしてるよ! oogatta@oogatta-ubuntu:~$ ./unko.sh sugamasao 457930
リリース、障害情報などのサービスのお知らせ
最新の人気エントリーの配信
処理を実行中です
j次のブックマーク
k前のブックマーク
lあとで読む
eコメント一覧を開く
oページを開く