Index: trunk/ippScripts/scripts/dist_advancerun.pl
===================================================================
--- trunk/ippScripts/scripts/dist_advancerun.pl	(revision 28962)
+++ trunk/ippScripts/scripts/dist_advancerun.pl	(revision 28963)
@@ -67,4 +67,5 @@
 my $stacktool   = can_run('stacktool') or (warn "Can't find stacktool" and $missing_tools = 1);
 my $bgtool = can_run('bgtool') or (warn "Can't find bgtool" and $missing_tools = 1);
+my $staticskytool = can_run('staticskytool') or (warn "Can't find staticskytool" and $missing_tools = 1);
 if ($missing_tools) {
     &my_die("Can't find required tools.", $dist_id, $PS_EXIT_CONFIG_ERROR);
@@ -108,4 +109,8 @@
     $list_mode = "-sumskyfile";
     $component_key = "skycell_id";
+} elsif ($stage eq "sky") {
+    $tool_cmd = "$staticskytool -sky_id";
+    $list_mode = "-result";
+    $component_key = "";
 } elsif ($stage eq "diff") {
     $tool_cmd = "$difftool -diff_id";
Index: trunk/ippScripts/scripts/dist_bundle.pl
===================================================================
--- trunk/ippScripts/scripts/dist_bundle.pl	(revision 28962)
+++ trunk/ippScripts/scripts/dist_bundle.pl	(revision 28963)
@@ -53,4 +53,7 @@
                       'PPSTACK.OUTPUT.MASK' => 'mask',
                       'PPSTACK.OUTPUT.VARIANCE' => 'variance' );
+my %sky_cleaned   = ( 'PSPHOT.STACK.OUTPUT.IMAGE' => 'image',
+                      'PSPHOT.STACK.OUTPUT.MASK' => 'mask',
+                      'PSPHOT.STACK.OUTPUT.VARIANCE' => 'variance' );
 
 
@@ -420,4 +423,6 @@
     } elsif ($stage eq "stack") {
         $type = $stack_cleaned{$rule};
+    } elsif ($stage eq "sky") {
+        $type = $sky_cleaned{$rule};
     } else {
         &my_die("$stage is not a valid stage", $component, $PS_EXIT_CONFIG_ERROR);
@@ -500,4 +505,6 @@
     } elsif ($stage eq "stack") {
         $config_file_rule = "PPSTACK.CONFIG";
+    } elsif ($stage eq "sky") {
+        $config_file_rule = "PSPHOT.STACK.CONFIG";
     } else {
         &my_die("$stage is not a valid stage", $component, $PS_EXIT_CONFIG_ERROR);
Index: trunk/ippScripts/scripts/dist_make_fileset.pl
===================================================================
--- trunk/ippScripts/scripts/dist_make_fileset.pl	(revision 28962)
+++ trunk/ippScripts/scripts/dist_make_fileset.pl	(revision 28963)
@@ -223,5 +223,5 @@
     my $dbname = shift;
 
-    if (($stage eq 'stack') or ($stage eq 'diff') or ($stage eq 'SSdiff')) {
+    if (($stage eq 'stack') or ($stage eq 'diff') or ($stage eq 'SSdiff') or $stage eq 'sky') {
         return "";
     }
