Skip to content

Instantly share code, notes, and snippets.

@mktakuya
Created March 11, 2014 04:45
Show Gist options
  • Save mktakuya/9479650 to your computer and use it in GitHub Desktop.
Save mktakuya/9479650 to your computer and use it in GitHub Desktop.
# -*- coding:utf-8 -*- # Pythonスタートアップ import readline import rlcompleter import atexit import os # タブ補完 readline.parse_and_bind('tab: complete') # ヒストリーファイル histfile = os.path.join(os.environ['HOME'], '.pythonhistory') try: readline.read_history_file(histfile) except IOError: pass atexit.register(readline.write_history_file, histfile) del os, h…
# -*- coding:utf-8 -*-
# Pythonスタートアップ
import readline
import rlcompleter
import atexit
import os
# タブ補完
readline.parse_and_bind('tab: complete')
# ヒストリーファイル
histfile = os.path.join(os.environ['HOME'], '.pythonhistory')
try:
readline.read_history_file(histfile)
except IOError:
pass
atexit.register(readline.write_history_file, histfile)
del os, histfile, readline, rlcompleter, atexit
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment