From 73cd8588265a284047a79528f0a2be699c7e7ddd Mon Sep 17 00:00:00 2001 From: rzaitov Date: Fri, 15 Nov 2013 20:24:13 +0400 Subject: [PATCH 1/7] =?UTF-8?q?=D0=94=D0=BE=D0=B1=D0=B0=D0=B2=D0=B8=D0=BB?= =?UTF-8?q?=20=D0=B2=D0=BE=D0=B7=D0=BC=D0=BE=D0=B6=D0=BD=D0=BE=D1=81=D1=82?= =?UTF-8?q?=D1=8C=20=D0=BE=D0=BF=D1=80=D0=B5=D0=B4=D0=B5=D0=BB=D1=8F=D1=82?= =?UTF-8?q?=D1=8C=20backup=20ignore=20=D1=84=D0=B0=D0=B9=D0=BB=D1=8B/?= =?UTF-8?q?=D0=BF=D0=B0=D0=BF=D0=BA=D0=B8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../BaseBackupCommandBuilder.py | 14 ++++++++++++++ .../CreateBackupCommandBuilder.py | 9 +++++---- .../DeleteBackupCommandBuilder.py | 9 +++++---- .../RestoreBackupCommandBuilder.py | 9 +++++---- .../BuilderBackupCommands/__init__.py | 1 + scripts/TouchinBuild/Core/StepsRunner.py | 16 ++++++++++------ .../Tests/ManualTests/create_backup_test.py | 4 ++-- .../Tests/ManualTests/delete_backup_test.py | 4 ++-- .../Tests/ManualTests/restore_backup_test.py | 4 ++-- .../BaseBackupCommand/BaseBackupCommand.py | 9 +++++++-- .../BaseBackupCommand/CreateBackupCommand.py | 4 ++-- .../BaseBackupCommand/DeleteBackupCommand.py | 4 ++-- .../BaseBackupCommand/RestoreBackupCommand.py | 4 ++-- scripts/TouchinBuild/parsers/ValuesStriper.py | 8 +++++--- scripts/settings.txt | 1 + 15 files changed, 65 insertions(+), 35 deletions(-) create mode 100644 scripts/TouchinBuild/CommandBuilders/BuilderBackupCommands/BaseBackupCommandBuilder.py rename scripts/TouchinBuild/CommandBuilders/{ => BuilderBackupCommands}/CreateBackupCommandBuilder.py (57%) rename scripts/TouchinBuild/CommandBuilders/{ => BuilderBackupCommands}/DeleteBackupCommandBuilder.py (58%) rename scripts/TouchinBuild/CommandBuilders/{ => BuilderBackupCommands}/RestoreBackupCommandBuilder.py (58%) create mode 100644 scripts/TouchinBuild/CommandBuilders/BuilderBackupCommands/__init__.py diff --git a/scripts/TouchinBuild/CommandBuilders/BuilderBackupCommands/BaseBackupCommandBuilder.py b/scripts/TouchinBuild/CommandBuilders/BuilderBackupCommands/BaseBackupCommandBuilder.py new file mode 100644 index 0000000..9dc6dae --- /dev/null +++ b/scripts/TouchinBuild/CommandBuilders/BuilderBackupCommands/BaseBackupCommandBuilder.py @@ -0,0 +1,14 @@ +from parsers.ValuesStriper import ValuesStripper + + +class BaseBackupCommandBuilder: + def __init__(self, ignoreBackupStr): + + if ignoreBackupStr: + splitter = ValuesStripper(',') + values = splitter.strip(ignoreBackupStr) + self.ignoreBackup = values + else: + self.ignoreBackup = [] + + print self.ignoreBackup \ No newline at end of file diff --git a/scripts/TouchinBuild/CommandBuilders/CreateBackupCommandBuilder.py b/scripts/TouchinBuild/CommandBuilders/BuilderBackupCommands/CreateBackupCommandBuilder.py similarity index 57% rename from scripts/TouchinBuild/CommandBuilders/CreateBackupCommandBuilder.py rename to scripts/TouchinBuild/CommandBuilders/BuilderBackupCommands/CreateBackupCommandBuilder.py index 5bd0bd3..1921940 100644 --- a/scripts/TouchinBuild/CommandBuilders/CreateBackupCommandBuilder.py +++ b/scripts/TouchinBuild/CommandBuilders/BuilderBackupCommands/CreateBackupCommandBuilder.py @@ -1,10 +1,11 @@ +from CommandBuilders.BuilderBackupCommands.BaseBackupCommandBuilder import BaseBackupCommandBuilder from commands.BaseBackupCommand.CreateBackupCommand import CreateBackupCommand from parsers.ParserBackup.CreateBackupParser import CreateBackupParser -class CreateBackupCommandBuilder: - def __init__(self): - pass +class CreateBackupCommandBuilder(BaseBackupCommandBuilder): + def __init__(self, ignoreBackupStr): + BaseBackupCommandBuilder.__init__(self, ignoreBackupStr) def isCreateBackup(self, line): assert line is not None @@ -18,5 +19,5 @@ class CreateBackupCommandBuilder: parser = CreateBackupParser() parser.parseLine(line) - command = CreateBackupCommand() + command = CreateBackupCommand(self.ignoreBackup) return command diff --git a/scripts/TouchinBuild/CommandBuilders/DeleteBackupCommandBuilder.py b/scripts/TouchinBuild/CommandBuilders/BuilderBackupCommands/DeleteBackupCommandBuilder.py similarity index 58% rename from scripts/TouchinBuild/CommandBuilders/DeleteBackupCommandBuilder.py rename to scripts/TouchinBuild/CommandBuilders/BuilderBackupCommands/DeleteBackupCommandBuilder.py index 53e9238..2e3ea3a 100644 --- a/scripts/TouchinBuild/CommandBuilders/DeleteBackupCommandBuilder.py +++ b/scripts/TouchinBuild/CommandBuilders/BuilderBackupCommands/DeleteBackupCommandBuilder.py @@ -1,10 +1,11 @@ +from CommandBuilders.BuilderBackupCommands.BaseBackupCommandBuilder import BaseBackupCommandBuilder from commands.BaseBackupCommand.DeleteBackupCommand import DeleteBackupCommand from parsers.ParserBackup.DeleteBackupParser import DeleteBackupParser -class DeleteBackupCommandBuilder: - def __init__(self): - pass +class DeleteBackupCommandBuilder(BaseBackupCommandBuilder): + def __init__(self, ignoreBackupStr): + BaseBackupCommandBuilder.__init__(self, ignoreBackupStr) def isDeleteBackup(self, line): assert line is not None @@ -20,5 +21,5 @@ class DeleteBackupCommandBuilder: parser = DeleteBackupParser() parser.parseLine(line) - command = DeleteBackupCommand() + command = DeleteBackupCommand(self.ignoreBackup) return command diff --git a/scripts/TouchinBuild/CommandBuilders/RestoreBackupCommandBuilder.py b/scripts/TouchinBuild/CommandBuilders/BuilderBackupCommands/RestoreBackupCommandBuilder.py similarity index 58% rename from scripts/TouchinBuild/CommandBuilders/RestoreBackupCommandBuilder.py rename to scripts/TouchinBuild/CommandBuilders/BuilderBackupCommands/RestoreBackupCommandBuilder.py index 0f391a1..29c459f 100644 --- a/scripts/TouchinBuild/CommandBuilders/RestoreBackupCommandBuilder.py +++ b/scripts/TouchinBuild/CommandBuilders/BuilderBackupCommands/RestoreBackupCommandBuilder.py @@ -1,10 +1,11 @@ +from CommandBuilders.BuilderBackupCommands.BaseBackupCommandBuilder import BaseBackupCommandBuilder from commands.BaseBackupCommand.RestoreBackupCommand import RestoreBackupCommand from parsers.ParserBackup.RestoreBackupParser import RestoreBackupParser -class RestoreBackupCommandBuilder: - def __init__(self): - pass +class RestoreBackupCommandBuilder(BaseBackupCommandBuilder): + def __init__(self, ignoreBackupStr): + BaseBackupCommandBuilder.__init__(self, ignoreBackupStr) def isRestoreBackup(self, line): assert line is not None @@ -20,5 +21,5 @@ class RestoreBackupCommandBuilder: parser = RestoreBackupParser() parser.parseLine(line) - command = RestoreBackupCommand() + command = RestoreBackupCommand(self.ignoreBackup) return command diff --git a/scripts/TouchinBuild/CommandBuilders/BuilderBackupCommands/__init__.py b/scripts/TouchinBuild/CommandBuilders/BuilderBackupCommands/__init__.py new file mode 100644 index 0000000..cc31abc --- /dev/null +++ b/scripts/TouchinBuild/CommandBuilders/BuilderBackupCommands/__init__.py @@ -0,0 +1 @@ +__author__ = 'rzaitov' diff --git a/scripts/TouchinBuild/Core/StepsRunner.py b/scripts/TouchinBuild/Core/StepsRunner.py index fefce63..a6085ee 100644 --- a/scripts/TouchinBuild/Core/StepsRunner.py +++ b/scripts/TouchinBuild/Core/StepsRunner.py @@ -1,7 +1,9 @@ +from CommandBuilders.BuilderBackupCommands.CreateBackupCommandBuilder import CreateBackupCommandBuilder +from CommandBuilders.BuilderBackupCommands.DeleteBackupCommandBuilder import DeleteBackupCommandBuilder +from CommandBuilders.BuilderBackupCommands.RestoreBackupCommandBuilder import RestoreBackupCommandBuilder + from CommandBuilders.CleanBuildCommandBuilder import CleanBuildCommandBuilder from CommandBuilders.CopyCommandBuilder import CopyCommandBuilder -from CommandBuilders.CreateBackupCommandBuilder import CreateBackupCommandBuilder -from CommandBuilders.DeleteBackupCommandBuilder import DeleteBackupCommandBuilder from CommandBuilders.InstallProfileCommandBuilder import InstallProfileCommandBuilder from CommandBuilders.MakeDirsCommandBuilder import MakeDirsCommandBuilder from CommandBuilders.PatchCsprojCommandBuilder import PatchCsprojCommandBuilder @@ -9,7 +11,6 @@ from CommandBuilders.PatchInfoPlistArrayCommandBuilder import PatchInfoPlistArra from CommandBuilders.PatchInfoplistCommandBuilder import PatchInfoplistCommandBuilder from CommandBuilders.PatchManifestCommandBuilder import PatchManifestCommandBuilder from CommandBuilders.RemoveProjectCommandBuilder import RemoveProjectCommandBuilder -from CommandBuilders.RestoreBackupCommandBuilder import RestoreBackupCommandBuilder from CommandBuilders.ShCommandBuilder import ShCommandBuilder from CommandBuilders.SignApkBuilder import SignApkCommandBuilder from CommandBuilders.TestflightCommandBuilder import TestflightCommandBuilder @@ -26,9 +27,6 @@ class StepsRunner: self.shCommandBuilder = ShCommandBuilder() self.removeProjectBuilder = RemoveProjectCommandBuilder() - self.createBackupBuilder = CreateBackupCommandBuilder() - self.restoreFromBackupBuilder = RestoreBackupCommandBuilder() - self.deleteBackupBuilder = DeleteBackupCommandBuilder() self.createDirs = MakeDirsCommandBuilder() self.patchCsproj = PatchCsprojCommandBuilder() self.patchInfoPlist = PatchInfoplistCommandBuilder(self.valueProvider) @@ -37,6 +35,12 @@ class StepsRunner: self.copyBuilder = CopyCommandBuilder() self.testflightBuilder = TestflightCommandBuilder() + ignoreBackup = config.get('ignore_backup', None) + self.createBackupBuilder = CreateBackupCommandBuilder(ignoreBackup) + self.restoreFromBackupBuilder = RestoreBackupCommandBuilder(ignoreBackup) + self.deleteBackupBuilder = DeleteBackupCommandBuilder(ignoreBackup) + + profilePrefix = config['project_name'] self.installProfileBuilder = InstallProfileCommandBuilder(profilePrefix) diff --git a/scripts/TouchinBuild/Tests/ManualTests/create_backup_test.py b/scripts/TouchinBuild/Tests/ManualTests/create_backup_test.py index c770259..676da36 100644 --- a/scripts/TouchinBuild/Tests/ManualTests/create_backup_test.py +++ b/scripts/TouchinBuild/Tests/ManualTests/create_backup_test.py @@ -1,8 +1,8 @@ -from CommandBuilders.CreateBackupCommandBuilder import CreateBackupCommandBuilder +from CommandBuilders.BuilderBackupCommands.CreateBackupCommandBuilder import CreateBackupCommandBuilder line = "create backup" -cmdBuilder = CreateBackupCommandBuilder() +cmdBuilder = CreateBackupCommandBuilder(None) command = cmdBuilder.getCommandFor(line) command.execute() \ No newline at end of file diff --git a/scripts/TouchinBuild/Tests/ManualTests/delete_backup_test.py b/scripts/TouchinBuild/Tests/ManualTests/delete_backup_test.py index 4c312c4..a885c7d 100644 --- a/scripts/TouchinBuild/Tests/ManualTests/delete_backup_test.py +++ b/scripts/TouchinBuild/Tests/ManualTests/delete_backup_test.py @@ -1,8 +1,8 @@ -from CommandBuilders.DeleteBackupCommandBuilder import DeleteBackupCommandBuilder +from CommandBuilders.BuilderBackupCommands.DeleteBackupCommandBuilder import DeleteBackupCommandBuilder line = "delete backup" -cmdBuilder = DeleteBackupCommandBuilder() +cmdBuilder = DeleteBackupCommandBuilder(None) command = cmdBuilder.getCommandFor(line) command.execute() \ No newline at end of file diff --git a/scripts/TouchinBuild/Tests/ManualTests/restore_backup_test.py b/scripts/TouchinBuild/Tests/ManualTests/restore_backup_test.py index a61e390..33d3a6f 100644 --- a/scripts/TouchinBuild/Tests/ManualTests/restore_backup_test.py +++ b/scripts/TouchinBuild/Tests/ManualTests/restore_backup_test.py @@ -1,8 +1,8 @@ -from CommandBuilders.RestoreBackupCommandBuilder import RestoreBackupCommandBuilder +from CommandBuilders.BuilderBackupCommands.RestoreBackupCommandBuilder import RestoreBackupCommandBuilder line = "restore from backup" -builder = RestoreBackupCommandBuilder() +builder = RestoreBackupCommandBuilder(None) command = builder.getCommandFor(line) command.execute() diff --git a/scripts/TouchinBuild/commands/BaseBackupCommand/BaseBackupCommand.py b/scripts/TouchinBuild/commands/BaseBackupCommand/BaseBackupCommand.py index aba3acc..da0ac3e 100644 --- a/scripts/TouchinBuild/commands/BaseBackupCommand/BaseBackupCommand.py +++ b/scripts/TouchinBuild/commands/BaseBackupCommand/BaseBackupCommand.py @@ -4,8 +4,14 @@ from commands.CommandBase import CommandBase class BaseBackupCommand(CommandBase): - def __init__(self): + def __init__(self, ignoreBackup): CommandBase.__init__(self) + + assert ignoreBackup is not None + + self.backupIgnore = ['.git', '.gitignore', '.DS_Store', 'backup'] + self.backupIgnore.extend(ignoreBackup) + self.folderPath = '.' # вычислять абсолютные пути надо на этапе создания комманды @@ -13,7 +19,6 @@ class BaseBackupCommand(CommandBase): self.srcAbsDirPath = self.getAbsSrc() self.backupDirAbsPath = self.getAbsDst() - self.backupIgnore = ['.git', '.gitignore', '.DS_Store', 'backup'] def getAbsSrc(self): return self.getAbs(self.folderPath) diff --git a/scripts/TouchinBuild/commands/BaseBackupCommand/CreateBackupCommand.py b/scripts/TouchinBuild/commands/BaseBackupCommand/CreateBackupCommand.py index cb559dd..1906257 100644 --- a/scripts/TouchinBuild/commands/BaseBackupCommand/CreateBackupCommand.py +++ b/scripts/TouchinBuild/commands/BaseBackupCommand/CreateBackupCommand.py @@ -4,8 +4,8 @@ from commands.BaseBackupCommand.BaseBackupCommand import BaseBackupCommand class CreateBackupCommand(BaseBackupCommand): - def __init__(self): - BaseBackupCommand.__init__(self) + def __init__(self, ignoreBackup): + BaseBackupCommand.__init__(self, ignoreBackup) def execute(self): #if os.path.exists(self.backupDirAbsPath): diff --git a/scripts/TouchinBuild/commands/BaseBackupCommand/DeleteBackupCommand.py b/scripts/TouchinBuild/commands/BaseBackupCommand/DeleteBackupCommand.py index c29f5ce..660240b 100644 --- a/scripts/TouchinBuild/commands/BaseBackupCommand/DeleteBackupCommand.py +++ b/scripts/TouchinBuild/commands/BaseBackupCommand/DeleteBackupCommand.py @@ -4,8 +4,8 @@ from commands.BaseBackupCommand.BaseBackupCommand import BaseBackupCommand class DeleteBackupCommand(BaseBackupCommand): - def __init__(self): - BaseBackupCommand.__init__(self) + def __init__(self, ignoreBackup): + BaseBackupCommand.__init__(self, ignoreBackup) def execute(self): if not os.path.exists(self.backupDirAbsPath): diff --git a/scripts/TouchinBuild/commands/BaseBackupCommand/RestoreBackupCommand.py b/scripts/TouchinBuild/commands/BaseBackupCommand/RestoreBackupCommand.py index 403d5f7..15faf3b 100644 --- a/scripts/TouchinBuild/commands/BaseBackupCommand/RestoreBackupCommand.py +++ b/scripts/TouchinBuild/commands/BaseBackupCommand/RestoreBackupCommand.py @@ -4,8 +4,8 @@ from commands.BaseBackupCommand.BaseBackupCommand import BaseBackupCommand class RestoreBackupCommand(BaseBackupCommand): - def __init__(self): - BaseBackupCommand.__init__(self) + def __init__(self, ignoreBackup): + BaseBackupCommand.__init__(self, ignoreBackup) def execute(self): if not os.path.exists(self.backupDirAbsPath): diff --git a/scripts/TouchinBuild/parsers/ValuesStriper.py b/scripts/TouchinBuild/parsers/ValuesStriper.py index 934cc84..7be6574 100644 --- a/scripts/TouchinBuild/parsers/ValuesStriper.py +++ b/scripts/TouchinBuild/parsers/ValuesStriper.py @@ -1,11 +1,13 @@ class ValuesStripper: - def __init__(self): - pass + def __init__(self, separator=':'): + assert separator is not None + + self.separator = separator def strip(self, valueStr): assert valueStr is not None - rawValues = valueStr.split(':') + rawValues = valueStr.split(self.separator) values = [name.strip() for name in rawValues] return values \ No newline at end of file diff --git a/scripts/settings.txt b/scripts/settings.txt index fe7c0cd..6eac6f7 100644 --- a/scripts/settings.txt +++ b/scripts/settings.txt @@ -4,6 +4,7 @@ version=0.0.0 # комментарий в тойже строке configs = 'appstore, staging, android' project_name = CoolApp sln_config = Release|iPhone +backup_ignore = .git, .gitignore, .DS_Store, backup, artifacts # ios platform settings #ios.steps = 'scripts/IosSteps.txt' From 7043276c9c91df8a3f25e4c7ab6af73ac8771345 Mon Sep 17 00:00:00 2001 From: rzaitov Date: Fri, 15 Nov 2013 20:27:51 +0400 Subject: [PATCH 2/7] =?UTF-8?q?=D0=9F=D0=BE=D1=84=D0=B8=D0=BA=D1=81=D0=B8?= =?UTF-8?q?=D0=BB=20=D0=BA=D0=BB=D1=8E=D1=87=20=D0=BF=D0=BE=20=D0=BA=D1=82?= =?UTF-8?q?=D0=BE=D1=80=D0=BE=D0=BC=D1=83=20=D0=B1=D0=B5=D1=80=D1=83=D1=82?= =?UTF-8?q?=D1=81=D1=8F=20=D1=84=D0=B0=D0=B9=D0=BB=D1=8B=20=D0=B8=20=D0=BF?= =?UTF-8?q?=D0=B0=D0=BF=D0=BA=D0=B8=20=D0=B4=D0=BB=D1=8F=20=D0=B1=D1=8D?= =?UTF-8?q?=D0=BA=D0=B0=D0=BF=D0=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../BuilderBackupCommands/BaseBackupCommandBuilder.py | 4 +--- scripts/TouchinBuild/Core/StepsRunner.py | 2 +- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/scripts/TouchinBuild/CommandBuilders/BuilderBackupCommands/BaseBackupCommandBuilder.py b/scripts/TouchinBuild/CommandBuilders/BuilderBackupCommands/BaseBackupCommandBuilder.py index 9dc6dae..ca2954a 100644 --- a/scripts/TouchinBuild/CommandBuilders/BuilderBackupCommands/BaseBackupCommandBuilder.py +++ b/scripts/TouchinBuild/CommandBuilders/BuilderBackupCommands/BaseBackupCommandBuilder.py @@ -9,6 +9,4 @@ class BaseBackupCommandBuilder: values = splitter.strip(ignoreBackupStr) self.ignoreBackup = values else: - self.ignoreBackup = [] - - print self.ignoreBackup \ No newline at end of file + self.ignoreBackup = [] \ No newline at end of file diff --git a/scripts/TouchinBuild/Core/StepsRunner.py b/scripts/TouchinBuild/Core/StepsRunner.py index a6085ee..364d5a7 100644 --- a/scripts/TouchinBuild/Core/StepsRunner.py +++ b/scripts/TouchinBuild/Core/StepsRunner.py @@ -35,7 +35,7 @@ class StepsRunner: self.copyBuilder = CopyCommandBuilder() self.testflightBuilder = TestflightCommandBuilder() - ignoreBackup = config.get('ignore_backup', None) + ignoreBackup = config.get('backup_ignore', None) self.createBackupBuilder = CreateBackupCommandBuilder(ignoreBackup) self.restoreFromBackupBuilder = RestoreBackupCommandBuilder(ignoreBackup) self.deleteBackupBuilder = DeleteBackupCommandBuilder(ignoreBackup) From 3d7a40dd23914d7ec96faa69b74e970dfceffd6b Mon Sep 17 00:00:00 2001 From: rzaitov Date: Fri, 15 Nov 2013 20:38:07 +0400 Subject: [PATCH 3/7] =?UTF-8?q?=D0=9F=D0=BE=D0=B4=D0=B3=D0=BE=D1=82=D0=BE?= =?UTF-8?q?=D0=B2=D0=B8=D0=BB=20=D0=BA=20=D1=81=D0=B1=D0=BE=D1=80=D0=BA?= =?UTF-8?q?=D0=B5=203=20=D0=BA=D0=BE=D0=BD=D1=84=D0=B8=D0=B3=D1=83=D1=80?= =?UTF-8?q?=D0=B0=D1=86=D0=B8=D0=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- scripts/AndroidSteps.txt | 12 ++++++++++++ scripts/IosSetupSteps.txt | 6 +++--- scripts/IosSteps.txt | 6 +++--- scripts/settings.txt | 6 +++--- 4 files changed, 21 insertions(+), 9 deletions(-) diff --git a/scripts/AndroidSteps.txt b/scripts/AndroidSteps.txt index 0bbd163..8b06ad5 100644 --- a/scripts/AndroidSteps.txt +++ b/scripts/AndroidSteps.txt @@ -1,7 +1,19 @@ +restore from backup +create backup + inside 'BuildSample/BuildSample.sln' remove 'CoolApp:NotCompileApp:Domain' project +inside 'BuildSample/BuildSample/CoolApp.csproj' set OutputPath to 'Output' for '{@sln_config}' + inside 'BuildSample/DroidApp/Properties/AndroidManifest.xml' set android:versionCode to '17' inside 'BuildSample/DroidApp/Properties/AndroidManifest.xml' set android:versionName to '1.2.3' clean 'BuildSample/BuildSample.sln' for '{@sln_config}' sign android 'BuildSample/BuildSample.sln' for '{@sln_config}' project 'DroidApp' + +create dirs 'Output/GooglePlay/Artifacts' +copy 'BuildSample/DroidApp/Output/*.apk' to 'Output/GooglePlay/Artifacts' +sh cp -a BuildSample/DroidApp/Output/ Output/GooglePlay/ + +restore from backup +delete backup diff --git a/scripts/IosSetupSteps.txt b/scripts/IosSetupSteps.txt index 08eaf5d..c825961 100644 --- a/scripts/IosSetupSteps.txt +++ b/scripts/IosSetupSteps.txt @@ -1,7 +1,7 @@ -# restore from backup # восстанавливаем из бэкапа (исходники от сборки предыдущей конфигурации могут быть модифицированными) -# create backup +restore from backup # восстанавливаем из бэкапа (исходники от сборки предыдущей конфигурации могут быть модифицированными) +create backup -sh echo '{@sln_config}' +sh echo 'Hello from setup.txt' inside 'BuildSample/BuildSample.sln' remove 'NotCompileApp:DroidApp' project diff --git a/scripts/IosSteps.txt b/scripts/IosSteps.txt index 72b4dff..09d6afe 100644 --- a/scripts/IosSteps.txt +++ b/scripts/IosSteps.txt @@ -7,7 +7,7 @@ create dirs 'Output/Appstore/Artifacts' copy 'BuildSample/BuildSample/Output/{@assembly_name}-{@version}.ipa' to 'Output/Appstore/Artifacts' sh cp -a BuildSample/BuildSample/Output/ Output/Appstore/ -publish 'Output/Appstore/Artifacts/{@assembly_name}-{@version}.ipa' to testflight notes = 'Hello' api_token = '{@tf_api_token}' team_token = '{@tf_team_token}' +#publish 'Output/Appstore/Artifacts/{@assembly_name}-{@version}.ipa' to testflight notes = 'Hello' api_token = '{@tf_api_token}' team_token = '{@tf_team_token}' -#restore from backup -#delete backup \ No newline at end of file +restore from backup +delete backup \ No newline at end of file diff --git a/scripts/settings.txt b/scripts/settings.txt index 6eac6f7..29dba80 100644 --- a/scripts/settings.txt +++ b/scripts/settings.txt @@ -3,11 +3,10 @@ build_tool='/Applications/Xamarin\ Studio.app/Contents/MacOS/mdtool' version=0.0.0 # комментарий в тойже строке configs = 'appstore, staging, android' project_name = CoolApp -sln_config = Release|iPhone -backup_ignore = .git, .gitignore, .DS_Store, backup, artifacts +backup_ignore = .git, .gitignore, .DS_Store, backup, Output # ios platform settings -#ios.steps = 'scripts/IosSteps.txt' +ios.sln_config = Release|iPhone ios.setup_steps = 'IosSetupSteps.txt' ios.assembly_name = 'CoolApp' @@ -15,6 +14,7 @@ ios.tf_api_token = '0e6925075d4fc10fed0e7bbf43fa6894_NjQ0OTI2MjAxMi0wOS0yNSAxMTo ios.tf_team_token = 'c5c3cf7a6dae2bea4382dfbd181a2075_Mjc4ODkwMjAxMy0wOS0yOSAxNDowOTo1OC40Mzg5MTY' # android platform settings +android.sln_config = Release android.steps = 'scripts/AndroidSteps.txt' # config settings From b87b0b5b37f2a4c74996bd8bf825e83fa54c77c8 Mon Sep 17 00:00:00 2001 From: rzaitov Date: Fri, 15 Nov 2013 20:40:39 +0400 Subject: [PATCH 4/7] =?UTF-8?q?=D0=98=D1=81=D0=BF=D1=80=D0=B0=D0=B2=D0=B8?= =?UTF-8?q?=D0=BB=20=D0=BE=D1=88=D0=B8=D0=B1=D0=BA=D1=83=20=D0=B2=20=D0=B0?= =?UTF-8?q?=D0=BD=D0=B4=D1=80=D0=BE=D0=B8=D0=B4=20=D1=88=D0=B0=D0=B3=D0=B0?= =?UTF-8?q?=D1=85?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- scripts/AndroidSteps.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/AndroidSteps.txt b/scripts/AndroidSteps.txt index 8b06ad5..c887abf 100644 --- a/scripts/AndroidSteps.txt +++ b/scripts/AndroidSteps.txt @@ -3,7 +3,7 @@ create backup inside 'BuildSample/BuildSample.sln' remove 'CoolApp:NotCompileApp:Domain' project -inside 'BuildSample/BuildSample/CoolApp.csproj' set OutputPath to 'Output' for '{@sln_config}' +inside 'BuildSample/DroidApp/DroidApp.csproj' set OutputPath to 'Output' for '{@sln_config}' inside 'BuildSample/DroidApp/Properties/AndroidManifest.xml' set android:versionCode to '17' inside 'BuildSample/DroidApp/Properties/AndroidManifest.xml' set android:versionName to '1.2.3' From 25b58a1548f33aa965681c791a7d561b650630d8 Mon Sep 17 00:00:00 2001 From: rzaitov Date: Fri, 15 Nov 2013 21:00:40 +0400 Subject: [PATCH 5/7] =?UTF-8?q?=D0=9D=D0=B0=D1=88=D0=B5=D0=BB=20=D0=BE?= =?UTF-8?q?=D1=88=D0=B8=D0=B1=D0=BA=D1=83.=20=D0=9F=D0=BE=20=D0=BA=D0=B0?= =?UTF-8?q?=D0=BA=D0=B8=D0=BC-=D1=82=D0=BE=20=D0=BF=D1=80=D0=B8=D1=87?= =?UTF-8?q?=D0=B8=D0=BD=D0=B0=D0=BC=20=D0=B2=D1=81=D0=B5=D0=B3=D0=B4=D0=B0?= =?UTF-8?q?=20=D1=81=D0=BE=D0=B1=D0=B8=D1=80=D0=B0=D0=B5=D1=82=D1=81=D1=8F?= =?UTF-8?q?=20=D0=B2=20bin/Debug=20=3F=3F=3F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- scripts/AndroidSteps.txt | 1 + .../commands/CleanBuildCommands/SignApkCommand.py | 1 + scripts/settings.txt | 4 ++-- 3 files changed, 4 insertions(+), 2 deletions(-) diff --git a/scripts/AndroidSteps.txt b/scripts/AndroidSteps.txt index c887abf..c1bea87 100644 --- a/scripts/AndroidSteps.txt +++ b/scripts/AndroidSteps.txt @@ -9,6 +9,7 @@ inside 'BuildSample/DroidApp/Properties/AndroidManifest.xml' set android:version inside 'BuildSample/DroidApp/Properties/AndroidManifest.xml' set android:versionName to '1.2.3' clean 'BuildSample/BuildSample.sln' for '{@sln_config}' +build 'BuildSample/BuildSample.sln' for '{@sln_config}' sign android 'BuildSample/BuildSample.sln' for '{@sln_config}' project 'DroidApp' create dirs 'Output/GooglePlay/Artifacts' diff --git a/scripts/TouchinBuild/commands/CleanBuildCommands/SignApkCommand.py b/scripts/TouchinBuild/commands/CleanBuildCommands/SignApkCommand.py index 9914f75..501852a 100644 --- a/scripts/TouchinBuild/commands/CleanBuildCommands/SignApkCommand.py +++ b/scripts/TouchinBuild/commands/CleanBuildCommands/SignApkCommand.py @@ -19,4 +19,5 @@ class SignApkCommand(ShellCommandBase): def execute(self): cmdText = self.commandPattern.format(self.pathToBuildUtil, self.slnConfig, self.projectName, self.slnPath) + print cmdText self.executeShell(cmdText) diff --git a/scripts/settings.txt b/scripts/settings.txt index 29dba80..4426ed8 100644 --- a/scripts/settings.txt +++ b/scripts/settings.txt @@ -3,7 +3,7 @@ build_tool='/Applications/Xamarin\ Studio.app/Contents/MacOS/mdtool' version=0.0.0 # комментарий в тойже строке configs = 'appstore, staging, android' project_name = CoolApp -backup_ignore = .git, .gitignore, .DS_Store, backup, Output +backup_ignore = .git, .gitignore, .DS_Store, backup, Output, scripts # ios platform settings ios.sln_config = Release|iPhone @@ -14,7 +14,7 @@ ios.tf_api_token = '0e6925075d4fc10fed0e7bbf43fa6894_NjQ0OTI2MjAxMi0wOS0yNSAxMTo ios.tf_team_token = 'c5c3cf7a6dae2bea4382dfbd181a2075_Mjc4ODkwMjAxMy0wOS0yOSAxNDowOTo1OC40Mzg5MTY' # android platform settings -android.sln_config = Release +android.sln_config = Release|AnyCPU android.steps = 'scripts/AndroidSteps.txt' # config settings From d364c7cc94f9f8e26dde58c076f3458c22680a90 Mon Sep 17 00:00:00 2001 From: rzaitov Date: Fri, 15 Nov 2013 21:08:54 +0400 Subject: [PATCH 6/7] =?UTF-8?q?=D0=B7=D0=B0=D0=B4=D0=B0=D0=BB=20=D1=88?= =?UTF-8?q?=D0=B0=D0=B3=D0=B8=20=D0=B4=D0=BB=D1=8F=20ios=20=D1=81=D0=B1?= =?UTF-8?q?=D0=BE=D1=80=D0=BE=D0=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- scripts/settings.txt | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/scripts/settings.txt b/scripts/settings.txt index 4426ed8..b0ad51d 100644 --- a/scripts/settings.txt +++ b/scripts/settings.txt @@ -1,11 +1,12 @@ # global settings build_tool='/Applications/Xamarin\ Studio.app/Contents/MacOS/mdtool' version=0.0.0 # комментарий в тойже строке -configs = 'appstore, staging, android' +configs = 'appstore' project_name = CoolApp backup_ignore = .git, .gitignore, .DS_Store, backup, Output, scripts # ios platform settings +ios.steps = scripts/IosSteps.txt ios.sln_config = Release|iPhone ios.setup_steps = 'IosSetupSteps.txt' ios.assembly_name = 'CoolApp' From 24b8dbf8343b68828755ab5493250f46bf7f0f78 Mon Sep 17 00:00:00 2001 From: rzaitov Date: Mon, 18 Nov 2013 15:50:20 +0400 Subject: [PATCH 7/7] =?UTF-8?q?=D0=94=D0=BE=D0=B1=D0=B8=D0=BB=D1=81=D1=8F?= =?UTF-8?q?=20=D0=BF=D1=80=D0=B0=D0=B2=D0=B8=D0=BB=D1=8C=D0=BD=D0=BE=D0=B9?= =?UTF-8?q?=20=D1=81=D0=B1=D0=BE=D1=80=D0=BA=D0=B8=20android=20=D0=BF?= =?UTF-8?q?=D1=80=D0=BE=D0=B5=D0=BA=D1=82=D0=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- scripts/AndroidSteps.txt | 5 ++--- scripts/settings.txt | 1 + 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/scripts/AndroidSteps.txt b/scripts/AndroidSteps.txt index c1bea87..a421d0c 100644 --- a/scripts/AndroidSteps.txt +++ b/scripts/AndroidSteps.txt @@ -9,11 +9,10 @@ inside 'BuildSample/DroidApp/Properties/AndroidManifest.xml' set android:version inside 'BuildSample/DroidApp/Properties/AndroidManifest.xml' set android:versionName to '1.2.3' clean 'BuildSample/BuildSample.sln' for '{@sln_config}' -build 'BuildSample/BuildSample.sln' for '{@sln_config}' -sign android 'BuildSample/BuildSample.sln' for '{@sln_config}' project 'DroidApp' +sign android 'BuildSample/BuildSample.sln' for '{@sln_config_build}' project 'DroidApp' create dirs 'Output/GooglePlay/Artifacts' -copy 'BuildSample/DroidApp/Output/*.apk' to 'Output/GooglePlay/Artifacts' +sh cp BuildSample/DroidApp/Output/*.apk Output/GooglePlay/Artifacts sh cp -a BuildSample/DroidApp/Output/ Output/GooglePlay/ restore from backup diff --git a/scripts/settings.txt b/scripts/settings.txt index b0ad51d..9c52061 100644 --- a/scripts/settings.txt +++ b/scripts/settings.txt @@ -16,6 +16,7 @@ ios.tf_team_token = 'c5c3cf7a6dae2bea4382dfbd181a2075_Mjc4ODkwMjAxMy0wOS0yOSAxND # android platform settings android.sln_config = Release|AnyCPU +android.sln_config_build = Release android.steps = 'scripts/AndroidSteps.txt' # config settings