Merge pull request #2733 from jonpas/fixSQFvalidatorWithoutPythonArg

Add shebang line to specify python version to SQF validator
This commit is contained in:
Glowbal 2015-10-11 23:24:49 +02:00
commit ecafbb0242

View File

@ -1,3 +1,4 @@
#!/usr/bin/env python3
import fnmatch
import os
@ -149,11 +150,11 @@ def main():
args = parser.parse_args()
# Allow running from root directory as well as from inside the tools directory
rootDir = "../addons"
rootDir = "..\\addons"
if (os.path.exists("addons")):
rootDir = "addons"
for root, dirnames, filenames in os.walk(rootDir + '/' + args.module):
for root, dirnames, filenames in os.walk(rootDir + '\\' + args.module):
for filename in fnmatch.filter(filenames, '*.sqf'):
sqf_list.append(os.path.join(root, filename))