0
0
mirror of https://github.com/mongodb/mongo.git synced 2024-11-29 08:42:18 +01:00
mongodb/buildscripts/bb.py
2010-01-02 08:59:54 -05:00

24 lines
537 B
Python

# bb tools
import os
import re
def checkOk():
dir = os.getcwd()
m = re.compile( ".*/.*_V(\d+\.\d+)/mongo" ).findall( dir )
if len(m) == 0:
return
if len(m) > 1:
raise Exception( "unexpected: " + str(m) )
m = "v" + m[0]
print( m )
print( "excpted version [" + m + "]" )
from subprocess import Popen, PIPE
diff = Popen( [ "git", "diff", "origin/v1.2" ], stdout=PIPE ).communicate()[ 0 ]
if len(diff) > 0:
print( diff )
raise Exception( "build bot broken?" )