Начал реализацию dsl к билд коммандам

This commit is contained in:
Rustam Zaitov
2013-10-03 21:41:52 +04:00
parent 6e61455c90
commit b0abdcccdb
10 changed files with 126 additions and 16 deletions
+1
View File
@@ -0,0 +1 @@
__author__ = 'rzaitov'
+26
View File
@@ -0,0 +1,26 @@
import commands.patch_infoplist_command as plist
import os
config = {
'version': '0.1.2',
# patch_info_plist
'plist-CoolApp_rel_path': 'BuildSample/Info.plist',
'plist-CoolApp_CFBundleVersion': '@version', # set CFBundleVersion
'plist-CoolApp_CFBundleDisplayName': '@app_name', # set CFBundleDisplayName
}
base_dir = '/Users/rzaitov/Documents/Apps/BuildScript',
class PathProvider:
def __init__(self, base_dir):
self._base_dir = base_dir
def ResolveAbsPath(self, rel_path):
abs_path = os.path.join(self._base_dir, rel_path)
return abs_path
provider = PathProvider(base_dir)
patcher = plist.PatchInfoPlist(config, provider)
patcher.Execute()