Update conmux ~$ commands to allow for arguments to be passed
For example: ~$hardreset -o 3
if the command hardreset accepts -o 3 then that will be passed to it
Also add bin/lib and bin/../lib to path for libraries (On an installed version of conmux
libraries are not always where the binary is)

Signed-off-by: Scott Zawalski <scottz@google.com>



git-svn-id: http://test.kernel.org/svn/autotest/trunk@2756 592f7852-d20e-0410-864c-8624ca9c26a4
diff --git a/conmux/conmux b/conmux/conmux
index 63534b0..4c45f60 100755
--- a/conmux/conmux
+++ b/conmux/conmux
@@ -23,6 +23,8 @@
 
 # Find our internal libraries.
 use lib $FindBin::Bin;
+use lib "$FindBin::Bin/../lib/";
+use lib "$FindBin::Bin/lib/";
 use Conmux;
 
 our $P = 'conmux';
@@ -652,7 +654,8 @@
 	}
 
 	local(*IN, *OUT, *ERR);
-	my $pid = IPC::Open3::open3(*IN, *OUT, *ERR, $run);
+	my ($cmd, @args) = split(' ', $run . " $a");
+	my $pid = IPC::Open3::open3(*IN, *OUT, *ERR, $cmd, @args);
 	close(*IN{IO});
 
 	# XXX: this should not be happening here.