apneadiving
apneadiving

Reputation: 115511

Sublime2 Plugin: how to open multiple files in editor?

I'm writing a plugin which has a command creating 3 files.

I want the 3 files to be opened and tabbed in Sublime.

I thought this would do the trick but only one file is opened.

self.view.window().open_file(view_path, 1)
self.view.window().open_file(controller_path, 1)
self.view.window().open_file(base_coffee, 1)

Any insight please?

Upvotes: 2

Views: 186

Answers (1)

apneadiving
apneadiving

Reputation: 115511

At last I found it:

initial_window = self.view.window()
initial_window.open_file(view_path,       1)
initial_window.open_file(controller_path, 1)
initial_window.open_file(base_coffee,     1)

Upvotes: 1

Related Questions