From 62da6342b391902baadc7edefa2ce6e9fe2d7914 Mon Sep 17 00:00:00 2001 From: Jephte Clain Date: Thu, 28 Nov 2024 21:24:16 +0400 Subject: [PATCH] =?UTF-8?q?revenir=20=C3=A0=20nur/sery=20pour=20faciliter?= =?UTF-8?q?=20la=20migration?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .idea/nur-ture.iml | 6 +-- TODO.md | 2 +- bbnurse | 22 +++++----- composer.json | 6 +-- composer.lock | 6 +-- nur_bin/steam-train.php | 2 +- nur_src/b/io/FileCachedValue.php | 4 +- nur_src/b/io/TmpfileWriter.php | 2 +- nur_src/cli/Application.php | 2 +- nur_src/ldap/LdapSearch.php | 2 +- nur_src/ldap/app/LdapDeleteApp.php | 2 +- nur_src/ldap/ldap_server.php | 2 +- nur_src/ldap/schemas/LseAttribute.php | 2 +- nur_src/ldap/schemas/LseObjectClass.php | 2 +- nur_src/ldap/schemas/LseSyntax.php | 2 +- nur_src/m/pdo/mysql/MysqlQuery.php | 2 +- nur_src/ref/ref_type.php | 5 +-- nur_tbin/base/test-args4.php | 2 +- sbin/update_classes.php | 2 +- src/php/access/AbstractAccess.php | 4 +- src/php/access/FormAccess.php | 4 +- src/php/access/GetAccess.php | 4 +- src/php/access/IAccess.php | 2 +- src/php/access/IDeleter.php | 2 +- src/php/access/IGetter.php | 2 +- src/php/access/ISetter.php | 2 +- src/php/access/KeyAccess.php | 4 +- src/php/access/PostAccess.php | 4 +- src/php/access/ShadowAccess.php | 2 +- src/php/access/ValueAccess.php | 2 +- src/schema/OldSchema.php | 2 +- src/schema/README.md | 2 +- src/schema/Result.php | 8 ++-- src/schema/Schema.php | 12 +++--- src/schema/SchemaException.php | 2 +- src/schema/TODO.md | 2 +- src/schema/Value.php | 10 ++--- src/schema/_assoc/AssocResult.php | 4 +- src/schema/_assoc/AssocSchema.php | 10 ++--- src/schema/_assoc/AssocValue.php | 6 +-- src/schema/_list/ListResult.php | 4 +- src/schema/_list/ListSchema.php | 8 ++-- src/schema/_list/ListValue.php | 6 +-- src/schema/_scalar/ScalarResult.php | 12 +++--- src/schema/_scalar/ScalarSchema.php | 26 ++++++------ src/schema/_scalar/ScalarValue.php | 14 +++---- src/schema/input/FormInput.php | 10 ++--- src/schema/input/GetInput.php | 6 +-- src/schema/input/Input.php | 8 ++-- src/schema/input/PostInput.php | 6 +-- src/schema/types.php | 18 ++++---- src/schema/types/IType.php | 8 ++-- src/schema/types/Registry.php | 4 +- src/schema/types/_tsimple.php | 4 +- src/schema/types/tarray.php | 8 ++-- src/schema/types/tbool.php | 16 ++++---- src/schema/types/tcallable.php | 10 ++--- src/schema/types/tcontent.php | 6 +-- src/schema/types/tfloat.php | 10 ++--- src/schema/types/tint.php | 10 ++--- src/schema/types/tkey.php | 6 +-- src/schema/types/tpkey.php | 6 +-- src/schema/types/tstring.php | 10 ++--- src/web/content/Tag.php | 8 ++-- src/web/content/v.php | 2 +- src_app/app.php | 4 +- src_app/app/cli/Application.php | 4 +- support/template-.launcher.php | 2 +- support/template-_bg_launcher.php | 4 +- tests/app/argsTest.php | 4 +- tests/appTest.php | 26 ++++++------ tests/db/sqlite/SqliteStorageTest.php | 8 ++-- tests/db/sqlite/SqliteTest.php | 2 +- tests/db/sqlite/_queryTest.php | 2 +- tests/file/base/FileReaderTest.php | 4 +- tests/php/access/KeyAccessTest.php | 4 +- tests/php/access/ValueAccessTest.php | 4 +- tests/php/content/cTest.php | 6 +-- tests/php/content/impl/AContent.php | 4 +- tests/php/content/impl/APrintable.php | 4 +- tests/php/content/impl/ATag.php | 6 +-- tests/php/content/impl/html.php | 2 +- tests/php/funcTest.php | 50 +++++++++++------------ tests/php/nur_funcTest.php | 2 +- tests/php/time/DateTest.php | 2 +- tests/php/time/DateTimeTest.php | 2 +- tests/php/time/DelayTest.php | 2 +- tests/schema/_scalar/ScalarSchemaTest.php | 6 +-- tests/schema/types/boolTest.php | 6 +-- tests/schema/types/floatTest.php | 6 +-- tests/schema/types/intTest.php | 6 +-- tests/schema/types/strTest.php | 6 +-- tests/schema/types/unionTest.php | 6 +-- tests/strTest.php | 2 +- tests/web/uploadsTest.php | 2 +- 95 files changed, 289 insertions(+), 290 deletions(-) diff --git a/.idea/nur-ture.iml b/.idea/nur-ture.iml index 4c55568..34c43ad 100644 --- a/.idea/nur-ture.iml +++ b/.idea/nur-ture.iml @@ -4,9 +4,9 @@ - - - + + + diff --git a/TODO.md b/TODO.md index 4bec4f1..6a61f80 100644 --- a/TODO.md +++ b/TODO.md @@ -1,6 +1,6 @@ # TODO -* [ ] bbnurse -cmk supprime la classe dans nur\ture après l'avoir copié dans la +* [ ] bbnurse -cmk supprime la classe dans nur\sery après l'avoir copié dans la destination diff --git a/bbnurse b/bbnurse index 0b14ae2..eaa0a6f 100755 --- a/bbnurse +++ b/bbnurse @@ -18,7 +18,7 @@ function copy_mature() { if [ -f "$src" ]; then # fichier setx src=abspath "$src" - [ "${src#$MYDIR/src/}" != "$src" ] || die "la source doit être dans nur-ture/src/" + [ "${src#$MYDIR/src/}" != "$src" ] || die "la source doit être dans nur-sery/src/" src="${src#$MYDIR/src/}" if [[ "$src" == */* ]]; then path="${src%/*}" @@ -33,25 +33,25 @@ function copy_mature() { elif [ -d "$src" ]; then # répertoire de package setx src=abspath "$src" - [ "$src" == "$MYDIR/src" -o "${src#$MYDIR/src/}" != "$src" ] || die "la source doit être dans nur-ture/src/" + [ "$src" == "$MYDIR/src" -o "${src#$MYDIR/src/}" != "$src" ] || die "la source doit être dans nur-sery/src/" srcdir="$src" path="${src#$MYDIR/src}"; path="${path#/}" else # package src="${src//\\\\/\/}" src="${src%/}" - [ -d "$MYDIR/src/$src" ] || die "la source doit être un package de nur-ture" + [ -d "$MYDIR/src/$src" ] || die "la source doit être un package de nur-sery" srcdir="$MYDIR/src/$src" path="$src" fi tsrcdir= - nurturepackage='nur\ture'; nulibpackage='nulib' + nurturepackage='nur\sery'; nulibpackage='nulib' if [ -n "$path" ]; then - srcpackage="nur/ture/$path"; srcpackage="${srcpackage//\//\\}" + srcpackage="nur/sery/$path"; srcpackage="${srcpackage//\//\\}" destpackage="nulib/$path"; destpackage="${destpackage//\//\\}" [ -d "$MYDIR/tests/$path" ] && tsrcdir="$MYDIR/tests/$path" else - srcpackage='nur\ture' + srcpackage='nur\sery' destpackage='nulib' fi @@ -134,11 +134,11 @@ function nulib_sync_mature() { estep "Mise à jour des packages" setx -a dests=find "$destdir/src/" -type f for dest in "${dests[@]}"; do - sed -i 's|nur\\ture|nulib|g' "$dest" + sed -i 's|nur\\sery|nulib|g' "$dest" done setx -a dests=find "$destdir/tests/" -type f for dest in "${dests[@]}"; do - sed -i 's|nur\\ture|nulib|g' "$dest" + sed -i 's|nur\\sery|nulib|g' "$dest" done } @@ -147,7 +147,7 @@ function update_nurse() { } function update_mature() { - srcpackage='nur\ture' + srcpackage='nur\sery' destpackage='nulib' if [ -n "$Dest" ]; then @@ -202,7 +202,7 @@ Pour chaque type d'évolution, il y a deux actions possibles: * DEST est le répertoire du projet nulib-* ou le répertoire courant sinon * mettre à jour (-u) * mettre en nurserie (-un) met à jour les sources d'un projet pour utiliser la - version de nur/ture + version de nur/sery * arriver à maturation (-um) met à jour les sources d'un projet pour utiliser la version mature à maturation L'argument est un 'package' ou un 'sous\\package' (dont le nom commence par @@ -212,7 +212,7 @@ Pour chaque type d'évolution, il y a deux actions possibles: -u,--update action=update "Mettre à jour un projet. C'est l'option par défaut" -i,-n,--nurse evolution=nurse "Mettre en nurserie" -x,-m,--mature evolution=mature "Arriver à maturation. C'est l'option par défaut" - --sm '$action=nulib_sync; evolution=mature' "Maturation complète vers nulib. Equivalent à '-cm nur/ture -d ../nulib' mais omet le package nur\\ture\\wip" + --sm '$action=nulib_sync; evolution=mature' "Maturation complète vers nulib. Equivalent à '-cm nur/sery -d ../nulib' mais omet le package nur\\sery\\wip" ) parse_args "$@"; set -- "${args[@]}" diff --git a/composer.json b/composer.json index d5b17a2..d7ac199 100644 --- a/composer.json +++ b/composer.json @@ -53,8 +53,8 @@ }, "autoload": { "psr-4": { - "nur\\ture\\wip\\": "src", - "nur\\ture\\": "src_app", + "nur\\sery\\wip\\": "src", + "nur\\sery\\": "src_app", "nur\\": "nur_src" }, "files": [ @@ -63,7 +63,7 @@ }, "autoload-dev": { "psr-4": { - "nur\\ture\\": "tests", + "nur\\sery\\": "tests", "nur\\": "nur_tests" } }, diff --git a/composer.lock b/composer.lock index cc96aab..eef96bd 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "59f960588ea6ef57b3974fbfc65b7d17", + "content-hash": "fd786c1eb69e14f16916905711daf8ca", "packages": [], "packages-dev": [ { @@ -510,7 +510,7 @@ "source": { "type": "git", "url": "https://git.univ-reunion.fr/sda-php/nulib.git", - "reference": "2a35a6de7105ab2e14edf912d3c47de1513da6d2" + "reference": "325391d60c2ed3a6ead71992d98aa2ce205bd293" }, "require": { "php": "^7.4" @@ -545,7 +545,7 @@ } ], "description": "fonctions et classes essentielles", - "time": "2024-11-28T15:57:48+00:00" + "time": "2024-11-28T16:58:43+00:00" }, { "name": "nulib/phpss", diff --git a/nur_bin/steam-train.php b/nur_bin/steam-train.php index 849d5ac..dbde68a 100755 --- a/nur_bin/steam-train.php +++ b/nur_bin/steam-train.php @@ -2,6 +2,6 @@ [ - "package" => "nur\\ture\\", + "package" => "nur\\sery\\", "path" => __DIR__."/../src", "classes" => [ ], diff --git a/src/php/access/AbstractAccess.php b/src/php/access/AbstractAccess.php index 1f39716..d9df3db 100644 --- a/src/php/access/AbstractAccess.php +++ b/src/php/access/AbstractAccess.php @@ -1,7 +1,7 @@ __DIR__ . '/..', "appcode" => \app\config\bootstrap::APPCODE, ]; -require __DIR__.'/../vendor/nur/ture/src/app/cli/include-launcher.php'; +require __DIR__.'/../vendor/nur/sery/src/app/cli/include-launcher.php'; diff --git a/support/template-_bg_launcher.php b/support/template-_bg_launcher.php index a5f4a17..c627a47 100644 --- a/support/template-_bg_launcher.php +++ b/support/template-_bg_launcher.php @@ -5,8 +5,8 @@ require __DIR__.'/../vendor/autoload.php'; # Lancer une application en tâche de fond -use nur\ture\tools\BgLauncherApp; -use nur\ture\app; +use nur\sery\tools\BgLauncherApp; +use nur\sery\app; # chemin vers le lanceur PHP const NULIB_APP_app_launcher = __DIR__.'/../_cli/.launcher.php'; diff --git a/tests/app/argsTest.php b/tests/app/argsTest.php index 7eb1cf7..b2bdef1 100644 --- a/tests/app/argsTest.php +++ b/tests/app/argsTest.php @@ -1,9 +1,9 @@ "$projdir/vendor/bin", "autoload" => "$projdir/vendor/autoload.php", ], - "appcode" => "nur-ture", + "appcode" => "nur-sery", "cwd" => $cwd, "datadir" => "$projdir/devel", "etcdir" => "$projdir/devel/etc", @@ -38,7 +38,7 @@ namespace nur\ture { "bindir" => "$projdir/vendor/bin", "autoload" => "$projdir/vendor/autoload.php", ], - "appcode" => "nur-ture", + "appcode" => "nur-sery", "cwd" => $cwd, "datadir" => "$projdir/devel", "etcdir" => "$projdir/devel/etc", @@ -63,7 +63,7 @@ namespace nur\ture { "bindir" => "$projdir/vendor/bin", "autoload" => "$projdir/vendor/autoload.php", ], - "appcode" => "nur-ture", + "appcode" => "nur-sery", "cwd" => $cwd, "datadir" => "$projdir/devel", "etcdir" => "$projdir/devel/etc", @@ -82,7 +82,7 @@ namespace nur\ture { "bindir" => "$projdir/vendor/bin", "autoload" => "$projdir/vendor/autoload.php", ], - "appcode" => "nur-ture", + "appcode" => "nur-sery", "cwd" => $cwd, "datadir" => "$projdir/devel", "etcdir" => "$projdir/devel/etc", @@ -97,11 +97,11 @@ namespace nur\ture { } } -namespace nur\ture\impl { +namespace nur\sery\impl { - use nur\ture\app\cli\Application; - use nur\ture\os\path; - use nur\ture\app; + use nur\sery\app\cli\Application; + use nur\sery\os\path; + use nur\sery\app; class config { const PROJDIR = __DIR__.'/..'; diff --git a/tests/db/sqlite/SqliteStorageTest.php b/tests/db/sqlite/SqliteStorageTest.php index 4f87b84..8461de0 100644 --- a/tests/db/sqlite/SqliteStorageTest.php +++ b/tests/db/sqlite/SqliteStorageTest.php @@ -1,10 +1,10 @@