Skip to content

Instantly share code, notes, and snippets.

@suvene
suvene / gist:5076262
Last active December 14, 2015 10:59
falcon スコープ
falcon スコープ
===============
対象範囲
---------------
- 売上登録
- 請求締
- 請求登録
- 入金登録
- 原価登録
@suvene
suvene / gist:5038282
Created February 26, 2013 13:07
query for redmine issue
select id, substr(subject, 1, 15), category_id, project_id, created_on from issues order by updated_on;
select issues.id, substr(subject, 1, 15), category_id, project_id, created_on
FROM `issues` INNER JOIN issue_statuses ist on ist.id = issues.status_id WHERE (1 = 1
and (issues.assigned_to_id = 3
and issues.start_date < '2013-02-11 00:00:00'
and ist.is_closed != 1))
;
@suvene
suvene / git-pull-rebase.txt
Created February 11, 2013 09:43
git rebaseについて
git pull について
http://dxd8.com/archives/218/
------
O-Show 2011-04-08 05:20
こんにちは。
git config branch.ブランチ名.mergeoptions “–no-ff”
で常にファストフォワードではないマージを行うことについて一つ。
@suvene
suvene / gist:4750480
Last active December 12, 2015 09:19
ActiveRecordHelper
ActiveRecordHelper
module ActiveRecordHelper
def flatten_conditions(conditions, op = "and")
return nil if conditions.empty?
ps = []
condition = conditions.collect do |c|
next if c.size < 1
ps += c[1..(c.size)]
"( #{c[0]} )"
@suvene
suvene / gist:2601101
Created May 5, 2012 09:01
KeyRemap4MacBook for gvim
<?xml version="1.0"?>
<root>
<appdef>
<appname>GVim</appname>
<equal>org.vim.MacVim</equal>
</appdef>
<item>
<name>My GVim Hack</name>
<appendix>Change ESC to ESC + KANA</appendix>
@suvene
suvene / install-ruby-debug-ubuntu-ruby-1.9.3
Created April 28, 2012 00:34 — forked from boriscy/install-ruby-debug-ubuntu-ruby-1.9.3
ruby-debug in ruby-1.9.3 and ubuntu
#To install ruby-debug on Ubuntu ruby-1.9.3 you need to download from http://rubyforge.org/frs/?group_id=8883
linecache19-0.5.13.gem
ruby_core_source-0.1.5.gem
ruby-debug19-0.11.6.gem
ruby-debug-base19-0.11.26.gem
#Then in your console
export RVM_SRC=/your/path/to/ruby-1.9.3
@suvene
suvene / gist:2137801
Created March 20, 2012 16:17 — forked from zaininnari/git-install.csh
さくらインターネット スタンダードプラン git インストール
We couldn’t find that file to show.
@suvene
suvene / gist:2073781
Created March 18, 2012 14:19
vim-plugin
[submodule "bundle/vim-pathogen"]
path = bundle/vim-pathogen
url = git://github.com/tpope/vim-pathogen.git
[submodule "bundle/minibufexpl.vim"]
path = bundle/minibufexpl.vim
url = git://github.com/fholgado/minibufexpl.vim.git
[submodule "bundle/eregex.vim"]
path = bundle/eregex.vim
url = git://github.com/othree/eregex.vim
[submodule "bundle/vim-mru"]
@suvene
suvene / mac_ports
Created March 18, 2012 06:13
mac ports
# update
sudo port -d selfupdate
sudo port -d sync
sudo port upgrade outdated
# install
sudo port installed
sudo port search <module>
sudo port install <module @version>
sudo port variants <module>
// ==UserScript==
// @name G+ FormatDate
// @author suVene
// @version 0.1.0
// @namespace https://gist.github.com/raw/1115074/3a9327ed58907df0db1b755361875fedac87e682/G+.FormatDate.user.js
// @description formate date for post date
// @include https://plus.google.com/*
// @match https://plus.google.com/*
// ==/UserScript==