Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Doesn't auto-create pane with clone file to the right and other weirdness #94

Closed
dvcrn opened this issue Sep 17, 2015 · 2 comments
Closed

Comments

@dvcrn
Copy link

dvcrn commented Sep 17, 2015

Found this PR here - #90

I turned create_new_pane_if_necessary on and expected now that when I execute copy_file_to_pane that it will create a new pane if it doesn't exist - but it doesn't.

On the other hand, if I move to a direction where there is no pane, it will create one which I didn't expect.

I think moving should be excluded from auto-creating new panes and stuff like copy_file_to_pane should be included. In general, I think it would be a lot better if we could specify a flag like create to each keybinding which will then create a pane if it doesn't exist if set to true.

Also not sure if this is the right place to ask, but I tried to execute 2 origami commands behind each other to implement a create_and_clone action:

sublime.active_window().run_command("create_pane", {"direction": "right"})
sublime.active_window().run_command("copy_file_to_pane", {"direction": "right"})

But it just creates the pane and doesn't copy the file in it. I tried adding a timeout in there but that didn't seem to have worked either. Any ideas?

@adzenith
Copy link
Member

You can pass create_new_if_necessary to commands individually (i.e. add it to your keybindings like you describe). Let me know if you can't get it working.

Your create_and_clone should work fine. What context are you running those commands in? From the console?

@adzenith
Copy link
Member

Is this still relevant or can I close?

@dvcrn dvcrn closed this as completed Feb 27, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants