Skip to content

Instantly share code, notes, and snippets.

@Spyder-0
Created March 23, 2023 07:24
Show Gist options
  • Save Spyder-0/cd1a60c9f79c622e21b0a9569912850b to your computer and use it in GitHub Desktop.
Save Spyder-0/cd1a60c9f79c622e21b0a9569912850b to your computer and use it in GitHub Desktop.
Change Current Working Directory to Location of File.
import os
# Changes Directory to Where the File is Saved.
os.chdir(os.path.dirname(os.path.abspath(__file__)))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment