Created
July 16, 2020 14:02
-
-
Save lucascheung/932948d8f66d4ceb53b76038a3b4e948 to your computer and use it in GitHub Desktop.
all files in a directory to list
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from os import listdir | |
from os.path import isfile, join | |
onlyfiles = [f for f in listdir(mypath) if isfile(join(mypath, f))] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment