Skip to content

Instantly share code, notes, and snippets.

@parzibyte
Created December 28, 2018 00:17
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 parzibyte/560caa4247017df4631ce4ed6ffb8847 to your computer and use it in GitHub Desktop.
Save parzibyte/560caa4247017df4631ce4ed6ffb8847 to your computer and use it in GitHub Desktop.
import os, sys
def resolver_ruta(ruta_relativa):
if hasattr(sys, '_MEIPASS'):
return os.path.join(sys._MEIPASS, ruta_relativa)
return os.path.join(os.path.abspath('.'), ruta_relativa)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment