I am using os.getcwd()
to get user current directory. I want to check whether a file is in Desktop folder or not. But getcwd()
function only returns
username directory, like this /Users/macbookair
, but I expect this:
/Users/macbookair/Desktop
I am using macOS Big Sur. Any help would be greatly appreciated. THanks