Wolfram: Get Script Path, Notebook Dir
Get file path of running script
$InputFileName
- the file path of the current running script.
Get Dir Path of Current Notebook
NotebookDirectory[]
- the directory of the current notebook.
$InputFileName
NotebookDirectory[]