Rev 9377 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 9377 | Rev 9379 | ||
---|---|---|---|
Line 1... | Line 1... | ||
1 | #!/usr/bin/python3 |
1 | #!/usr/bin/python3 |
2 | import os |
2 | import os |
3 | import sys |
3 | import sys |
4 | import shutil |
4 | import shutil |
Line -... | Line 5... | ||
- | 5 | ||
- | 6 | import workspace.build |
|
5 | 7 | ||
6 | if len(sys.argv) < 2 or sys.argv[1] != "--remove-everything": |
8 | if len(sys.argv) < 2 or sys.argv[1] != "--remove-everything": |
7 | print(f"Please call `{sys.argv[0]} --remove-everything` if you really want to remove all your workspace files") |
9 | print(f"Please call `{sys.argv[0]} --remove-everything` if you really want to remove all your workspace files") |
Line 8... | Line 10... | ||
8 | exit() |
10 | exit() |
9 | 11 | ||
Line 10... | Line 12... | ||
10 | # Remove workspace folder |
12 | # Remove workspace folder |
11 | shutil.rmtree("workspace", ignore_errors = True) |
13 | shutil.rmtree("workspace", ignore_errors = True) |
Line 12... | Line 14... | ||
12 | 14 | ||
- | 15 | # Remove tup database |
|
Line 13... | Line 16... | ||
13 | # Remove tup database |
16 | shutil.rmtree(".tup", ignore_errors = True) |
14 | shutil.rmtree(".tup", ignore_errors = True) |
17 | |
15 | 18 | # Make build.py remove the stuff it built |
|
16 | # TODO: Make build.py remove the stuff it built |
19 | workspace.build.clean() |