from gui import simpleMode
from gui import icon
from util import profile
+from util import version
def main():
app = wx.App(False)
class mainWindow(configBase.configWindowBase):
"Main user interface window"
def __init__(self):
- super(mainWindow, self).__init__(title='Cura')
+ super(mainWindow, self).__init__(title='Cura - ' + version.getVersion())
wx.EVT_CLOSE(self, self.OnClose)
#self.SetIcon(icon.getMainIcon())
from gui import printWindow
from gui import icon
from util import profile
+from util import version
class simpleModeWindow(configBase.configWindowBase):
"Main user interface window for simple mode"
def __init__(self):
- super(simpleModeWindow, self).__init__(title='Cura - Simple mode')
+ super(simpleModeWindow, self).__init__(title='Cura - Simple mode - ' + version.getVersion())
wx.EVT_CLOSE(self, self.OnClose)
#self.SetIcon(icon.getMainIcon())
--- /dev/null
+from __future__ import absolute_import
+import __init__
+
+import os
+
+def getVersion():
+ gitPath = os.path.abspath(os.path.join(os.path.split(os.path.abspath(__file__))[0], "../../.git"))
+ versionFile = os.path.abspath(os.path.join(os.path.split(os.path.abspath(__file__))[0], "../version"))
+ if os.path.exists(gitPath):
+ f = open(gitPath + "/refs/heads/master", "r")
+ version = f.readline()
+ f.close()
+ return version.strip()
+ if os.path.exists(versionFile):
+ f = open(versionFile, "r")
+ version = f.readline()
+ f.close()
+ return version.strip()
+ return "?"
+
+if __name__ == '__main__':
+ print getVersion()
+
##Do we need to create the final archive
ARCHIVE_FOR_DISTRIBUTION=1
##Which version name are we appending to the final archive
-BUILD_NAME=RC1
+BUILD_NAME=RC2
TARGET_DIR=${BUILD_TARGET}-Cura-${BUILD_NAME}
##Which versions of external programs to use
#Cleanup pypy
rm -rf ${TARGET_DIR}/pypy/lib-python/2.7/test
-#add Skeinforge
+#add Cura
cp -a Cura ${TARGET_DIR}/Cura
+#Add cura version file
+echo $BUILD_NAME > ${TARGET_DIR}/Cura/version
#add printrun
cp -a Printrun ${TARGET_DIR}/Printrun