Skip to content

Instantly share code, notes, and snippets.

View shimizukawa's full-sized avatar

Takayuki SHIMIZUKAWA shimizukawa

View GitHub Profile
cookbook_path ["cookbooks", "site-cookbooks"]
role_path "roles"
data_bag_path "data_bags"
encrypted_data_bag_secret ".chef/data_bag_key"
environment_path "environments"
Vagrant::Config.run do |config|
config.vm.box = "ubuntu-12.10-x64" #http://cloud-images.ubuntu.com/quantal/current/quantal-server-cloudimg-vagrant-amd64-disk1.box
config.vm.provision :chef_solo do |chef|
#chef.log_level = "debug"
chef.cookbooks_path = "cookbooks"
chef.roles_path = "roles"
chef.add_role "python-build"
end
@shimizukawa
shimizukawa / Cheffile
Created April 2, 2013 10:41
chefでCentOSにMySQL5.5以降をインストールしたい! -> fork版 mysql cookbookを使えばできる!(このgist) -> remi repository使えば yum install mysql-serverでいけるよ! http://tk0miya.hatenablog.com/entry/2013/04/03/141656 (新情報!!)
cookbook 'mysql',
:git => 'https://github.com/9minutesnooze/mysql.git',
:ref => 'mysql56'
@shimizukawa
shimizukawa / gist:5167009
Created March 15, 2013 02:14
vagrant + veewee を動作させるためのバージョンの組み合わせをbundlerで調べてみた。ただしbundle exec veeweeを実行するとエラーになった。なんでじゃ
$ sudo aptitude install libxml2-dev libxslt-dev
$ sudo gem install bundler
$ mkdir /tmp/veewee
$ cd /tmp/veewee
$ bundle init
$ cat << HERE >> Gemfile 2>&1
gem "vagrant"
gem "veewee"
HERE
$ bundle install --path .
@shimizukawa
shimizukawa / _templates-localtoc.html
Created March 11, 2013 03:35
Sphinx extension to render local toctree in templates (ex. sidebar). see also: https://groups.google.com/d/topic/sphinx-users/dqfCLab4oB0/discussion
<h3>toctree</h3>
{{ local_toctree(pagename, maxdepth=-1) }}
@shimizukawa
shimizukawa / gist:5071213
Created March 2, 2013 14:24
sphinx build script for drone.io
export BUILD_TEST_PATH=tests
pip install . --use-mirrors
pip install nose sqlalchemy whoosh --use-mirrors
python tests/run.py
sphinx-build -W -b html -d _build/doctrees doc _build/html
@shimizukawa
shimizukawa / PIL_build.rst
Last active June 26, 2016 14:32 — forked from adrianer/PIL_build.rst
PIL(Pillow) build on Windows (32bit & 64bit)

PIL(Pillow) build on Windows (32bit & 64bit)

If you want to build PIL on Windows, you need to prepare few external libraries. Although some libraries did not provide static library for windows 32/64 bits then you need to build these libraries by your hand too. Also, PIL will load by python at last then you are recommended to use same compiler with python to build libraries.

Target PIL and versions

Pillow:1.7.8 for Python 2.7: src
@shimizukawa
shimizukawa / PIL_build.rst
Last active December 11, 2015 17:28
PIL (Pillow) build procedure

PIL(Pillow) build on Windows (32bit)

If you want to build PIL on Windows, you need to prepare few external libraries. Although some libraries did not provide static library for windows 32/64 bits then you need to build these libraries by your hand too. Also, PIL will load by python at last then you are recommended to use same compiler with python to build libraries.

Target PIL and versions

PIL:1.1.7 for Python 2.4 (or Pillow-1.7.8)
@shimizukawa
shimizukawa / conf.py
Last active December 11, 2015 04:28
sphinx: doc reference by using substitution and custome 'doc' inline directive. inspired by https://bitbucket.org/birkenfeld/sphinx/issue/1077
############################################
# inline doc directive for substitution
# rst: .. |sub| doc:: docname
# html: <a href="docname.html">sub</a>
from sphinx.util.compat import Directive
from sphinx.roles import XRefRole
class DocDirective(Directive):
required_arguments = 1