'From etoys3.0 of 19 February 2008 [latest update: #1953] on 1 April 2008 at 12:36:02 pm'! "Change Set: MoveMODir2-bf Date: 1 April 2008 Author: Bert Freudenberg Ticket #6212. One more place to change 'lang' to 'locale'"! !SugarLauncher methodsFor: 'bundling' stamp: 'bf 4/1/2008 12:35'! bundle: aFileName as: aBundleName title: aTitle version: aVersion id: aBundleID icon: anSVGIcon "Create a ZIP file named aBundleName-aVersion.xo containing aBundleName.activity/ aFileName bin/etoys-launch activity/activity.info activity/aBundleName-icon.svg locale/... " | dir archive fileAttr execAttr dirAttr localFileName scriptName | fileAttr := 16r81A4. execAttr := 16r81ED. dirAttr := 16r41ED. dir := aBundleName, '.activity/'. localFileName := FileDirectory localNameFor: aFileName. scriptName := aBundleName, '.sh'. archive := ZipArchive new. #('' 'bin' 'activity' 'locale') do: [:dirName | (archive addDirectory: dir, dirName) unixFileAttributes: dirAttr]. (archive addFile: aFileName as: dir, localFileName) unixFileAttributes: fileAttr. (archive addString: (self bundleScript: localFileName) as: dir, 'bin/', scriptName) unixFileAttributes: execAttr. (archive addString: (self bundleInfoTitle: aTitle version: aVersion bundle: aBundleID script: scriptName icon: aBundleName, '-icon') as: dir, 'activity/activity.info') unixFileAttributes: fileAttr. (archive addString: self bundleIcon as: dir, 'activity/', aBundleName, '-icon.svg') unixFileAttributes: fileAttr. archive members do: [:m | m setLastModFileDateTimeFrom: Time totalSeconds]. archive writeToFileNamed: aBundleName, '-', aVersion asString, '.xo'. archive close.! !