release 1.4

This commit is contained in:
Jean-Christian Denis 2023-10-07 21:45:14 +02:00
parent ef32e07197
commit bec0ff9b4f
Signed by: JcDenis
GPG key ID: 1B5B8C5B90B6C951
6 changed files with 21 additions and 15 deletions

View file

@ -1,3 +1,9 @@
tinyPacker 1.4 - 2023.10.07
===========================================================
* Require Dotclear 2.28
* Require PHP 8.1
* Update to Dotclear 2.28
tinyPacker 1.3 - 2023.08.13
===========================================================
* Require Dotclear 2.27

View file

@ -1,8 +1,8 @@
# README
[![Release](https://img.shields.io/badge/release-1.3-a2cbe9.svg)](https://git.dotclear.watch/JcDenis/tinyPacker/releases)
[![Date](https://img.shields.io/badge/date-2023.08.13-c44d58.svg)](https://git.dotclear.watch/JcDenis/tinyPacker/releases)
[![Dotclear](https://img.shields.io/badge/dotclear-v2.27-137bbb.svg)](https://fr.dotclear.org/download)
[![Release](https://img.shields.io/badge/release-1.4-a2cbe9.svg)](https://git.dotclear.watch/JcDenis/tinyPacker/releases)
[![Date](https://img.shields.io/badge/date-2023.10.07-c44d58.svg)](https://git.dotclear.watch/JcDenis/tinyPacker/releases)
[![Dotclear](https://img.shields.io/badge/dotclear-v2.28-137bbb.svg)](https://fr.dotclear.org/download)
[![Dotaddict](https://img.shields.io/badge/dotaddict-official-9ac123.svg)](https://plugins.dotaddict.org/dc2/details/tinyPacker)
[![License](https://img.shields.io/github/license/JcDenis/tinyPacker)](https://git.dotclear.watch/JcDenis/tinyPacker/blob/master/LICENSE)
@ -20,8 +20,8 @@ _tinyPacker_ requires:
* Super administrator permissions
* A writable public directory.
* Dotclear 2.27
* PHP 7.4+
* Dotclear 2.28
* PHP 8.1+
## USAGE

View file

@ -18,9 +18,9 @@ $this->registerModule(
'Tiny packer',
'Quick pack theme or plugin into public dir',
'Jean-Christian Denis',
'1.3',
'1.4',
[
'requires' => [['core', '2.27']],
'requires' => [['core', '2.28']],
'permissions' => null,
'type' => 'plugin',
'support' => 'https://git.dotclear.watch/JcDenis/' . basename(__DIR__) . '/issues',

View file

@ -2,11 +2,11 @@
<modules xmlns:da="http://dotaddict.org/da/">
<module id="tinyPacker">
<name>Tiny packer</name>
<version>1.3</version>
<version>1.4</version>
<author>Jean-Christian Denis</author>
<desc>Quick pack theme or plugin into public dir</desc>
<file>https://git.dotclear.watch/JcDenis/tinyPacker/releases/download/v1.3/plugin-tinyPacker.zip</file>
<da:dcmin>2.27</da:dcmin>
<file>https://git.dotclear.watch/JcDenis/tinyPacker/releases/download/v1.4/plugin-tinyPacker.zip</file>
<da:dcmin>2.28</da:dcmin>
<da:details>https://git.dotclear.watch/JcDenis/tinyPacker/src/branch/master/README.md</da:details>
<da:support>https://git.dotclear.watch/JcDenis/tinyPacker/issues</da:support>
</module>

View file

@ -14,7 +14,7 @@ declare(strict_types=1);
namespace Dotclear\Plugin\tinyPacker;
use dcCore;
use Dotclear\App;
use Dotclear\Core\Process;
use Dotclear\Core\Backend\ModulesList;
use Dotclear\Core\Backend\Notices;
@ -44,7 +44,7 @@ class Backend extends Process
return false;
}
dcCore::app()->addBehaviors([
App::behavior()->addBehaviors([
'adminModulesListGetActions' => function (ModulesList $list, string $id, array $_): string {
return in_array($list->getList(), [
'plugin-activate',
@ -60,7 +60,7 @@ class Backend extends Process
# Repository directory
$dir = (string) Path::real(
dcCore::app()->blog->public_path . DIRECTORY_SEPARATOR . My::TINYPACKER_DIR,
App::blog()->publicPath() . DIRECTORY_SEPARATOR . My::TINYPACKER_DIR,
false
);
if (!empty($dir) && !is_dir($dir)) {

View file

@ -14,7 +14,7 @@ declare(strict_types=1);
namespace Dotclear\Plugin\tinyPacker;
use dcCore;
use Dotclear\App;
use Dotclear\Module\MyPlugin;
class My extends MyPlugin
@ -39,6 +39,6 @@ class My extends MyPlugin
public static function checkCustomContext(int $context): ?bool
{
return defined('DC_CONTEXT_ADMIN') && dcCore::app()->auth->isSuperAdmin();
return defined('DC_CONTEXT_ADMIN') && App::auth()->isSuperAdmin();
}
}