From: Moritz Bunkus Date: Tue, 28 Dec 2010 11:37:20 +0000 (+0100) Subject: Vor Ausführung Verzeichnis wechseln X-Git-Tag: release-2.6.3~61^2~7^2~1^2~2^2~108 X-Git-Url: http://wagnertech.de/git?a=commitdiff_plain;h=88e5a86ec8d02e0fcc98a3fbefff39f0a6ba1427;p=kivitendo-erp.git Vor Ausführung Verzeichnis wechseln --- diff --git a/scripts/task_server.pl b/scripts/task_server.pl index 470272b75..2460e1b56 100755 --- a/scripts/task_server.pl +++ b/scripts/task_server.pl @@ -3,6 +3,14 @@ use strict; BEGIN { + require Cwd; + + my $dir = $0; + $dir = Cwd::getcwd() . '/' . $dir unless $dir =~ m|^/|; + $dir =~ s|[^/]+$|..|; + + chdir($dir) || die "Cannot change directory to ${dir}\n"; + unshift @INC, "modules/override"; # Use our own versions of various modules (e.g. YAML). push @INC, "modules/fallback"; # Only use our own versions of modules if there's no system version. }