Marcel Taeumel uploaded a new version of ReleaseBuilder to project The Trunk:
http://source.squeak.org/trunk/ReleaseBuilder-mt.159.mcz ==================== Summary ==================== Name: ReleaseBuilder-mt.159 Author: mt Time: 17 August 2016, 10:22:45.937517 am UUID: 1920f248-643b-9a4a-b1c4-0affddce0911 Ancestors: ReleaseBuilder-mt.158 Clean-up in the release builder in preparation for the code freeze. =============== Diff against ReleaseBuilder-mt.158 =============== Item was added: + ----- Method: ReleaseBuilder class>>checkCurrentProjects (in category 'scripts - support') ----- + checkCurrentProjects + + Project current isMorphic ifFalse: [ + Warning signal: 'The current project is not Morphic. Please create a new Morphic project, enter it, and restart the release building process.']. + + Project allProjects size = 1 ifFalse: [ + Warning signal: 'There should only be one project.'].! Item was changed: + ----- Method: ReleaseBuilder class>>doNextStep (in category 'manual - steps') ----- - ----- Method: ReleaseBuilder class>>doNextStep (in category 'manual') ----- doNextStep "Use this call to perform the manual steps in the release process." | versionString | SystemVersion current isRelease ifTrue: [ ^ self inform: 'This is a release image. Please use a trunk image to prepare the next release']. versionString := SystemVersion current version. SystemVersion current isAlpha ifTrue: [^ self step1FeatureFreeze]. SystemVersion current isFeatureFreeze ifTrue: [^ self step2CodeFreeze]. SystemVersion current isReleaseCandidate ifTrue: [ "Still code freeze and another RC? Or do the release?" (UIManager default chooseFrom: #('Create next release candidate' 'Create next release' 'Do nothing') lines: #(2) title: versionString) in: [:answer | answer = 1 ifTrue: [^ self step3NextReleaseCandidate]. answer = 2 ifTrue: [^ self step4Release]]. ^ self].! Item was added: + ----- Method: ReleaseBuilder class>>ensureMorphicTopProject (in category 'scripts - support') ----- + ensureMorphicTopProject + + Project current isMorphic ifFalse: [ + Warning signal: 'The current project is not Morphic. A new Morphic project will be created and entered. Please restart the release building process after that.'. + MorphicProject new enter "current process terminates after this"].! Item was changed: ----- Method: ReleaseBuilder class>>prepareEnvironment (in category 'preparing') ----- prepareEnvironment "Prepare everything that should be done for a new image build. Clear caches, passwords, etc." "ReleaseBuilder prepareNewBuild" self + checkCurrentProjects; clearCaches; configureTools; setPreferences; configureDesktop. DeferredTask := [PreferenceWizardMorph new openInWorld]. "If you save-and-quit the image after calling #prepareEnvironment, ensure that the next image startup will be fast." Project current world doOneCycle.! Item was changed: ----- Method: ReleaseBuilder class>>prepareSourceCode (in category 'preparing') ----- prepareSourceCode "Update code. Remove foreign packages." MCMcmUpdater defaultUpdateURL: self buildRepository description. MCMcmUpdater updateMissingPackages: true. MCMcmUpdater enableUpdatesForAllPackages. + TestCase new ensureInternetConnectionTo: self buildRepository description. + + "Flush all caches. If a previous download failed this is often helpful" + MCFileBasedRepository flushAllCaches. - MCMcmUpdater default doUpdate: false. "non-interactive". + [MCMcmUpdater default doUpdate: false. "non-interactive"] + on: MCEmptyVersion do: [:warning | warning resume]. + self unloadForeignPackages; checkForDirtyPackages; loadWellKnownPackages; checkForUndeclaredSymbols. Compiler recompileAll.! Item was changed: + ----- Method: ReleaseBuilder class>>requestNextReleaseVersion (in category 'manual') ----- - ----- Method: ReleaseBuilder class>>requestNextReleaseVersion (in category 'manual - steps') ----- requestNextReleaseVersion "self requestNextReleaseVersion" | nextMinor nextMajor current | current := { SystemVersion current majorVersionNumber. SystemVersion current minorVersionNumber}. nextMinor := { current first. current second + 1}. nextMajor := { current first + 1. 0}. (UIManager default chooseFrom: { '{1}.{2}' format: {nextMinor first. nextMinor second}. '{1}.{2}' format: {nextMajor first. nextMajor second}} title: 'Please Choose Next Version') in: [:answer | answer ifNil: [^ self requestNextReleaseVersion]. answer = 1 ifTrue: [ NextMinorVersion := nextMinor second]. answer = 2 ifTrue: [ NextMajorVersion := nextMajor first. NextMinorVersion := 0]].! Item was added: + ----- Method: ReleaseBuilder class>>saveAsNewRelease (in category 'saving') ----- + saveAsNewRelease + "Use this to create a new release image to be used in the automated release artifact building process on http://www.github.com/squeak-smalltalk/squeak-app." + + | fileName | + self setNewSystemVersion: self versionString. + + fileName := ('squeak-{1}.{2}{3}' format: { + SystemVersion current majorVersionNumber. + SystemVersion current minorVersionNumber. + self releaseLocally ifTrue: ['-offline'] ifFalse: ['']}). + Smalltalk saveAs: fileName. + + "Update the image state." + self + prepareSourceCode; + prepareEnvironment; + switchToNewRepository: self releaseRepository; + addAdditionalRepositories. + + Smalltalk condenseChanges. + Smalltalk snapshot: true "Important!!" andQuit: true.! Item was changed: ----- Method: ReleaseBuilder class>>saveAsNewTrunk (in category 'saving') ----- saveAsNewTrunk + "Use this to create a new release image to be used in the automated release artifact building process on http://www.github.com/squeak-smalltalk/squeak-app." - "Use this to create a new trunk image to be used by smalltalkCI." | fileName | fileName := ('squeak-trunk{1}' format: { self releaseLocally ifTrue: ['-offline'] ifFalse: ['']}). + Smalltalk saveAs: fileName. + self - [ self - setTopProject; prepareSourceCode; prepareEnvironment; switchToNewRepository: self buildRepository. - ] on: MCEmptyVersion do: [:warning | warning resume]. - - Smalltalk saveAs: fileName. Smalltalk condenseChanges. Smalltalk snapshot: true "Important!!" andQuit: true.! Item was changed: ----- Method: ReleaseBuilder class>>setNewSystemVersion: (in category 'manual') ----- setNewSystemVersion: version self class compile: (self initializeTemplate format: {version}) classified: 'class initialization'. self initialize. + self assert: self versionString = SystemVersion current version. + SystemVersion current isRelease ifFalse: [ + self inform: ('You just changed the system version to {1}.\Please upload the changed ''ReleaseBuilder'' package to\\ {2}\\so that this version change will be official.' translated withCRs format: {SystemVersion current version. self buildRepository description})].! - SystemVersion current isRelease - ifFalse: [self uploadNewSystemVersion].! Item was changed: ----- Method: ReleaseBuilder class>>setPreferences (in category 'scripts') ----- setPreferences "Preferences class defaultValueTableForCurrentRelease" " Preferences outOfTheBox." "<-- uncomment after #defaultValueTableForCurrentRelease is fixed up." "General User interaction" Preferences enable: #generalizedYellowButtonMenu ; enable: #swapMouseButtons; disable: #mouseOverForKeyboardFocus. Morph indicateKeyboardFocus: true. Project uiManager openToolsAttachedToMouseCursor: false. SearchBar useScratchPad: false. HandMorph sendMouseWheelToKeyboardFocus: false. HandMorph synthesizeMouseWheelEvents: true. "Text input." TextEditor autoEnclose: true ; autoIndent: true ; encloseSelection: false ; destructiveBackWord: false ; blinkingCursor: true ; dumbbellCursor: false. PluggableTextMorph simpleFrameAdornments: false. "Windows" SystemWindow reuseWindows: false. SystemWindow windowsRaiseOnClick: true. SystemWindow windowTitleActiveOnFirstClick: true. Model windowActiveOnFirstClick: false. "Not good for little screen real estate." Model useColorfulWindows: false. Preferences disable: #showSplitterHandles; disable: #fastDragWindowForMorphic. CornerGripMorph drawCornerResizeHandles: false; passiveColor: (Color gray: 0.85); activeColor: (Color r: 1 g: 0.599 b: 0.0). ProportionalSplitterMorph smartHorizontalSplitters: false ; smartVerticalSplitters: false. "Scroll bars." Preferences enable: #scrollBarsNarrow; enable: #scrollBarsOnRight; enable: #alwaysHideHScrollbar; disable: #alwaysShowHScrollbar; disable: #alwaysShowVScrollbar. ScrollBar scrollBarsWithoutArrowButtons: true; scrollBarsWithoutMenuButton: true. ScrollPane useRetractableScrollBars: false. "Rounded corners." Morph preferredCornerRadius: 8. SystemWindow roundedWindowCorners: false. DialogWindow roundedDialogCorners: false. MenuMorph roundedMenuCorners: false. PluggableButtonMorph roundedButtonCorners: false. ScrollBar roundedScrollBarLook: false. "Gradients." SystemWindow gradientWindow: false. DialogWindow gradientDialog: false. MenuMorph gradientMenu: false. PluggableButtonMorph gradientButton: false. ScrollBar gradientScrollBar: false. "Shadows" Preferences enable: #menuAppearance3d. Morph useSoftDropShadow: true. "Lists and Trees" PluggableListMorph filterableLists: true; clearFilterAutomatically: false; highlightHoveredRow: true; menuRequestUpdatesSelection: true. PluggableTreeMorph filterByLabelsOnly: false; maximumSearchDepth: 1. "Standard Tools" Workspace shouldStyle: false. Browser listClassesHierarchically: true; showClassIcons: true; showMessageIcons: true; sortMessageCategoriesAlphabetically: true. Preferences enable: #annotationPanes; enable: #optionalButtons; + disable: #diffsWithPrettyPrint; - enable: #diffsWithPrettyPrint; enable: #traceMessages; enable: #alternativeBrowseIt; enable: #menuWithIcons; enable: #visualExplorer. SystemNavigation thoroughSenders: true. Preferences disable: #debugLogTimestamp. "Halo" Preferences enable: #showBoundsInHalo ; disable: #alternateHandlesLook. "System" NetNameResolver enableIPv6: false. Scanner allowUnderscoreAsAssignment: true; prefAllowUnderscoreSelectors: true. "that's all, folks"! Item was changed: ----- Method: ReleaseBuilder class>>step4Release (in category 'manual - steps') ----- step4Release "Creates the release. New file, clean-ed up." (UIManager default confirm: ('Do you want release {1}{2}?' withCRs format: { self versionString. (self releaseLocally ifTrue: [' locally'] ifFalse: [''])}) title: 'Release Builder Step 4 of 4: The Release') ifFalse: [^ self]. "If you re-open the current trunk image again, it will be an alpha version for the next release." DeferredTask := [self step0AssureAlpha]. "We continue with preparing the release image." + NextTask := [self saveAsNewRelease]. - NextTask := [self step5DoRelease]. "Now save it but do not quit." Smalltalk snapshot: true andQuit: false.! Item was removed: - ----- Method: ReleaseBuilder class>>step5DoRelease (in category 'manual - steps') ----- - step5DoRelease - "Creates the release. New file, clean-ed up." - - | fileName | - - "Create new .image and .changes files for the release image." - self setNewSystemVersion: self versionString. - fileName := ('squeak-{1}.{2}{3}' format: { - SystemVersion current majorVersionNumber. - SystemVersion current minorVersionNumber. - self releaseLocally ifTrue: ['-offline'] ifFalse: ['']}). - Smalltalk saveAs: fileName. - - "Update the image state." - [ self - setTopProject; - prepareSourceCode; - prepareEnvironment; - switchToNewRepository: self releaseRepository. - ] on: MCEmptyVersion do: [:warning | warning resume]. - - NextTask := [self uploadForSmalltalkCI: fileName.]. - - Smalltalk condenseChanges. - Smalltalk snapshot: true "Important!!" andQuit: false. - "Finished. See NextTask."! Item was removed: - ----- Method: ReleaseBuilder class>>uploadForSmalltalkCI: (in category 'manual') ----- - uploadForSmalltalkCI: fileName - "TODO Automate upload." - - self releaseLocally ifTrue: [ - ^ UserDialogBoxMorph - inform: ('Please do never upload images that are meant to be used locally.') - title: 'Release Builder - Local Release Finished'.]. - - UserDialogBoxMorph - inform: ('Please upload {1] and {2} to files.squeak.org/smalltalkCI' format: {fileName, '.image'. fileName, '.changes'}) - title: 'Release Builder - Almost Done'.! |
Free forum by Nabble | Edit this page |