| 21 | return correct_path |
| 22 | |
| 23 | def load_plugin(self, plugin): |
| 24 | github_plugin = GithubPlugin(plugin) |
| 25 | if github_plugin.is_valid_plugin(): |
| 26 | if not github_plugin.is_already_installed(): |
| 27 | github_plugin.install() |
| 28 | |
| 29 | correct_path = github_plugin.get_plugin_folder() |
| 30 | |
| 31 | else: |
| 32 | correct_path = self._get_correct_path(plugin) |
| 33 | |
| 34 | if correct_path not in self.folder_cache: |
| 35 | self.folder_cache.append(correct_path) |
| 36 | sys.path.append(correct_path) |
| 37 | |
| 38 | def remove_path(self, path): |
| 39 | correct_path = self._get_correct_path(path) |