Permalink
Browse files

Fix an unnessesary and ugly warning on a non existing build folder wh…

…en creating packages - thanks fade2gray
  • Loading branch information...
1 parent 4196e22 commit e2c8a310ab9ab29e99ad2bb11c0971dc7de7210a @elkuku committed Apr 16, 2012
@@ -1 +1 @@
-0.0.16-2-g4739ee8
+0.0.16-3-g4196e22
@@ -9,18 +9,26 @@
$buildPath = $this->project->getZipPath();
?>
+
<div class="infoHeader img icon-16-installfolder"><?php echo jgettext('Build folder') ?></div>
<?php
if(2 == ECR_HELP):
echo JHTML::tooltip(jgettext('Build folder').'::'
- .jgettext('The folder where your final package ends up. The folders extension_name and version will be added automatically.'
- .'<br />'
- .'If left blank the default folder will be used.'));
+ .jgettext('The folder where your final package ends up. The folders extension_name and version will be added automatically.'
+ .'<br />'
+ .'If left blank the default folder will be used.'));
echo '<br/><br/>';
- endif; ?>
+endif; ?>
<div class="path"><?php echo $buildPath.DS.$this->project->version; ?></div>
<?php
if(! JFolder::exists($buildPath.DS.$this->project->version)) :
- EcrHtml::displayMessage(jgettext('The folder does not exist'), 'warning');
+
+ //-- The build folder does not exist - let's create it
+
+ if(JFolder::create($buildPath.DS.$this->project->version)) :
+ EcrHtml::displayMessage(jgettext('The folder has been created'));
+ else :
+ EcrHtml::displayMessage(jgettext('Unable to create the build folder - please check !'), 'error');
+ endif;
endif;

0 comments on commit e2c8a31

Please sign in to comment.