Skip to content

Instantly share code, notes, and snippets.

@saicologic
saicologic / dbdoc.rake
Last active August 31, 2015 02:18 — forked from ayasuda/dbdoc.rake
データベース定義書を作るタスク(rails用)
require 'rake'
Table = Struct.new(:name, :comment, :columns, :indexes)
Column = Struct.new(:name, :type, :not_null, :default, :primary_key, :comment)
Index = Struct.new(:name, :columns, :primary, :unique)
def get_schema_info(klass)
table = Table.new
table.name = klass.table_name
table.columns = []
@saicologic
saicologic / memusg
Created August 30, 2017 01:01 — forked from netj/memusg
memusg -- Measure memory usage of processes
#!/usr/bin/env bash
# memusg -- Measure memory usage of processes
# Usage: memusg COMMAND [ARGS]...
#
# Author: Jaeho Shin <[email protected]>
# Created: 2010-08-16
############################################################################
# Copyright 2010 Jaeho Shin. #
# #
# Licensed under the Apache License, Version 2.0 (the "License"); #