Skip to content

Instantly share code, notes, and snippets.

@troter
troter / gist:2193220
Created March 25, 2012 12:11
hackable mercurial 16279 (531e69ff348f) のテスト結果
Skipped test-add.t: system supports Windows
Skipped test-addremove.t: system supports Windows
Skipped test-alias.t: missing feature: system() uses sh
Skipped test-archive-symlinks.t: missing feature: symbolic links
Skipped test-archive.t: missing feature: platform and python can manage 'hg serve -d'
Skipped test-audit-path.t: missing feature: symbolic links
Skipped test-bad-pull.t: missing feature: platform and python can manage 'hg serve -d'
Skipped test-bisect.t: missing feature: system() uses sh
Skipped test-bookmarks-pushpull.t: missing feature: platform and python can manage 'hg serve -d'
Skipped test-bundle.t: missing feature: system() uses sh
@troter
troter / gist:2192936
Created March 25, 2012 11:12
hackable mercurial 2.1 のテスト結果
Skipped test-add.t: system supports Windows
Skipped test-addremove.t: system supports Windows
Skipped test-alias.t: missing feature: system() uses sh
Skipped test-archive-symlinks.t: missing feature: symbolic links
Skipped test-archive.t: missing feature: platform and python can manage 'hg serve -d'
Skipped test-audit-path.t: missing feature: symbolic links
Skipped test-bad-pull.t: missing feature: platform and python can manage 'hg serve -d'
Skipped test-bisect.t: missing feature: system() uses sh
Skipped test-bookmarks-pushpull.t: missing feature: platform and python can manage 'hg serve -d'
Skipped test-bundle.t: missing feature: system() uses sh
@troter
troter / gist:2145640
Created March 21, 2012 08:40
mercurial-2.1 + Python 2.7.2 traceback
** 予期せぬ例外が発生しました
** http://mercurial.selenic.com/wiki/BugTracker まで
** 以下の情報を報告してください。
** Python 2.7.2 (default, Feb 27 2012, 17:38:03) [GCC 4.1.2 20080704 (Red Hat 4.1.2-51)]
** Mercurial Distributed SCM (version 2.1)
** Extensions loaded: churn, color, convert, eol, extdiff, fetch, graphlog, mq, pager, progress, rebase, record, transplant
Traceback (most recent call last):
File "/home/takumi/.pythonbrew/pythons/Python-2.7.2/bin/hg", line 38, in <module>
mercurial.dispatch.run()
File "/home/takumi/.pythonbrew/pythons/Python-2.7.2/lib/python2.7/site-packages/mercurial/dispatch.py", line 27, in run
@troter
troter / gist:2027972
Created March 13, 2012 10:11
rackhub.netにpythonbrewでpython-2.7/2をインストールしようとするとtest_uuidのテストに失敗する
test_uuid
test test_uuid failed -- Traceback (most recent call last):
File "/home/rackhuber/.pythonbrew/build/Python-2.7.2/Lib/test/test_uuid.py", line 306, in test_ifconfig_getnode
node = uuid._ifconfig_getnode()
File "/home/rackhuber/.pythonbrew/build/Python-2.7.2/Lib/uuid.py", line 321, in _ifconfig_getnode
mac = _find_mac('ifconfig', args, ['hwaddr', 'ether'], lambda i: i+1)
File "/home/rackhuber/.pythonbrew/build/Python-2.7.2/Lib/uuid.py", line 311, in _find_mac
words[get_index(i)].replace(':', ''), 16)
ValueError: invalid literal for int() with base 16: '00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00'
create table member (
id INT NOT NULL AUTO_INCREMENT COMMENT 'ID',
name VARCHAR(100) DEFAULT '' NOT NULL COMMENT '氏名',
created_date DATETIME NOT NULL COMMENT '作成日時',
updated_date DATETIME NOT NULL COMMENT '更新日時',
deleted_date DATETIME COMMENT '削除日時',
version INT DEFAULT 0 NOT NULL COMMENT 'オプティミスティックロック用',
CONSTRAINT member_pk PRIMARY KEY(id)
) COMMENT = 'メンバー' DEFAULT CHARSET=UTF8;
@troter
troter / mercurial-introduction.rst
Created October 30, 2011 09:51
SCMBC #2 Mercurial入門セッション資料(のたたき台) move to https://bitbucket.org/troter/scmbc-2011.11-mercurial-introsession

Mercurial 入門セッション資料

この資料について

  • SCMBC #2 Mercurial 入門セッション資料(のたたき台)です。
  • TODO たとえ話募集中

(おまけ)分散バージョン管理全般の利点

@troter
troter / gist:1290799
Created October 16, 2011 11:57
aircastle/flaskrのimportの依存関係
digraph {
"flaskr.__init__.py" -> "flasker.util.db"
"flaskr.__init__.py" -> "flasker.controller.general"
"flaskr.__init__.py" -> "flasker.controller.user"
"flaskr.__init__.py" -> "flasker.controller.entry"
"flaskr.__init__.py" -> "flasker.controller.comment"
"flasker.controller.comment" -> "flaskr.model.entry"
"flasker.controller.comment" -> "flaskr.model.comment"
"flasker.controller.comment" -> "flaskr.controller.form"
@troter
troter / gist:1289101
Created October 15, 2011 05:30
finally timing
% python [31909]
Python 2.6.5 (r265:79063, Jun 12 2010, 17:07:01)
[GCC 4.3.4 20090804 (release) 1] on cygwin
Type "help", "copyright", "credits" or "license" for more information.
>>> def g():
... try:
... yield 1
... finally:
... print "finished"
...
@troter
troter / gyazowin+.ini
Created October 9, 2011 08:20
MemocurialのGyazo機能
[gyazowin+]
upload_server=timedia.memocurial.com
upload_path=/gyazo?prefix=http:%2F%2Ftimedia.memocurial.com
@troter
troter / gist:1225257
Created September 18, 2011 16:47
mercurialの内部APIを利用してファイルのコンテンツをとる
import os
from mercurial import hg, ui
path = "/home/takumi/"
repo = hg.repository(ui.ui(), path)
ctx = repo['tip']
#print ctx.filectx('.zshenv').data()
mf = ctx.manifest()