Permalink
Browse files

Docblocks and J version markers

  • Loading branch information...
1 parent 9cc13fa commit ff091642cf5b8d5b587f99a06fa9277272828db8 @elkuku committed Apr 27, 2012
Showing with 193 additions and 149 deletions.
  1. +3 −2 administrator/components/com_easycreator/controllers/stuffer.php
  2. +5 −5 administrator/components/com_easycreator/helpers/dbadapter/format/mysql.php
  3. +5 −5 administrator/components/com_easycreator/helpers/dbadapter/format/postgresql.php
  4. +5 −5 administrator/components/com_easycreator/helpers/dbadapter/format/sqlite.php
  5. +5 −5 administrator/components/com_easycreator/helpers/dbadapter/format/sqlsrv.php
  6. +6 −6 administrator/components/com_easycreator/helpers/deployer/type/ftp.php
  7. +10 −6 administrator/components/com_easycreator/helpers/deployer/type/github.php
  8. +5 −5 administrator/components/com_easycreator/helpers/ftp.php
  9. +5 −5 administrator/components/com_easycreator/helpers/github.php
  10. +6 −6 administrator/components/com_easycreator/helpers/github/downloads.php
  11. +9 −6 administrator/components/com_easycreator/helpers/github/http.php
  12. +6 −6 administrator/components/com_easycreator/helpers/github/response/downloads/get.php
  13. +2 −0 administrator/components/com_easycreator/helpers/language.php
  14. +8 −0 administrator/components/com_easycreator/helpers/project/base.php
  15. +16 −4 administrator/components/com_easycreator/helpers/project/manifest.php
  16. +1 −0 administrator/components/com_easycreator/helpers/project/type/cliapp.php
  17. +1 −0 administrator/components/com_easycreator/helpers/project/type/component.php
  18. +1 −0 administrator/components/com_easycreator/helpers/project/type/library.php
  19. +1 −0 administrator/components/com_easycreator/helpers/project/type/webapp.php
  20. +4 −2 administrator/components/com_easycreator/templates/parts/various/install_script/part.php
  21. +1 −1 administrator/components/com_easycreator/version.txt
  22. +11 −10 administrator/components/com_easycreator/views/codeeye/tmpl/default.php
  23. +9 −10 administrator/components/com_easycreator/views/deploy/tmpl/default.php
  24. +6 −6 administrator/components/com_easycreator/views/deploy/tmpl/default_ftp.php
  25. +6 −6 administrator/components/com_easycreator/views/deploy/tmpl/default_ftpcredentials.php
  26. +6 −6 administrator/components/com_easycreator/views/deploy/tmpl/default_githubcredentials.php
  27. +14 −8 administrator/components/com_easycreator/views/deploy/tmpl/package_archive.php
  28. +6 −6 administrator/components/com_easycreator/views/deploy/tmpl/package_ftp.php
  29. +6 −6 administrator/components/com_easycreator/views/deploy/tmpl/package_github.php
  30. +1 −1 administrator/components/com_easycreator/views/deploy/view.html.php
  31. +3 −2 administrator/components/com_easycreator/views/stuffer/tmpl/install_update.php
  32. +6 −6 administrator/components/com_easycreator/views/stuffer/tmpl/stuffer_deploy.php
  33. +2 −0 administrator/components/com_easycreator/views/stuffer/tmpl/stuffer_package.php
  34. +11 −13 administrator/components/com_easycreator/views/stuffer/tmpl/stuffer_update.php
  35. +1 −0 administrator/components/com_easycreator/views/ziper/tmpl/ziper_format.php
