Skip to content

Instantly share code, notes, and snippets.

View KengoSawa2's full-sized avatar
💭
I don’t want to work forever :)

Kengo Sawatsu KengoSawa2

💭
I don’t want to work forever :)
View GitHub Profile
@nobonobo
nobonobo / Py2AppTips.rst
Last active June 21, 2016 02:54
メモ:py2appのコツ

Py2AppのTips

  • 直接import記述していないパッケージが取り込まれない場合がある。
  • 動作するときのsys.modulesと動作しない時のsys.modulesをよく見比べましょう。
  • pngだろうがなんだろうが、「tiff2icns」でicnsファイルは作れる。
  • OS-X内蔵Pythonはアプリ内に複製できない(py2appの仕様)ので、別途Pythonをインストールする必要がある。 (portsサンプル多いが、brewでもできたー。)

for PyQt or PySide

@t-nissie
t-nissie / delxattr.py
Last active June 6, 2016 02:37
Mac OS Xとかでファイルとディレクトリの拡張属性xattrを再帰的にすべて消す高速なPythonスクリプトdelxattr.py
#!/usr/bin/env python
# delxattr.py recursively removes all extended attributes (xattr) from
# all files and directories under the current or given directory.
# In the latest Mac OS X, you can do the same thing with "xattr -rc".
# See a help of xattr with "xattr -h".
# Author: Takeshi NISHIMATSU
# Gist: https://gist.github.com/t-nissie/8491009
# Example1$ delxattr.py
# Example2$ delxattr.py ../foo
# Example3$ delxattr.py ~/foo