Created
January 2, 2018 22:45
-
-
Save Fusion86/4d394d77f2841b0aeaf23ed7300bf403 to your computer and use it in GitHub Desktop.
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
import glob | |
f = open(".stignore", "w") | |
for filepath in glob.iglob("**/.stignore", recursive=True): | |
# Ignore top-level .stignore, because that is the one we are generating | |
if filepath != ".stignore": | |
unixpath = filepath.replace('\\', '/') # Use Unix like filepaths | |
f.write(f"#include {unixpath}\n") | |
print(f"Added '{unixpath}' to the ignore file") | |
f.close() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment