logPath = "./build.log"
if __name__ == "__main__":
- if len(sys.argv) == 1:
- print("Execute with a PR number")
- print(" ~$ python main.py [PR Number]")
+ if len(sys.argv) < 3:
+ print("Execute with token and the PR number")
+ print(" ~$ python main.py [Token] [PR Number]")
exit(1)
logs = BuildLog(logPath)
- pr = PRManager(int(sys.argv[1]))
+ pr = PRManager(sys.argv[1], int(sys.argv[2]))
warningsInFile = []
for file in pr.changedFiles:
warningsInFile = [warning for warning in logs.warnings if file.filename.endswith(warning[logs.FILE])]