(self, edit)
| 197 | |
| 198 | class RecoverJsLinkCommand(sublime_plugin.TextCommand): |
| 199 | def run(self, edit): |
| 200 | text = get_buffer_text(self.view) |
| 201 | prefix = get_console_text(self.view).strip('\n').strip('/') + '/' |
| 202 | |
| 203 | try: |
| 204 | text = json.loads(text) |
| 205 | except: |
| 206 | sublime.message_dialog('[error] Json data has error! Please check...') |
| 207 | else: |
| 208 | rets = '' |
| 209 | for key in text.keys(): |
| 210 | rets += prefix + key + '.' + text[key] + '.js\n' |
| 211 | panel_print(self.view, edit, rets) |
| 212 | |
| 213 | |
| 214 | # Text Edit |
nothing calls this directly
no test coverage detected