commit c9debbb1ceabdea48df609a9db2025265fa65c51
Author: Simon Howard <fraggle@soulsphere.org>
AuthorDate: Mon Nov 9 23:30:34 2015 -0500
Commit: Simon Howard <fraggle@soulsphere.org>
CommitDate: Mon Nov 9 23:30:34 2015 -0500
Set the window title for command prompt.
This is a bit more interesting than just displaying "tempscript.sh".
---
pkg/osx/Execute.m | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/pkg/osx/Execute.m b/pkg/osx/Execute.m
index bc5d8c56..2d5d5931 100644
--- a/pkg/osx/Execute.m
+++ b/pkg/osx/Execute.m
@@ -26,6 +26,7 @@
#define RESPONSE_FILE "/tmp/launcher.rsp"
#define TEMP_SCRIPT "/tmp/tempscript.sh"
+#define WINDOW_TITLE PACKAGE_STRING " command prompt"
static char *executable_path;
@@ -183,6 +184,9 @@ void OpenTerminalWindow(const char *doomwadpath)
fprintf(stream, "export DOOMWADPATH\n");
fprintf(stream, "rm -f \"%s\"\n", TEMP_SCRIPT);
+ // Window title to something more interesting than "tempscript":
+ fprintf(stream, "echo -en \"\\033]0;%s\\a\"\n", WINDOW_TITLE);
+
// Display a useful message:
fprintf(stream, "clear\n");