diff --git a/Admin Classes/KajuFile.xojo_code b/Admin Classes/KajuFile.xojo_code index 3a1df29..f8b6119 100644 --- a/Admin Classes/KajuFile.xojo_code +++ b/Admin Classes/KajuFile.xojo_code @@ -20,6 +20,8 @@ Protected Class KajuFile #tag Method, Flags = &h0 Sub ExportTo(fileOrFolder As FolderItem) + Validate() + dim data as JSONItem = DataToJSON data.Compact = false data.EscapeSlashes = false @@ -148,6 +150,8 @@ Protected Class KajuFile #tag Method, Flags = &h0 Sub SaveTo(f As FolderItem) + Validate() + dim master as JSONItem = ToJSON master.Compact = false @@ -171,6 +175,21 @@ Protected Class KajuFile End Sub #tag EndMethod + #tag Method, Flags = &h21 + Private Sub Validate() + // + // Make sure there are no duplicate versions + // + for i as integer = 0 to KajuData.Ubound + dim version as Kaju.UpdateInformation = KajuData( i ) + if IndexOf( version.Version ) <> i then + raise new KajuException( "Duplicate version numbers", CurrentMethodName ) + end if + next + + End Sub + #tag EndMethod + #tag ComputedProperty, Flags = &h0 #tag Getter diff --git a/Kaju Admin App/Kaju Admin.xojo_project b/Kaju Admin App/Kaju Admin.xojo_project index 24cb751..d1269f4 100644 --- a/Kaju Admin App/Kaju Admin.xojo_project +++ b/Kaju Admin App/Kaju Admin.xojo_project @@ -30,12 +30,12 @@ Class=KajuFile;../Admin Classes/KajuFile.xojo_code;&h1A7FF7FF;&h0;false AppMenuBar=MainMenuBar MajorVersion=1 MinorVersion=6 -SubVersion=0 +SubVersion=1 NonRelease=0 Release=3 InfoVersion=Kaju Admin -LongVersion=v.1.6 -ShortVersion=1.6 +LongVersion=v.1.6.1 +ShortVersion=1.6.1 WinCompanyName=MacTechnologies Consulting WinInternalName= WinProductName= diff --git a/Kaju Admin App/WndAdmin.xojo_window b/Kaju Admin App/WndAdmin.xojo_window index abad2be..32daa06 100644 --- a/Kaju Admin App/WndAdmin.xojo_window +++ b/Kaju Admin App/WndAdmin.xojo_window @@ -2477,6 +2477,10 @@ End r = true ContentsChanged = false + Exception err as KajuException + self.ContentsChanged= savedContentsChanged + ShowValidationError "Save failed!", err + Exception err as IOException self.ContentsChanged = savedContentsChanged MsgBox "Save failed!" @@ -2685,6 +2689,18 @@ End End Sub #tag EndMethod + #tag Method, Flags = &h21 + Private Sub ShowValidationError(msg As String, err As RuntimeException) + dim mdlg as new MessageDialog + mdlg.Message = msg + mdlg.Explanation = err.Message + mdlg.CancelButton.Visible = false + + call mdlg.ShowModalWithin self + + End Sub + #tag EndMethod + #tag Method, Flags = &h21 Private Sub StoreFieldsToVersionRow() if LastVersionRow = -1 or LastVersionRow >= lbVersions.ListCount then @@ -3207,9 +3223,17 @@ End MyKajuFile.ExportTo( f ) + Exception err as KajuException + ShowValidationError "Could not export data.", err + Exception err As RuntimeException + if err isa EndException or err isa ThreadEndException then + raise err + end if + MsgBox "Could not export data." + End Sub #tag EndEvent #tag EndEvents diff --git a/Kaju Admin CLI/App.xojo_code b/Kaju Admin CLI/App.xojo_code index 17354e4..56c50d1 100644 --- a/Kaju Admin CLI/App.xojo_code +++ b/Kaju Admin CLI/App.xojo_code @@ -3,6 +3,8 @@ Protected Class App Inherits ConsoleApplication #tag Event Function Run(args() as String) As Integer + dim errCode as integer = kErrorNoError + RegisterSubApps dim caller as string = args( 0 ) @@ -28,66 +30,69 @@ Inherits ConsoleApplication if args.Ubound = 0 or parser.HelpRequested then PrintMainHelp parser - return kErrorNoError - end if - - // - // Adjust the args - // - for i as integer = 0 to appArgs.Ubound - args.Remove 0 - next - - // - // The first argument must be the subapp name - // - dim subappKey as string = args( 0 ) - dim subapp as SubApplication = SubAppDictionary.Value( subappKey ) - - // - // Substitute the caller for the subapp name - // - args( 0 ) = caller - - // - // Get the options - // - dim subappParser as new OptionParser( subappKey, "" ) - subapp.AddOptions subappParser - subappParser.Parse args - - if subappParser.HelpRequested then - PrintSubAppHelp( subappKey, subapp, subappParser ) - return kErrorNoError - end if - - // - // Get the admin file - // - dim adminFile as FolderItem = parser.FileValue( kOptionFile ) - if adminFile is nil then - print "No admin file specified" - return kErrorGeneralError - end if - - dim r as integer - try - r = subapp.Execute( adminFile, subappParser ) - catch err as RuntimeException - if err isa EndException or err isa ThreadEndException then - raise err - end if - print "Unexpected error: " + err.Message - r = kErrorGeneralError - end try + else + + // + // Adjust the args + // + for i as integer = 0 to appArgs.Ubound + args.Remove 0 + next + + // + // The first argument must be the subapp name + // + dim subappKey as string = args( 0 ) + dim subapp as SubApplication = SubAppDictionary.Value( subappKey ) + + // + // Substitute the caller for the subapp name + // + args( 0 ) = caller + + // + // Get the options + // + dim subappParser as new OptionParser( subappKey, "" ) + subapp.AddOptions subappParser + subappParser.Parse args + + if subappParser.HelpRequested then + PrintSubAppHelp( subappKey, subapp, subappParser ) + + else + + // + // Get the admin file + // + dim adminFile as FolderItem = parser.FileValue( kOptionFile ) + if adminFile is nil then + print "No admin file specified" + errCode = kErrorGeneralError + + else + try + errCode = subapp.Execute( adminFile, subappParser ) + catch err as RuntimeException + if err isa EndException or err isa ThreadEndException then + raise err + end if + + print "Unexpected error: " + err.Message + errCode = kErrorGeneralError + end try + end if + + end if + end if #if DebugBuild and TargetRemoteDebugger then print "Press return to continue..." call input #endif - return r + return errCode End Function #tag EndEvent diff --git a/Kaju Admin CLI/Kaju Admin CLI.xojo_project b/Kaju Admin CLI/Kaju Admin CLI.xojo_project index 7586958..8eaf69e 100644 --- a/Kaju Admin CLI/Kaju Admin CLI.xojo_project +++ b/Kaju Admin CLI/Kaju Admin CLI.xojo_project @@ -1,5 +1,5 @@ Type=Console -RBProjectVersion=2015.023 +RBProjectVersion=2015.024 MinIDEVersion=20070100 Class=App;App.xojo_code;&h31FD87FF;&h0;false Module=FormatCodePreferences;FormatCodePreferences.xojo_code;&h2977F6F1;&h0;false @@ -34,12 +34,12 @@ Class=OptionParserException;../Other Classes/OptionParser/OptionParserException. Class=OptionUnrecognizedKeyException;../Other Classes/OptionParser/OptionUnrecognizedKeyException.xojo_code;&h12104F75;&h797A37FF;false MajorVersion=1 MinorVersion=6 -SubVersion=0 +SubVersion=1 NonRelease=0 Release=3 InfoVersion= -LongVersion=v.1.6 -ShortVersion=1.6 +LongVersion=v.1.6.1 +ShortVersion=1.6.1 WinCompanyName=MacTechnologies Consulting WinInternalName=kaju WinProductName=Kaju CLI diff --git a/Kaju Admin CLI/Sub Applications/AddVersionApp.xojo_code b/Kaju Admin CLI/Sub Applications/AddVersionApp.xojo_code index 426ec47..0180ba3 100644 --- a/Kaju Admin CLI/Sub Applications/AddVersionApp.xojo_code +++ b/Kaju Admin CLI/Sub Applications/AddVersionApp.xojo_code @@ -27,8 +27,17 @@ Inherits VersionHandlerSubApplication #pragma unused version #pragma unused saveFile - dim appName as string = options.StringValue( kOptionAppName ) - dim versionString as string = options.StringValue( kOptionVersion ) + dim appName as string = options.StringValue( kOptionAppName ).Trim + if appName = "" then + print "App name must be specified" + return App.kErrorGeneralError + end if + + dim versionString as string = options.StringValue( kOptionVersion ).Trim + if file.IndexOf( versionString ) <> -1 then + print "Version " + versionString + " already exists" + return App.kErrorGeneralError + end if dim u as new Kaju.UpdateInformation u.Version = versionString diff --git a/Kaju Admin CLI/Sub Applications/EditVersionApp.xojo_code b/Kaju Admin CLI/Sub Applications/EditVersionApp.xojo_code index 5a85c58..b559b42 100644 --- a/Kaju Admin CLI/Sub Applications/EditVersionApp.xojo_code +++ b/Kaju Admin CLI/Sub Applications/EditVersionApp.xojo_code @@ -168,6 +168,15 @@ Inherits VersionHandlerSubApplication end if else // Just a key + + // + // If the key is version, make sure it's not a duplicate + // + if key = "version" and value.Trim <> version.Version.Trim and file.IndexOf( value ) <> -1 then + print "Can't set Version to " + value + " since that version already exists" + return App.kErrorGeneralError + end if + try version.SetByName( key ) = value keyFound = true diff --git a/Kaju Admin CLI/Sub Applications/ListVersionsApp.xojo_code b/Kaju Admin CLI/Sub Applications/ListVersionsApp.xojo_code index 067ed8f..7dad2c2 100644 --- a/Kaju Admin CLI/Sub Applications/ListVersionsApp.xojo_code +++ b/Kaju Admin CLI/Sub Applications/ListVersionsApp.xojo_code @@ -8,6 +8,14 @@ Inherits FileHandlerSubApplication o.AddAllowedValue "cr", "lf", "crlf", "null" parser.AddOption o + + o = new Option( "", kOptionInclude, "Include versions matching this regex pattern (can use more than one)", Option.OptionType.String ) + o.IsArray = true + parser.AddOption o + + o = new Option( "", kOptionExclude, "Exclude versions matching this regex pattern (can use more than one)", Option.OptionType.String ) + o.IsArray = true + parser.AddOption o End Sub #tag EndEvent @@ -28,10 +36,50 @@ Inherits FileHandlerSubApplication Function Run(file As KajuFile, adminFile As FolderItem, options As OptionParser) As Integer #pragma unused adminFile + dim includeOption as Option = options.OptionValue( kOptionInclude ) + dim excludeOption as Option = options.OptionValue( kOptionExclude ) + + dim emptyArray() as variant + + dim includers() as variant = if( includeOption.Value.IsNull, emptyArray, options.OptionValue( kOptionInclude ).Value ) + dim excluders() as variant = if( excludeOption.Value.IsNull, emptyArray, options.OptionValue( kOptionExclude ).Value ) + + dim rxInclude as RegEx + if includers.Ubound <> -1 then + dim patterns() as string + for each pattern as string in includers + patterns.Append pattern + next + + rxInclude = new RegEx + rxInclude.SearchPattern = "(?:" + join( patterns, ") | (?:" ) + ")" + end if + + dim rxExclude as RegEx + if excluders.Ubound <> -1 then + dim patterns() as string + for each pattern as string in excluders + patterns.Append pattern + next + + rxExclude = new RegEx + rxExclude.SearchPattern = "(?:" + join( patterns, ") | (?:" ) + ")" + end if + dim versions() as string for i as integer = 0 to file.KajuData.Ubound dim data as Kaju.UpdateInformation = file.KajuData( i ) - versions.Append data.Version + dim version as string = data.Version + + select case true + case rxInclude isa RegEx and rxInclude.Search( version ) is nil + // Skip it + case rxExclude isa RegEx and rxExclude.Search( version ) isa RegExMatch + // Skip it + + case else + versions.Append version + end select next dim eol as string = options.StringValue( kOptionEOL, "" ) @@ -63,6 +111,12 @@ Inherits FileHandlerSubApplication #tag Constant, Name = kOptionEOL, Type = String, Dynamic = False, Default = \"eol", Scope = Private #tag EndConstant + #tag Constant, Name = kOptionExclude, Type = String, Dynamic = False, Default = \"exclude", Scope = Private + #tag EndConstant + + #tag Constant, Name = kOptionInclude, Type = String, Dynamic = False, Default = \"include", Scope = Private + #tag EndConstant + #tag ViewBehavior #tag ViewProperty diff --git a/Kaju Classes/Kaju.xojo_code b/Kaju Classes/Kaju.xojo_code index a79f09d..b41d86c 100644 --- a/Kaju Classes/Kaju.xojo_code +++ b/Kaju Classes/Kaju.xojo_code @@ -382,7 +382,7 @@ Protected Module Kaju #tag Constant, Name = kUpdatePacketMarker, Type = String, Dynamic = False, Default = \"KAJU ", Scope = Protected #tag EndConstant - #tag Constant, Name = Version, Type = String, Dynamic = False, Default = \"1.6", Scope = Protected + #tag Constant, Name = Version, Type = String, Dynamic = False, Default = \"1.6.1", Scope = Protected #tag EndConstant diff --git a/Kaju Update Test v1.kaju b/Kaju Update Test v1.kaju index 74b15e0..fd9db3f 100644 --- a/Kaju Update Test v1.kaju +++ b/Kaju Update Test v1.kaju @@ -7,12 +7,12 @@ "AppName":"Kaju Update Test", "ImageURL":"", "LinuxBinary":{ - "Hash":"921DAF87E4CE227BB36FCE64A88EC887", + "Hash":"AC1BF5FA7B0421312D99936A1BFDCA7A", "URL":"http:\/\/www.mactechnologies.com\/Kaju_Test\/Kaju_Update_Test_Linux.zip", "ExecutableName":"Kaju Update Test" }, "MacBinary":{ - "Hash":"580E5E1739AACA02BC6436DF41D3C960", + "Hash":"F98AF211715DAA489A321D1CDE3E770E", "URL":"http:\/\/www.mactechnologies.com\/Kaju_Test\/Kaju_Update_Test_Mac.zip" }, "MinimumRequiredVersion":"", @@ -21,7 +21,7 @@ "UseTransparency":false, "Version":"1.1 (10)", "WindowsBinary":{ - "Hash":"70027AF7061DC79F56A6C5CD93C4C95E", + "Hash":"4A9BB6DC9D5859D6B7C34BBB184EE23B", "URL":"http:\/\/www.mactechnologies.com\/Kaju_Test\/Kaju_Update_Test_Win.zip", "ExecutableName":"Kaju Update Test.exe" } @@ -30,12 +30,12 @@ "AppName":"New Kaju Update Test", "ImageURL":"", "LinuxBinary":{ - "Hash":"921DAF87E4CE227BB36FCE64A88EC887", + "Hash":"AC1BF5FA7B0421312D99936A1BFDCA7A", "URL":"http:\/\/www.mactechnologies.com\/Kaju_Test\/Kaju_Update_Test_Linux.zip", "ExecutableName":"Kaju Update Test" }, "MacBinary":{ - "Hash":"580E5E1739AACA02BC6436DF41D3C960", + "Hash":"F98AF211715DAA489A321D1CDE3E770E", "URL":"http:\/\/www.mactechnologies.com\/Kaju_Test\/Kaju_Update_Test_Mac.zip" }, "MinimumRequiredVersion":"", @@ -44,7 +44,7 @@ "UseTransparency":false, "Version":"1.2.2d5", "WindowsBinary":{ - "Hash":"70027AF7061DC79F56A6C5CD93C4C95E", + "Hash":"4A9BB6DC9D5859D6B7C34BBB184EE23B", "URL":"http:\/\/www.mactechnologies.com\/Kaju_Test\/Kaju_Update_Test_Win.zip", "ExecutableName":"Kaju Update Test.exe" } @@ -53,12 +53,12 @@ "AppName":"Kaju Update Test", "ImageURL":"", "LinuxBinary":{ - "Hash":"921DAF87E4CE227BB36FCE64A88EC887", + "Hash":"AC1BF5FA7B0421312D99936A1BFDCA7A", "URL":"http:\/\/www.mactechnologies.com\/Kaju_Test\/Kaju_Update_Test_Linux.zip", "ExecutableName":"Kaju Update Test" }, "MacBinary":{ - "Hash":"580E5E1739AACA02BC6436DF41D3C960", + "Hash":"F98AF211715DAA489A321D1CDE3E770E", "URL":"http:\/\/www.mactechnologies.com\/Kaju_Test\/Kaju_Update_Test_Mac.zip" }, "MinimumRequiredVersion":"", @@ -67,7 +67,7 @@ "UseTransparency":false, "Version":"1.2.1a4", "WindowsBinary":{ - "Hash":"70027AF7061DC79F56A6C5CD93C4C95E", + "Hash":"4A9BB6DC9D5859D6B7C34BBB184EE23B", "URL":"http:\/\/www.mactechnologies.com\/Kaju_Test\/Kaju_Update_Test_Win.zip", "ExecutableName":"Kaju Update Test.exe" } @@ -76,12 +76,12 @@ "AppName":"Kaju Update Test", "ImageURL":"http:\/\/www.mactechnologies.com\/Kaju_Test\/Some_Image_beta.png", "LinuxBinary":{ - "Hash":"070DF4E3FC0B42F646999C613EE2B2F8", + "Hash":"AC1BF5FA7B0421312D99936A1BFDCA7A", "URL":"http:\/\/www.mactechnologies.com\/Kaju_Test\/Kaju_Update_Test_Win.zip", "ExecutableName":"Kaju Update Test" }, "MacBinary":{ - "Hash":"770CBE477DFB2F24040697997835CE00", + "Hash":"F98AF211715DAA489A321D1CDE3E770E", "URL":"http:\/\/www.mactechnologies.com\/Kaju_Test\/Kaju_Update_Test_Linux.zip" }, "MinimumRequiredVersion":"", @@ -90,7 +90,7 @@ "UseTransparency":true, "Version":"1.2b2", "WindowsBinary":{ - "Hash":"DAE0E76052F66DDB4784E01830A02D14", + "Hash":"4A9BB6DC9D5859D6B7C34BBB184EE23B", "URL":"http:\/\/www.mactechnologies.com\/Kaju_Test\/Kaju_Update_Test_Mac.zip", "ExecutableName":"Kaju Update Test.exe" } @@ -99,12 +99,12 @@ "AppName":"Kaju Update Test", "ImageURL":"", "LinuxBinary":{ - "Hash":"921DAF87E4CE227BB36FCE64A88EC887", + "Hash":"AC1BF5FA7B0421312D99936A1BFDCA7A", "URL":"http:\/\/www.mactechnologies.com\/Kaju_Test\/Kaju_Update_Test_Linux.zip", "ExecutableName":"Kaju Update Test" }, "MacBinary":{ - "Hash":"580E5E1739AACA02BC6436DF41D3C960", + "Hash":"F98AF211715DAA489A321D1CDE3E770E", "URL":"http:\/\/www.mactechnologies.com\/Kaju_Test\/Kaju_Update_Test_Mac.zip" }, "MinimumRequiredVersion":"", @@ -113,7 +113,7 @@ "UseTransparency":false, "Version":"0.9", "WindowsBinary":{ - "Hash":"70027AF7061DC79F56A6C5CD93C4C95E", + "Hash":"4A9BB6DC9D5859D6B7C34BBB184EE23B", "URL":"http:\/\/www.mactechnologies.com\/Kaju_Test\/Kaju_Update_Test_Win.zip", "ExecutableName":"Kaju Update Test.exe" } diff --git a/README.md b/README.md index 2537aab..90ab613 100644 --- a/README.md +++ b/README.md @@ -404,3 +404,11 @@ Add a translation for each, then submit a pull request as outlined above. - Can override the preference file name when creating the UpdateChecker object. - Introduced command line project (CLI). + +1.6.1 (August 27, 2015) + +- **CLI**: Better handling of remote debugging. +- **CLI**: listversions now has --include and --exclude switches that take regex patterns. +- **Admin**: Prevent Save or Export if the file includes duplicate version numbers. +- **CLI**: Disallow adding duplicate version number or changing an existing version number so it becomes a duplicate. +- **Test App*: Created Build Script to automatically update the Kaju files after building. diff --git a/Update Test App/Build Automation.xojo_code b/Update Test App/Build Automation.xojo_code index f9b6aee..393f516 100644 --- a/Update Test App/Build Automation.xojo_code +++ b/Update Test App/Build Automation.xojo_code @@ -2,13 +2,25 @@ Begin BuildStepList Linux Begin BuildProjectStep Build End + Begin ExternalIDEScriptStep PrepareKajuLinux + AppliesTo = 2 + FolderItem = Li4AQnVpbGQgU2NyaXB0cwBQcmVwYXJlIEthanUueG9qb19zY3JpcHQ= + End End Begin BuildStepList Mac OS X Begin BuildProjectStep Build End + Begin ExternalIDEScriptStep PrepareKajuMac + AppliesTo = 2 + FolderItem = Li4AQnVpbGQgU2NyaXB0cwBQcmVwYXJlIEthanUueG9qb19zY3JpcHQ= + End End Begin BuildStepList Windows Begin BuildProjectStep Build End + Begin ExternalIDEScriptStep PrepareKajuWin + AppliesTo = 2 + FolderItem = Li4AQnVpbGQgU2NyaXB0cwBQcmVwYXJlIEthanUueG9qb19zY3JpcHQ= + End End #tag EndBuildAutomation diff --git a/Update Test App/Build Scripts/Prepare Kaju.xojo_script b/Update Test App/Build Scripts/Prepare Kaju.xojo_script new file mode 100644 index 0000000..f26d705 --- /dev/null +++ b/Update Test App/Build Scripts/Prepare Kaju.xojo_script @@ -0,0 +1,130 @@ +const kTargetMac = 7 +const kTargetWin = 3 +const kTargetLinux = 4 + +Function ConfirmTool( toolPath as String ) As Boolean +toolPath = DoShellCommand( "echo " + toolPath ).Trim +dim s as string +s = DoShellCommand( "which " + toolPath ) +return s.Trim = toolPath +End Function + +Function Quoted( s as String ) As String +return "'" + s.ReplaceAll( "'", "'\''" ) + "'" +End Function + +Function ShellToPosixPath( shellPath as String ) As String +dim path as string = shellPath.ReplaceAll( "\", "" ) +path = Quoted( path ) +return path +End Function + +// +// Confirm that it's a Mac +// +if not ConfirmTool( "/usr/bin/sw_vers" ) then +print "This build script can only be run in a Mac." +return +end if + +// +// Confirm that ditto is available +// +dim ditto as string +ditto = "/usr/bin/ditto" +if not ConfirmTool( ditto ) then +print "Error: Can't find ditto" +return +end if + +// +// Confirm that the kaju CLI is available +// +dim topLevelPath as string = CurrentBuildLocation +select case CurrentBuildTarget +case kTargetWin, kTargetLinux +topLevelPath = topLevelPath + "/../../../.." +case else +topLevelPath = topLevelPath + "/../../.." +end select + +dim kaju as string = topLevelPath + "/Kaju\ Admin\ CLI/Builds\ \-\ Kaju\ Admin\ CLI.xojo_project/Mac\ OS\ X\ \(Intel\)/kaju/kaju" + +dim result as string +result = DoShellCommand( kaju ) +if result.InStr( "addversion" ) = 0 then +print "The kaju CLI is not available. Build it first." +return +end if + +dim destPath as string = topLevelPath + "/Update\ Test\ Files\ \(Upload\ These\)" + +// +// Compress the files +// +dim zipName as string +dim sourcePath as string +dim sequesterRsrc as string +dim binaryType as string + +select case CurrentBuildTarget +case kTargetMac +zipName = "Kaju_Update_Test_Mac.zip" +sourcePath = CurrentBuildLocation + "/'" + CurrentBuildAppName + ".app'" +sequesterRsrc = "--sequesterRsrc " +binaryType = "--MacBinary" +case kTargetWin +zipName = "Kaju_Update_Test_Win.zip" +sourcePath = CurrentBuildLocation +binaryType = "--WinBinary" +case kTargetLinux +zipName = "Kaju_Update_Test_Linux.zip" +sourcePath = CurrentBuildLocation +binaryType = "--LinuxBinary" +case else +print "CurrentBuildTarget = " + str( CurrentBuildTarget ) +return +end select + +dim zipFile as string = destPath + "/" + zipName + +dim kajuFile as string = topLevelPath + "/Kaju\ Update\ Test\ v1.kaju" + +dim cmd as string +cmd = ditto + " -ck --keepParent " + sequesterRsrc + sourcePath + " " + zipFile +dim err as string = DoShellCommand( cmd ) +if err <> "" then +print err + &uA + &uA + cmd +return +end if + +// +// Get the versions +// +dim versions() as string = DoShellCommand( kaju + " --file=" + kajuFile + " listversions" ).Trim.Split( &uA ) + +// +// Set the versions +// +for each version as string in versions +cmd = kaju + " --file=" + kajuFile + " editversion --version=" + Quoted( version ) + _ +" " + binaryType + "=" + ShellToPosixPath( zipFile ) +dim r as string = DoShellCommand( cmd ) +if r <> "" then +print "Version: " + version + &uA + &uA + r +return +end if +next + +// +// Export the file +// +dim exportName as string = "UpdateInformation.html" +dim exportPath as string = destPath + "/" + exportName + +cmd = kaju + " --file=" + kajuFile + " export " + destPath +err = DoShellCommand( cmd ) +if err <> "" then +print err + &uA + &uA + cmd +return +end if \ No newline at end of file diff --git a/Update Test Files (Upload These)/Kaju_Update_Test_Linux.zip b/Update Test Files (Upload These)/Kaju_Update_Test_Linux.zip index 62df4fd..26ebf27 100644 Binary files a/Update Test Files (Upload These)/Kaju_Update_Test_Linux.zip and b/Update Test Files (Upload These)/Kaju_Update_Test_Linux.zip differ diff --git a/Update Test Files (Upload These)/Kaju_Update_Test_Mac.zip b/Update Test Files (Upload These)/Kaju_Update_Test_Mac.zip index eeb399b..b41375f 100644 Binary files a/Update Test Files (Upload These)/Kaju_Update_Test_Mac.zip and b/Update Test Files (Upload These)/Kaju_Update_Test_Mac.zip differ diff --git a/Update Test Files (Upload These)/Kaju_Update_Test_Win.zip b/Update Test Files (Upload These)/Kaju_Update_Test_Win.zip index ff01243..92f45e0 100644 Binary files a/Update Test Files (Upload These)/Kaju_Update_Test_Win.zip and b/Update Test Files (Upload These)/Kaju_Update_Test_Win.zip differ diff --git a/Update Test Files (Upload These)/UpdateInformation.html b/Update Test Files (Upload These)/UpdateInformation.html index 5d7d4e3..8378e3f 100644 --- a/Update Test Files (Upload These)/UpdateInformation.html +++ b/Update Test Files (Upload These)/UpdateInformation.html @@ -1,15 +1,15 @@ -KAJU 3A9F6F608297FE245CF0742B858AA0594956CA3F0C6922375C9D99E0E5E568793660C8B0EFDC28C5D428EC5E764CFEFF7E60B20833F758F9EA04B0E5910B30CF10BE835C620407C2AD903C46F6203734E0848367FADB02B696F7B1FB10EF740FF36C83AAB6D5884D4401D987BAE02D6C9F8EA5E961F81E678C3E997516DB1383B56F10272CDFBDADCAB704F59B489BA28E7B03CADA9B4A45EC4DAB77969D5D2F6A9FE3809259F3B0E678029428B7B9200EA32DCC15B2C24A38C7AD8CF268BEA38F4A57BC00F30CF6B388269AB270D7590D48B2869B03F5A325206426DE4FCEEABCA091757EEAC4A6AACF7CEF30B2341782ED0C9B80AFEBA5A52BF36800790DE6 +KAJU 21855598A2AC1E85674C5B4FAAEDDF0BC5141E918286A627C4AC9C1A3D03925907AAC88950BFC3B11A3AA6F94DAFD5C30C16ECCA944DA7BC61FBBC4CBDE58BD02256C0FA9132396B37BCA621E42C9C9DE22B44FF470C339616EFE116D9F7FD39F9359CE857A5F8C08D4879952240CCB0B175A847E387B5D67C2DB3B3EE35B1D8753D6B2F9765B7AAA37C498B792CD1A4CDBB7BEDA53515B21D9D0A8549A36360AF1946B6D453F59AA5437A9F175431A66F7C41AB9F47C1503BD8507E6E6D56D665EA52BBEFEFE3C41821E12CE7A6791E89E376870C09760044311459CFA2BD23C1106129658A939E6E7206472E257F14F2DE75FA4CD2E86637F6AAC709CC5ECB [ { "AppName":"Kaju Update Test", "ImageURL":"", "LinuxBinary":{ - "Hash":"921DAF87E4CE227BB36FCE64A88EC887", + "Hash":"AC1BF5FA7B0421312D99936A1BFDCA7A", "URL":"http://www.mactechnologies.com/Kaju_Test/Kaju_Update_Test_Linux.zip", "ExecutableName":"Kaju Update Test" }, "MacBinary":{ - "Hash":"580E5E1739AACA02BC6436DF41D3C960", + "Hash":"F98AF211715DAA489A321D1CDE3E770E", "URL":"http://www.mactechnologies.com/Kaju_Test/Kaju_Update_Test_Mac.zip" }, "MinimumRequiredVersion":"", @@ -18,7 +18,7 @@ "UseTransparency":false, "Version":"1.1 (10)", "WindowsBinary":{ - "Hash":"70027AF7061DC79F56A6C5CD93C4C95E", + "Hash":"4A9BB6DC9D5859D6B7C34BBB184EE23B", "URL":"http://www.mactechnologies.com/Kaju_Test/Kaju_Update_Test_Win.zip", "ExecutableName":"Kaju Update Test.exe" } @@ -27,12 +27,12 @@ "AppName":"New Kaju Update Test", "ImageURL":"", "LinuxBinary":{ - "Hash":"921DAF87E4CE227BB36FCE64A88EC887", + "Hash":"AC1BF5FA7B0421312D99936A1BFDCA7A", "URL":"http://www.mactechnologies.com/Kaju_Test/Kaju_Update_Test_Linux.zip", "ExecutableName":"Kaju Update Test" }, "MacBinary":{ - "Hash":"580E5E1739AACA02BC6436DF41D3C960", + "Hash":"F98AF211715DAA489A321D1CDE3E770E", "URL":"http://www.mactechnologies.com/Kaju_Test/Kaju_Update_Test_Mac.zip" }, "MinimumRequiredVersion":"", @@ -41,7 +41,7 @@ "UseTransparency":false, "Version":"1.2.2d5", "WindowsBinary":{ - "Hash":"70027AF7061DC79F56A6C5CD93C4C95E", + "Hash":"4A9BB6DC9D5859D6B7C34BBB184EE23B", "URL":"http://www.mactechnologies.com/Kaju_Test/Kaju_Update_Test_Win.zip", "ExecutableName":"Kaju Update Test.exe" } @@ -50,12 +50,12 @@ "AppName":"Kaju Update Test", "ImageURL":"", "LinuxBinary":{ - "Hash":"921DAF87E4CE227BB36FCE64A88EC887", + "Hash":"AC1BF5FA7B0421312D99936A1BFDCA7A", "URL":"http://www.mactechnologies.com/Kaju_Test/Kaju_Update_Test_Linux.zip", "ExecutableName":"Kaju Update Test" }, "MacBinary":{ - "Hash":"580E5E1739AACA02BC6436DF41D3C960", + "Hash":"F98AF211715DAA489A321D1CDE3E770E", "URL":"http://www.mactechnologies.com/Kaju_Test/Kaju_Update_Test_Mac.zip" }, "MinimumRequiredVersion":"", @@ -64,7 +64,7 @@ "UseTransparency":false, "Version":"1.2.1a4", "WindowsBinary":{ - "Hash":"70027AF7061DC79F56A6C5CD93C4C95E", + "Hash":"4A9BB6DC9D5859D6B7C34BBB184EE23B", "URL":"http://www.mactechnologies.com/Kaju_Test/Kaju_Update_Test_Win.zip", "ExecutableName":"Kaju Update Test.exe" } @@ -73,12 +73,12 @@ "AppName":"Kaju Update Test", "ImageURL":"http://www.mactechnologies.com/Kaju_Test/Some_Image_beta.png", "LinuxBinary":{ - "Hash":"070DF4E3FC0B42F646999C613EE2B2F8", + "Hash":"AC1BF5FA7B0421312D99936A1BFDCA7A", "URL":"http://www.mactechnologies.com/Kaju_Test/Kaju_Update_Test_Win.zip", "ExecutableName":"Kaju Update Test" }, "MacBinary":{ - "Hash":"770CBE477DFB2F24040697997835CE00", + "Hash":"F98AF211715DAA489A321D1CDE3E770E", "URL":"http://www.mactechnologies.com/Kaju_Test/Kaju_Update_Test_Linux.zip" }, "MinimumRequiredVersion":"", @@ -87,7 +87,7 @@ "UseTransparency":true, "Version":"1.2b2", "WindowsBinary":{ - "Hash":"DAE0E76052F66DDB4784E01830A02D14", + "Hash":"4A9BB6DC9D5859D6B7C34BBB184EE23B", "URL":"http://www.mactechnologies.com/Kaju_Test/Kaju_Update_Test_Mac.zip", "ExecutableName":"Kaju Update Test.exe" } @@ -96,12 +96,12 @@ "AppName":"Kaju Update Test", "ImageURL":"", "LinuxBinary":{ - "Hash":"921DAF87E4CE227BB36FCE64A88EC887", + "Hash":"AC1BF5FA7B0421312D99936A1BFDCA7A", "URL":"http://www.mactechnologies.com/Kaju_Test/Kaju_Update_Test_Linux.zip", "ExecutableName":"Kaju Update Test" }, "MacBinary":{ - "Hash":"580E5E1739AACA02BC6436DF41D3C960", + "Hash":"F98AF211715DAA489A321D1CDE3E770E", "URL":"http://www.mactechnologies.com/Kaju_Test/Kaju_Update_Test_Mac.zip" }, "MinimumRequiredVersion":"", @@ -110,7 +110,7 @@ "UseTransparency":false, "Version":"0.9", "WindowsBinary":{ - "Hash":"70027AF7061DC79F56A6C5CD93C4C95E", + "Hash":"4A9BB6DC9D5859D6B7C34BBB184EE23B", "URL":"http://www.mactechnologies.com/Kaju_Test/Kaju_Update_Test_Win.zip", "ExecutableName":"Kaju Update Test.exe" }