-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild_rules.py
62 lines (44 loc) · 1.73 KB
/
build_rules.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
#!/usr/bin/env python
# -*- coding: utf-8 -*-
"""
Copy the GLSL visual studio plugin to sdks/visualstudio
Copyright 1995-2022 by Rebecca Ann Heineman [email protected]
It is released under an MIT Open Source license. Please see LICENSE
for license details. Yes, you can use it in a
commercial title without paying anything, just give me a credit.
Please? It's not like I'm asking you for money!
"""
from __future__ import absolute_import, unicode_literals
import os
import sys
from burger import clean_directories, clean_files
# ``cleanme`` will process any child directory with the clean() function if
# True.
CLEANME_GENERIC = True
# ``cleanme`` will assume only the function ``clean()`` is used if True.
CLEANME_PROCESS_PROJECT_FILES = False
# Process listed folders using their rules before processing this folder.
DEPENDENCIES = ['stripcomments', 'install_pre_2017', 'install_2017',
'install_2019', 'install_2022']
########################################
def clean(working_directory):
"""
Delete temporary files.
This function is called by ``cleanme`` to remove temporary files.
On exit, return 0 for no error, or a non zero error code if there was an
error to report.
Args:
working_directory
Directory this script resides in.
Returns:
None if not implemented, otherwise an integer error code.
"""
clean_directories(
working_directory,
('bin', 'temp', 'obj', 'Properties', '.vs', '.vscode', 'build'))
clean_files(working_directory,
('Key.snk', '*.user', '*.suo', '*.msi'), True)
return 0
# If called as a command line and not a class, perform the build
if __name__ == "__main__":
sys.exit(clean(os.path.dirname(os.path.abspath(__file__))))