@@ -571,8 +571,9 @@ public function delete_project($complete = false)
//-- Get the project
try
{
- $project = EcrProjectHelper::getProject()
- ->remove($complete);
+ $project = EcrProjectHelper::getProject();
+
+ $project->remove($complete);
$this->setRedirect('index.php?option=com_easycreator'
, sprintf(jgettext('The Project %s has been removed'), $project->name));
@@ -1,8 +1,8 @@
<?php
/**
- * Created by JetBrains PhpStorm.
- * User: elkuku
- * Date: 14.01.12
- * Time: 03:27
- * To change this template use File | Settings | File Templates.
+ * @package EasyCreator
+ * @subpackage Helpers
+ * @author Nikolai Plath (elkuku)
+ * @author Created on 25-Apr-2011
+ * @license GNU/GPL, see JROOT/LICENSE.php
*/
@@ -1,8 +1,8 @@
<?php
/**
- * Created by JetBrains PhpStorm.
- * User: elkuku
- * Date: 14.01.12
- * Time: 04:53
- * To change this template use File | Settings | File Templates.
+ * @package EasyCreator
+ * @subpackage Helpers
+ * @author Nikolai Plath (elkuku)
+ * @author Created on 25-Apr-2011
+ * @license GNU/GPL, see JROOT/LICENSE.php
*/
@@ -1,8 +1,8 @@
<?php
/**
- * Created by JetBrains PhpStorm.
- * User: elkuku
- * Date: 14.01.12
- * Time: 03:27
- * To change this template use File | Settings | File Templates.
+ * @package EasyCreator
+ * @subpackage Helpers
+ * @author Nikolai Plath (elkuku)
+ * @author Created on 25-Apr-2011
+ * @license GNU/GPL, see JROOT/LICENSE.php
*/
@@ -1,8 +1,8 @@
<?php
/**
- * Created by JetBrains PhpStorm.
- * User: elkuku
- * Date: 14.01.12
- * Time: 04:53
- * To change this template use File | Settings | File Templates.
+ * @package EasyCreator
+ * @subpackage Helpers
+ * @author Nikolai Plath (elkuku)
+ * @author Created on 25-Apr-2011
+ * @license GNU/GPL, see JROOT/LICENSE.php
*/
@@ -1,10 +1,10 @@
-<?php
+<?php defined('_JEXEC') || die('=;)');
/**
- * Created by JetBrains PhpStorm.
- * User: elkuku
- * Date: 24.04.12
- * Time: 11:28
- * To change this template use File | Settings | File Templates.
+ * @package EasyCreator
+ * @subpackage Helpers
+ * @author Nikolai Plath (elkuku)
+ * @author Created on 25-Apr-2011
+ * @license GNU/GPL, see JROOT/LICENSE.php
*/
class EcrDeployerTypeFtp extends EcrDeployer
@@ -1,10 +1,14 @@
-<?php
+<?php defined('_JEXEC') || die('=;)');
/**
- * Created by JetBrains PhpStorm.
- * User: elkuku
- * Date: 24.04.12
- * Time: 11:43
- * To change this template use File | Settings | File Templates.
+ * @package EasyCreator
+ * @subpackage Helpers
+ * @author Nikolai Plath (elkuku)
+ * @author Created on 25-Apr-2011
+ * @license GNU/GPL, see JROOT/LICENSE.php
+ */
+
+/**
+ *
*/
class EcrDeployerTypeGithub extends EcrDeployer
{
@@ -1,10 +1,10 @@
<?php
/**
- * Created by JetBrains PhpStorm.
- * User: elkuku
- * Date: 18.04.12
- * Time: 16:15
- * To change this template use File | Settings | File Templates.
+ * @package EasyCreator
+ * @subpackage Helpers
+ * @author Nikolai Plath (elkuku)
+ * @author Created on 25-Apr-2011
+ * @license GNU/GPL, see JROOT/LICENSE.php
*/
jimport('joomla.client.ftp');
@@ -1,10 +1,10 @@
<?php
/**
- * Created by JetBrains PhpStorm.
- * User: elkuku
- * Date: 17.04.12
- * Time: 13:25
- * To change this template use File | Settings | File Templates.
+ * @package EasyCreator
+ * @subpackage Helpers
+ * @author Nikolai Plath (elkuku)
+ * @author Created on 25-Apr-2011
+ * @license GNU/GPL, see JROOT/LICENSE.php
*
* @property-read EcrGithubDownloads $downloads
*/
@@ -1,10 +1,10 @@
-<?php
+<?php defined('_JEXEC') || die('=;)');
/**
- * Created by JetBrains PhpStorm.
- * User: elkuku
- * Date: 17.04.12
- * Time: 13:37
- * To change this template use File | Settings | File Templates.
+ * @package EasyCreator
+ * @subpackage Helpers
+ * @author Nikolai Plath (elkuku)
+ * @author Created on 25-Apr-2011
+ * @license GNU/GPL, see JROOT/LICENSE.php
*/
/**
@@ -1,12 +1,15 @@
-<?php
+<?php defined('_JEXEC') || die('=;)');
/**
- * Created by JetBrains PhpStorm.
- * User: elkuku
- * Date: 18.04.12
- * Time: 17:56
- * To change this template use File | Settings | File Templates.
+ * @package EasyCreator
+ * @subpackage Helpers
+ * @author Nikolai Plath (elkuku)
+ * @author Created on 25-Apr-2011
+ * @license GNU/GPL, see JROOT/LICENSE.php
*/
+/**
+ *
+ */
class EcrGithubHttp extends JGithubHttp
{
/**
@@ -1,10 +1,10 @@
-<?php
+<?php defined('_JEXEC') || die('=;)');
/**
- * Created by JetBrains PhpStorm.
- * User: elkuku
- * Date: 17.04.12
- * Time: 17:08
- * To change this template use File | Settings | File Templates.
+ * @package EasyCreator
+ * @subpackage Helpers
+ * @author Nikolai Plath (elkuku)
+ * @author Created on 25-Apr-2011
+ * @license GNU/GPL, see JROOT/LICENSE.php
*/
/**
@@ -1111,6 +1111,7 @@ private function _buildFileList()
if(JFolder::exists($copyItem))
{
//--Add all PHP and XML files from a given folder
+ //-- @Joomla!-version-check
switch($this->project->JCompat)
{
case '1.5' :
@@ -1487,6 +1488,7 @@ public static function createFileFromRequest()
$fileName = self::getFileName($lang, $scope, $project);
+ //-- @Joomla!-compat 1.5
$commentChar =($project->JCompat == '1.5') ? '#' : ';';
$fileContents = '';
@@ -17,6 +17,11 @@
public $method = '';
+ /**
+ * Joomla! compatibility mode
+ * @Joomla!-compat 1.5
+ * @var string
+ */
public $JCompat = '1.5';
public $phpVersion = '4';
@@ -906,7 +911,10 @@ private function readProjectXml($projectName)
$this->scope = (string)$manifest->attributes()->scope;
$this->name = (string)$manifest->name;
$this->comName = (string)$manifest->comname;
+
+ //-- @Joomla!-compat 1.5
$this->JCompat = ((string)$manifest->JCompat) ? (string)$manifest->JCompat : '1.5';
+
$this->langFormat = (string)$manifest->langFormat;
$this->zipPath = (string)$manifest->zipPath;
$this->headerType = (string)$manifest->headerType;
@@ -49,17 +49,19 @@ public function create(EcrProjectBase $project)
$rootTag = '';
+ //-- @Joomla!-version-check
switch($this->project->JCompat)
{
+ case '1.5':
+ $rootTag = 'install';
+ break;
+
case '1.6':
case '1.7':
case '2.5':
$rootTag = 'extension';
break;
- case '1.5':
- $rootTag = 'install';
- break;
default:
JFactory::getApplication()->enqueueMessage(
__METHOD__.'Unknown JCompat: '.$this->project->JCompat, 'error');
@@ -233,6 +235,7 @@ private function processInstall()
$installFiles = EcrProjectHelper::findInstallFiles($this->project);
//-- PHP install scripts
+ //-- @Joomla!-version-check
switch($this->project->JCompat)
{
case '1.5':
@@ -258,11 +261,13 @@ private function processInstall()
$uninstall = $this->manifest->addChild('uninstall');
$uninstallSql = $uninstall->addChild('sql');
+ //-- @Joomla!-version-check
switch($this->project->JCompat)
{
case '1.6':
case '1.7':
- //-- J! 1.6 update stuff
+ case '2.5':
+ //-- J! 1.6+ update stuff
$update = $this->manifest->addChild('update');
$updateSql = $update->addChild('schemas');
@@ -279,6 +284,8 @@ private function processInstall()
break;
default:
+ JFactory::getApplication()->enqueueMessage(
+ __METHOD__.'Unknown JCompat: '.$this->project->JCompat, 'error');
break;
}
@@ -475,6 +482,7 @@ private function processSite()
}
}
+ //-- @Joomla!-compat 1.5
if(count($languageFiles)
&& $this->project->JCompat == '1.5'
)
@@ -539,6 +547,7 @@ private function processAdmin()
$menu->addAttribute('img', $s);
}
+ //-- @Joomla!-compat 1.5
if(isset($def_menu['link'])
&& $this->project->JCompat == '1.5'
)
@@ -578,6 +587,7 @@ private function processAdmin()
$menu->addAttribute('img', $s);
}
+ //-- @Joomla!-version-check
switch($this->project->JCompat)
{
case '1.5' :
@@ -644,6 +654,7 @@ private function processAdmin()
}
}
+ //-- @Joomla!-compat 1.5
if(count($languageFiles)
&& $this->project->JCompat == '1.5'
)
@@ -800,6 +811,7 @@ private function processParameters()
if('template' == $this->project->type)
{
+ //-- @Joomla!-version-check
switch($this->project->JCompat)
{
case '1.5':
@@ -22,6 +22,7 @@ class EcrProjectTypeCliapp extends EcrProjectBase
*/
public $prefix = 'cap_';
+ //-- @Joomla!-compat 1.6
public $JCompat = '1.6';
/**
@@ -124,6 +124,7 @@ public function getLanguagePaths($scope = '')
return $paths;
}
+ //-- @Joomla!-version-check
switch($this->JCompat)
{
case '1.5':
@@ -29,6 +29,7 @@ class EcrProjectTypeLibrary extends EcrProjectBase
*/
public $prefix = 'lib_';
+ //-- @Joomla!-compat 1.6
public $JCompat = '1.6';
/**
@@ -22,6 +22,7 @@ class EcrProjectTypeWebapp extends EcrProjectBase
*/
public $prefix = 'wap_';
+ //-- @Joomla!-compat 1.6
public $JCompat = '1.6';
/**
@@ -41,14 +41,14 @@ public function getOptions()
{
$project = EcrProjectHelper::getProject();
+ //-- @Joomla!-compat 1.5
if('1.5' == $project->JCompat)
{
- EcrHtml::displayMessage(jgettext('Install scripts are avilable from Joomla! 1.6 + projects'), 'error');
+ EcrHtml::displayMessage(jgettext('Install scripts are available for Joomla! 1.6 + projects only'), 'error');
return false;
}
-// var_dump($project);
$ecr_project = JRequest::getCmd('ecr_project');
$basePathDest = JPATH_ROOT.DS.'administrator'.DS.'components'.DS.$ecr_project;
@@ -62,6 +62,8 @@ public function getOptions()
EcrHtml::drawLoggingOptions();
EcrHtml::drawSubmitParts();
+
+ return $this;
}//function
/**
@@ -1 +1 @@
-0.0.16-23-g5acf544
+0.0.16-24-g9cc13fa
Oops, something went wrong. Retry.

0 comments on commit ff09164

Please sign in to comment.