I keep getting myself in knots when I am manipulating paths and file names because I don’t follow a naming standard for path components.
Consider the following toy pr
A) foo
filename without extension
B) foo.src
filename
C) src
extension without dot
D) .src
extension
E) C:\users\OddThinking\Documents\My Source\ - i.e. the top of the tree.
[absolute] (working | current | active | root) directory path
F) Widget\foo.src - i.e. the path from the top of the tree to the leaf.
relative file path
G) Widget - i.e. one node of the tree.
directory name
H) C:\users\OddThinking\Documents\My Source\Widget\ - i.e. the name of the folder
[absolute] directory path
I) C:\users\OddThinking\Documents\My Source\Widget\foo.src
[absolute] file path
"Filename" is a word, so generally we should probably use "filename" and not "file name" (and Filename not FileName).
We're working at a lower level, so we should probably call them directories and not folders, but either would be ok if you were consistent.