Index: trunk/wikiation/installer/installation_system.py |
— | — | @@ -150,13 +150,32 @@ |
151 | 151 | |
152 | 152 | self.download(installer_name) |
153 | 153 | self.install_settings(installer_name) |
| 154 | + self.setup(installer_name) |
154 | 155 | # ... |
155 | | - # ... |
156 | 156 | |
157 | 157 | #query the installer to see if ot thinks the component is properly installed |
158 | 158 | # any flaws at this point are the fault of the installer :-P |
159 | 159 | return self.is_installed(installer_name) |
160 | 160 | |
| 161 | + def setup(self, installer_name, destination_dir=None): |
| 162 | + """perform actions needed to setup an extension post-download""" |
| 163 | + |
| 164 | + destination_dir=destination_dir or self.destination_dir |
| 165 | + if not destination_dir: |
| 166 | + raise Exception("Installation_system: Internal Error: No destination_dir provided") |
| 167 | + |
| 168 | + if not self.exists(installer_name): |
| 169 | + raise Installer_Exception("Can't find installer "+installer_name) |
| 170 | + |
| 171 | + self.do_setup(installer_name,destination_dir) |
| 172 | + |
| 173 | + def do_setup(self, installer_name, destination_dir): |
| 174 | + if not self.can_exec(installer_name,"setup"): |
| 175 | + print "notice: cannot execute setup script for "+installer_name |
| 176 | + return |
| 177 | + |
| 178 | + self.exec_task(installer_name,"setup") |
| 179 | + |
161 | 180 | def download (self, installer_name, destination_dir=None): |
162 | 181 | """perform actions needed to download all the files we need""" |
163 | 182 | |