Skip to content

Instantly share code, notes, and snippets.

@swayson
Created October 16, 2016 06:11
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save swayson/2c5a613868a65fcc84887db12f3f2705 to your computer and use it in GitHub Desktop.
Save swayson/2c5a613868a65fcc84887db12f3f2705 to your computer and use it in GitHub Desktop.
Snippet to construct the absolute path of the directory, in which the currently executing script is located.
import os
os.path.dirname(os.path.realpath(__file__))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment