diff -Nur e-smith-starterwebsite-2.6.0/createlinks e-smith-starterwebsite-2.6.0_bz9393/createlinks --- e-smith-starterwebsite-2.6.0/createlinks 2003-01-06 18:50:25.000000000 +0100 +++ e-smith-starterwebsite-2.6.0_bz9393/createlinks 2016-05-13 00:11:13.438100574 +0200 @@ -1,49 +1,7 @@ #!/usr/bin/perl -w +use esmith::Build::CreateLinks qw(:all); -sub safe_symlink { - my ($from, $to) = @_; - use File::Basename; - use File::Path; - mkpath(dirname($to)); - unlink($to); - symlink($from, $to) or die "Can't create symlink from $from to $to: $!"; -} -sub panel_link -{ - my ($function, $panel) = @_; - - my $cgibin = "root/etc/e-smith/web/panels/$panel/cgi-bin"; - - safe_symlink("../../../functions/$function", - "$cgibin/$function") -} - -#-------------------------------------------------- -# functions for manager panel -#-------------------------------------------------- -my $panel = "manager"; - -panel_link("starterwebsite", $panel); - -sub admin_common_link -{ - my ($function) = @_; - safe_symlink("../../../functions/$function", - "root/etc/e-smith/web/panels/manager/common/$function"); -} - -#-------------------------------------------------- -# Links for manager/common directory -#-------------------------------------------------- - - -sub event_link -{ - my ($action, $event, $level) = @_; - - safe_symlink("../actions/${action}", - "root/etc/e-smith/events/${event}/S${level}${action}"); -} +panel_link("starterwebsite", "manager");