summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorMaxime Coste <mawww@kakoune.org>2020-05-03 13:20:44 +1000
committerMaxime Coste <mawww@kakoune.org>2020-05-03 13:20:44 +1000
commitf4efde7e08d06d0f2bc056c37e3948516c31b13e (patch)
tree06da317b6bdc4a69292eb7f382d16779784d13c1 /src
parent2fca4e564304ee69b33711084ceeefae397619cd (diff)
parentc010f14a7ceb4e87df9e6e091fccf995f3f5b655 (diff)
Merge remote-tracking branch 'krobelus/kak-c-initial-buffer-pos'
Diffstat (limited to 'src')
-rw-r--r--src/main.cc10
1 files changed, 8 insertions, 2 deletions
diff --git a/src/main.cc b/src/main.cc
index 48d4e3ab..4ec8effa 100644
--- a/src/main.cc
+++ b/src/main.cc
@@ -1164,8 +1164,14 @@ int main(int argc, char* argv[])
}
}
String new_files;
- for (auto name : files)
- new_files += format("edit '{}';", escape(real_path(name), "'", '\\'));
+ for (auto name : files) {
+ new_files += format("edit '{}'", escape(real_path(name), "'", '\\'));
+ if (init_coord) {
+ new_files += format(" {} {}", init_coord->line + 1, init_coord->column + 1);
+ init_coord.reset();
+ }
+ new_files += ";";
+ }
return run_client(*server_session, {}, new_files + client_init, init_coord, ui_type, false);
}