Skip to content

Instantly share code, notes, and snippets.

Multiple MySQL Versions with Homebrew

For homebrew version 0.9.5.

brew -v # => Homebrew 0.9.5

Install the current version of mysql.

# Install current mysql version

brew install mysql

@tadamak
tadamak / vm-resize-hard-disk.md
Created April 14, 2016 09:57 — forked from christopher-hopper/vm-resize-hard-disk.md
Resize a Hard Disk for a Virtual Machine provisioned using Vagrant from a Linux base box to run using VirutalBox.

Resize a Hard Disk for a Virtual Machine

Our Virtual Machines are provisioned using Vagrant from a Linux base box to run using VirutalBox. If the Hard Disk space runs out and you cannot remove files to free-up space, you can resize the Hard Disk using some VirtualBox and Linux commands.

Some assumptions

The following steps assume you've got a set-up like mine, where:

require 'zlib'
require 'fileutils'
require 'time'
require 'tempfile'
module Utils
def delete_file(path)
File.delete(path) if File.exists?(path)
end
@tadamak
tadamak / emacs.rb
Created September 22, 2012 10:00 — forked from rfkm/emacs.rb
Emacs24.2 Formula with inline-patch(+fix)
require 'formula'
class Emacs < Formula
homepage 'http://www.gnu.org/software/emacs/'
url 'http://ftp.gnu.org/pub/gnu/emacs/emacs-24.2.tar.gz'
sha1 '5fc4fe7797f821f2021ac415a81f5f190c52c0b2'
depends_on "autoconf" => :build
if ARGV.include? "--use-git-head"
@tadamak
tadamak / gist:2289427
Created April 3, 2012 05:09
CSV切り出し
cat error_all.csv | cut -d "," -f 1,4,6
@tadamak
tadamak / gist:1138720
Created August 11, 2011 01:33
MVC3でjquery.validate.jsのエラー表示カスタマイズ
var validator = $("#form").data('validator');
validator.settings.errorPlacement = function (error, element) {
// Error placement for single elements
var offset = element.offset();
error.insertBefore(element)
error.addClass('message'); // add a class to the wrapper
error.css('position', 'absolute');
error.css('left', offset.left + element.outerWidth());
error.css('top', offset.top - (element.height() / 2));
};
@tadamak
tadamak / gist:984553
Created May 21, 2011 14:04
Undefined method 'task'
module ::APP_NAME
class Application
include Rake::DSL
end
end
module ::RakeFileUtils
extend Rake::FileUtilsExt
end