chore: disable create on missing behaviour for now

This commit is contained in:
cschen 2024-11-03 17:58:17 +01:00
parent 9e2a0f323e
commit 612308d4f4

View file

@ -53,17 +53,17 @@ class CodempJoinBufferCommand(sublime_plugin.WindowCommand):
except KeyError:
pass
# if doesn't exist in the workspace, ask for creation.
if vws.handle.get_buffer(buffer_id) is None:
if sublime.ok_cancel_dialog(
f"There is no buffer named '{buffer_id}' in the workspace '{workspace_id}'.\n\
Do you want to create it?",
ok_title="yes", title="Create Buffer?",
):
sublime.run_command("codemp_create_buffer", {
"workspace_id": workspace_id,
"buffer_id": buffer_id
})
# # if doesn't exist in the workspace, ask for creation.
# if vws.handle.get_buffer(buffer_id) is None:
# if sublime.ok_cancel_dialog(
# f"There is no buffer named '{buffer_id}' in the workspace '{workspace_id}'.\n\
# Do you want to create it?",
# ok_title="yes", title="Create Buffer?",
# ):
# sublime.run_command("codemp_create_buffer", {
# "workspace_id": workspace_id,
# "buffer_id": buffer_id
# })
# now we can defer the attaching process
logger.debug(f"attempting to attach to {buffer_id}...")