2
4

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

Blenderの中のPythonでカレントディレクトリを知るには

Last updated at Posted at 2015-01-30

背景

OSXでFinderから起動した場合、一体どこがカレントディレクトリなのか
気になり調べた。

カレントディレクトリを知る

import os.path
print(os.path.abspath(os.path.dirname(".")))

dirnameのみだと、何も表示されない。
abspathを使うとフルパスで表示されるようになる。

関連投稿

関連記事

2
4
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
2
4

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?