aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/terminal.vala
diff options
context:
space:
mode:
Diffstat (limited to 'terminal.vala')
-rw-r--r--terminal.vala16
1 files changed, 1 insertions, 15 deletions
diff --git a/terminal.vala b/terminal.vala
index c963a75..aef68a5 100644
--- a/terminal.vala
+++ b/terminal.vala
@@ -65,7 +65,7 @@ class Terminal : Gtk.Overlay {
var argv = args[1:args.length];
if (argv.length == 0) {
- argv = { get_shell() };
+ argv = { Utils.get_shell() };
}
vte.spawn_sync(DEFAULT, null, argv, null, SEARCH_PATH, null, null, null);
@@ -111,20 +111,6 @@ class Terminal : Gtk.Overlay {
}
}
- string get_shell() {
- var env_shell = Environment.get_variable("SHELL");
- if (env_shell != null && env_shell.length > 0){
- return env_shell;
- }
-
- unowned Posix.Passwd pw = Posix.getpwuid(Posix.getuid());
- if (pw != null && pw.pw_shell.length > 0) {
- return pw.pw_shell;
- }
-
- return "/bin/sh";
- }
-
bool match_modifiers(int state, Gdk.ModifierType modifiers) {
return (state & modifiers) == modifiers;
}