From d6acd10ab9b281babc6c65d29d217a596382a725 Mon Sep 17 00:00:00 2001 From: Andy Fragen Date: Wed, 13 Nov 2024 17:26:42 -0800 Subject: [PATCH 01/10] Decoupled translations using `afragen/translations-updater` dependency (#178) Moved translations into separate repo and using git updater code to load translations off github repo translations. --------- Signed-off-by: Andy Fragen --- .gitignore | 5 +- aspire-update.php | 17 ++ composer.json | 36 ++-- composer.lock | 149 ++++++++++++--- languages/AspireUpdate-ca_ES.po | 162 ---------------- languages/AspireUpdate-de_DE.I10n.php | 27 --- languages/AspireUpdate-de_DE.mo | Bin 3283 -> 0 bytes languages/AspireUpdate-de_DE.po | 142 -------------- languages/AspireUpdate-es_ES.po | 145 --------------- languages/AspireUpdate-fr_FR.l10n.php | 2 - languages/AspireUpdate-fr_FR.mo | Bin 3260 -> 0 bytes languages/AspireUpdate-fr_FR.po | 163 ---------------- languages/AspireUpdate-nl_NL.l10n.php | 2 - languages/AspireUpdate-nl_NL.mo | Bin 3200 -> 0 bytes languages/AspireUpdate-nl_NL.po | 165 ----------------- languages/AspireUpdate-sv_SE.mo | Bin 2449 -> 0 bytes languages/AspireUpdate-sv_SE.po | 134 -------------- languages/AspireUpdate-zh_TW.l10n.php | 4 - languages/AspireUpdate-zh_TW.mo | Bin 2659 -> 0 bytes languages/AspireUpdate-zh_TW.po | 131 ------------- languages/AspireUpdate.pot | 106 +++++++---- vendor/afragen/autoloader/Autoloader.php | 135 ++++++++++++++ vendor/afragen/autoloader/CHANGES.md | 17 ++ vendor/afragen/autoloader/LICENSE | 21 +++ vendor/afragen/autoloader/README.md | 24 +++ vendor/afragen/autoloader/composer.json | 28 +++ .../afragen/translations-updater/CHANGES.md | 19 ++ vendor/afragen/translations-updater/LICENSE | 21 +++ vendor/afragen/translations-updater/README.md | 103 +++++++++++ .../translations-updater/composer.json | 55 ++++++ .../src/Translations_Updater/API.php | 175 ++++++++++++++++++ .../src/Translations_Updater/Base.php | 114 ++++++++++++ .../src/Translations_Updater/Init.php | 113 +++++++++++ .../Translations_Updater/Language_Pack.php | 120 ++++++++++++ .../Language_Pack_API.php | 155 ++++++++++++++++ 35 files changed, 1332 insertions(+), 1158 deletions(-) delete mode 100644 languages/AspireUpdate-ca_ES.po delete mode 100644 languages/AspireUpdate-de_DE.I10n.php delete mode 100644 languages/AspireUpdate-de_DE.mo delete mode 100644 languages/AspireUpdate-de_DE.po delete mode 100644 languages/AspireUpdate-es_ES.po delete mode 100644 languages/AspireUpdate-fr_FR.l10n.php delete mode 100644 languages/AspireUpdate-fr_FR.mo delete mode 100644 languages/AspireUpdate-fr_FR.po delete mode 100644 languages/AspireUpdate-nl_NL.l10n.php delete mode 100644 languages/AspireUpdate-nl_NL.mo delete mode 100644 languages/AspireUpdate-nl_NL.po delete mode 100644 languages/AspireUpdate-sv_SE.mo delete mode 100644 languages/AspireUpdate-sv_SE.po delete mode 100644 languages/AspireUpdate-zh_TW.l10n.php delete mode 100644 languages/AspireUpdate-zh_TW.mo delete mode 100644 languages/AspireUpdate-zh_TW.po create mode 100644 vendor/afragen/autoloader/Autoloader.php create mode 100644 vendor/afragen/autoloader/CHANGES.md create mode 100644 vendor/afragen/autoloader/LICENSE create mode 100644 vendor/afragen/autoloader/README.md create mode 100644 vendor/afragen/autoloader/composer.json create mode 100644 vendor/afragen/translations-updater/CHANGES.md create mode 100644 vendor/afragen/translations-updater/LICENSE create mode 100644 vendor/afragen/translations-updater/README.md create mode 100644 vendor/afragen/translations-updater/composer.json create mode 100644 vendor/afragen/translations-updater/src/Translations_Updater/API.php create mode 100644 vendor/afragen/translations-updater/src/Translations_Updater/Base.php create mode 100644 vendor/afragen/translations-updater/src/Translations_Updater/Init.php create mode 100644 vendor/afragen/translations-updater/src/Translations_Updater/Language_Pack.php create mode 100644 vendor/afragen/translations-updater/src/Translations_Updater/Language_Pack_API.php diff --git a/.gitignore b/.gitignore index 814b1e0..8fefb59 100644 --- a/.gitignore +++ b/.gitignore @@ -3,7 +3,7 @@ # Files and folders related to build and test tools. .phpunit.result.cache /phpunit.xml -/vendor +/vendor/* .cache/* /tests/phpunit/cache /tests/phpunit/coverage @@ -11,3 +11,6 @@ # Track placeholders so that empty directories stay in the repo. !.gitkeep + +# Decoupled translation updating. +!/vendor/afragen diff --git a/aspire-update.php b/aspire-update.php index f908326..4bbcaad 100644 --- a/aspire-update.php +++ b/aspire-update.php @@ -58,3 +58,20 @@ function aspire_update_uninstall_hook() { $admin_settings = AspireUpdate\Admin_Settings::get_instance(); $admin_settings->delete_all_settings(); } + +// Load and start translations updater. +add_action( 'init', 'aspireupdate_init_translations' ); +function aspireupdate_init_translations() { + require_once __DIR__ . '/vendor/afragen/autoloader/Autoloader.php'; + new Fragen\Autoloader( [ 'Fragen\\Translations_Updater' => __DIR__ . '/vendor/afragen/translations-updater/src/Translations_Updater' ] ); + $config = [ + 'git' => 'github', + 'type' => 'plugin', + 'slug' => 'aspireupdate', + 'version' => AP_VERSION, // Current version of plugin|theme. + 'languages' => 'https://github.com/aspirepress/aspireupdate-translations', + 'branch' => 'main', + ]; + + ( new \Fragen\Translations_Updater\Init() )->run( $config ); +} diff --git a/composer.json b/composer.json index f460e06..69c86e5 100644 --- a/composer.json +++ b/composer.json @@ -1,5 +1,4 @@ { - "name": "aspirepress/aspire-update", "description": "Update plugins and themes for WordPress.", "type": "wordpress-plugin", @@ -10,25 +9,30 @@ } ], "require": { - "php": ">=7.4.0" + "php": ">=7.4.0", + "afragen/autoloader": "dev-master", + "afragen/translations-updater": "^1" }, "require-dev": { - - "squizlabs/php_codesniffer": "3.10.3", - "wp-coding-standards/wpcs": "~3.1.0", + "squizlabs/php_codesniffer": "3.10.3", + "wp-coding-standards/wpcs": "~3.1.0", "yoast/phpunit-polyfills": "^1.1.0" }, - "config": { - "allow-plugins": { - "dealerdirect/phpcodesniffer-composer-installer": true - } - }, + "config": { + "allow-plugins": { + "dealerdirect/phpcodesniffer-composer-installer": true + } + }, "scripts": { - "format": "@php ./vendor/squizlabs/php_codesniffer/bin/phpcbf --report=summary,source", - "lint": "@php ./vendor/squizlabs/php_codesniffer/bin/phpcs --report=summary, source", - "test": [ "Composer\\Config::disableProcessTimeout", "@php ./vendor/phpunit/phpunit/phpunit" ], - "test:multisite": [ "Composer\\Config::disableProcessTimeout", "@php ./vendor/phpunit/phpunit/phpunit -c tests/phpunit/multisite.xml" ] + "format": "@php ./vendor/squizlabs/php_codesniffer/bin/phpcbf --report=summary,source", + "lint": "@php ./vendor/squizlabs/php_codesniffer/bin/phpcs --report=summary,source", + "test": [ + "Composer\\Config::disableProcessTimeout", + "@php ./vendor/phpunit/phpunit/phpunit" + ], + "test:multisite": [ + "Composer\\Config::disableProcessTimeout", + "@php ./vendor/phpunit/phpunit/phpunit -c tests/multisite.xml" + ] } - - } diff --git a/composer.lock b/composer.lock index 0af7c9c..b196fe0 100644 --- a/composer.lock +++ b/composer.lock @@ -4,9 +4,103 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - - "content-hash": "ee8f3669b94f591108fa37dfcf3db475", - "packages": [], + "content-hash": "2d376331f9e6e6c82ad7397106adb6eb", + "packages": [ + { + "name": "afragen/autoloader", + "version": "dev-master", + "source": { + "type": "git", + "url": "https://github.com/afragen/autoloader.git", + "reference": "ec56498d42f0694d3ad1207a496bf69cbb0ebc2f" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/afragen/autoloader/zipball/ec56498d42f0694d3ad1207a496bf69cbb0ebc2f", + "reference": "ec56498d42f0694d3ad1207a496bf69cbb0ebc2f", + "shasum": "" + }, + "require": { + "php": ">=5.6" + }, + "default-branch": true, + "type": "library", + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Andy Fragen", + "email": "andy@thefragens.com", + "homepage": "https://thefragens.com", + "role": "Developer" + } + ], + "description": "PSR-4 style autoloader and classmap loader.", + "keywords": [ + "autoload" + ], + "support": { + "issues": "https://github.com/afragen/autoloader/issues", + "source": "https://github.com/afragen/autoloader/tree/master" + }, + "time": "2024-11-10T22:55:51+00:00" + }, + { + "name": "afragen/translations-updater", + "version": "1.0.1", + "source": { + "type": "git", + "url": "https://github.com/afragen/translations-updater.git", + "reference": "0bde072a1bf92ddc43837f6a27b9475b651350ea" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/afragen/translations-updater/zipball/0bde072a1bf92ddc43837f6a27b9475b651350ea", + "reference": "0bde072a1bf92ddc43837f6a27b9475b651350ea", + "shasum": "" + }, + "require": { + "php": ">=5.4" + }, + "require-dev": { + "wp-coding-standards/wpcs": "^3.0.0" + }, + "type": "library", + "autoload": { + "psr-4": { + "Fragen\\Translations_Updater\\": "src/Translations_Updater/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Andy Fragen", + "email": "andy@thefragens.com", + "homepage": "https://thefragens.com", + "role": "Developer" + } + ], + "description": "This framework provides automatic decoupled languate pack updates from a public repository for your WordPress plugin or theme.", + "keywords": [ + "language pack", + "plugin", + "theme", + "translations", + "updater", + "wordpress" + ], + "support": { + "issues": "https://github.com/afragen/translations-updater/issues", + "source": "https://github.com/afragen/translations-updater" + }, + "time": "2024-11-13T00:36:43+00:00" + } + ], "packages-dev": [ { "name": "dealerdirect/phpcodesniffer-composer-installer", @@ -87,32 +181,31 @@ "time": "2023-01-05T11:28:13+00:00" }, { - "name": "doctrine/instantiator", - "version": "1.5.0", + "version": "2.0.0", "source": { "type": "git", "url": "https://github.com/doctrine/instantiator.git", - "reference": "0a0fa9780f5d4e507415a065172d26a98d02047b" + "reference": "c6222283fa3f4ac679f8b9ced9a4e23f163e80d0" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/doctrine/instantiator/zipball/0a0fa9780f5d4e507415a065172d26a98d02047b", - "reference": "0a0fa9780f5d4e507415a065172d26a98d02047b", + "url": "https://api.github.com/repos/doctrine/instantiator/zipball/c6222283fa3f4ac679f8b9ced9a4e23f163e80d0", + "reference": "c6222283fa3f4ac679f8b9ced9a4e23f163e80d0", "shasum": "" }, "require": { - "php": "^7.1 || ^8.0" + "php": "^8.1" }, "require-dev": { - "doctrine/coding-standard": "^9 || ^11", + "doctrine/coding-standard": "^11", "ext-pdo": "*", "ext-phar": "*", - "phpbench/phpbench": "^0.16 || ^1", - "phpstan/phpstan": "^1.4", - "phpstan/phpstan-phpunit": "^1", - "phpunit/phpunit": "^7.5 || ^8.5 || ^9.5", - "vimeo/psalm": "^4.30 || ^5.4" + "phpbench/phpbench": "^1.2", + "phpstan/phpstan": "^1.9.4", + "phpstan/phpstan-phpunit": "^1.3", + "phpunit/phpunit": "^9.5.27", + "vimeo/psalm": "^5.4" }, "type": "library", "autoload": { @@ -139,7 +232,7 @@ ], "support": { "issues": "https://github.com/doctrine/instantiator/issues", - "source": "https://github.com/doctrine/instantiator/tree/1.5.0" + "source": "https://github.com/doctrine/instantiator/tree/2.0.0" }, "funding": [ { @@ -155,20 +248,20 @@ "type": "tidelift" } ], - "time": "2022-12-30T00:15:36+00:00" + "time": "2022-12-30T00:23:10+00:00" }, { "name": "myclabs/deep-copy", - "version": "1.12.0", + "version": "1.12.1", "source": { "type": "git", "url": "https://github.com/myclabs/DeepCopy.git", - "reference": "3a6b9a42cd8f8771bd4295d13e1423fa7f3d942c" + "reference": "123267b2c49fbf30d78a7b2d333f6be754b94845" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/myclabs/DeepCopy/zipball/3a6b9a42cd8f8771bd4295d13e1423fa7f3d942c", - "reference": "3a6b9a42cd8f8771bd4295d13e1423fa7f3d942c", + "url": "https://api.github.com/repos/myclabs/DeepCopy/zipball/123267b2c49fbf30d78a7b2d333f6be754b94845", + "reference": "123267b2c49fbf30d78a7b2d333f6be754b94845", "shasum": "" }, "require": { @@ -207,7 +300,7 @@ ], "support": { "issues": "https://github.com/myclabs/DeepCopy/issues", - "source": "https://github.com/myclabs/DeepCopy/tree/1.12.0" + "source": "https://github.com/myclabs/DeepCopy/tree/1.12.1" }, "funding": [ { @@ -215,7 +308,7 @@ "type": "tidelift" } ], - "time": "2024-06-12T14:39:25+00:00" + "time": "2024-11-08T17:47:46+00:00" }, { "name": "nikic/php-parser", @@ -394,7 +487,6 @@ "time": "2022-02-21T01:04:05+00:00" }, { - "name": "phpcsstandards/phpcsextra", "version": "1.2.1", "source": { @@ -561,7 +653,6 @@ "time": "2024-05-20T13:34:27+00:00" }, { - "name": "phpunit/php-code-coverage", "version": "9.2.32", "source": { @@ -1947,7 +2038,6 @@ "time": "2020-09-28T06:39:44+00:00" }, { - "name": "squizlabs/php_codesniffer", "version": "3.10.3", "source": { @@ -2028,7 +2118,6 @@ "time": "2024-09-18T10:38:58+00:00" }, { - "name": "theseer/tokenizer", "version": "1.2.3", "source": { @@ -2079,7 +2168,6 @@ "time": "2024-03-03T12:36:25+00:00" }, { - "name": "wp-coding-standards/wpcs", "version": "3.1.0", "source": { @@ -2146,7 +2234,6 @@ "time": "2024-03-25T16:39:00+00:00" }, { - "name": "yoast/phpunit-polyfills", "version": "1.1.2", "source": { @@ -2212,7 +2299,9 @@ ], "aliases": [], "minimum-stability": "stable", - "stability-flags": {}, + "stability-flags": { + "afragen/autoloader": 20 + }, "prefer-stable": false, "prefer-lowest": false, "platform": { diff --git a/languages/AspireUpdate-ca_ES.po b/languages/AspireUpdate-ca_ES.po deleted file mode 100644 index d1baa27..0000000 --- a/languages/AspireUpdate-ca_ES.po +++ /dev/null @@ -1,162 +0,0 @@ -# Copyright (C) 2024 AspirePress -# This file is distributed under the GPLv2. -msgid "" -msgstr "" -"Project-Id-Version: AspireUpdate 0.5\n" -"Report-Msgid-Bugs-To: https://github.com/aspirepress/AspireUpdate\n" -"POT-Creation-Date: \n" -"PO-Revision-Date: 2024-11-08 11:23+0100\n" -"Last-Translator: Joan López \n" -"Language-Team: \n" -"Language: ca\n" -"MIME-Version: 1.0\n" -"Content-Type: text/plain; charset=UTF-8\n" -"Content-Transfer-Encoding: 8bit\n" -"X-Generator: Poedit 3.4.4\n" -"X-Domain: AspireUpdate\n" - -#. Plugin Name of the plugin -#: aspire-update.php -msgid "AspireUpdate" -msgstr "AspireUpdate" - -#. Plugin URI of the plugin -#: aspire-update.php -msgid "https://aspirepress.org/" -msgstr "https://aspirepress.org/" - -#. Description of the plugin -#: aspire-update.php -msgid "Update plugins and themes for WordPress." -msgstr "Actualitza plugins i temes per WordPress." - -#. Author of the plugin -#: aspire-update.php -msgid "AspirePress" -msgstr "AspirePress" - -#. Author URI of the plugin -#: aspire-update.php includes/class-branding.php:91 -#: includes/class-branding.php:100 includes/class-branding.php:108 -msgid "https://docs.aspirepress.org/aspireupdate/" -msgstr "https://docs.aspirepress.org/aspireupdate/" - -#: includes/class-admin-settings.php:133 -msgid "Settings have been reset to default." -msgstr "La configuració s’ha restablert al valor predeterminat." - -#: includes/class-admin-settings.php:298 -msgid "Unexpected Error:" -msgstr "Error inesperat:" - -#: includes/class-admin-settings.php:319 -msgid "AspireUpdate Settings" -msgstr "Configuració d’AspireUpdate" - -#: includes/class-admin-settings.php:329 -msgid "Reset" -msgstr "Restableix" - -#: includes/class-admin-settings.php:428 -msgid "API Configuration" -msgstr "Configuració de l’API" - -#: includes/class-admin-settings.php:439 -msgid "Enable AspireUpdate API Rewrites" -msgstr "Activa les reescriptures de l’API d’AspireUpdate" - -#: includes/class-admin-settings.php:452 -msgid "API Host" -msgstr "Host de l’API" - -#: includes/class-admin-settings.php:460 -msgid "Your new API Host." -msgstr "El teu nou host de l’API" - -#: includes/class-admin-settings.php:470 -msgid "Other" -msgstr "Altres" - -#: includes/class-admin-settings.php:479 -msgid "API Key" -msgstr "Clau de l’API" - -#: includes/class-admin-settings.php:487 -msgid "Provides an API key for repositories that may require authentication." -msgstr "" -"Proporciona una clau d’API pels repositoris que requereixin autenticació" - -#: includes/class-admin-settings.php:493 -msgid "API Debug Configuration" -msgstr "Configuració de depuració de l’API" - -#: includes/class-admin-settings.php:504 -msgid "Enable Debug Mode" -msgstr "Activa el mode de depuració" - -#: includes/class-admin-settings.php:512 -msgid "Enables debug mode for the plugin." -msgstr "Activa el mode de depuració del plugin" - -#: includes/class-admin-settings.php:518 -msgid "Enable Debug Type" -msgstr "Activa el tipus de depuració" - -#: includes/class-admin-settings.php:527 -msgid "Request" -msgstr "Petició" - -#: includes/class-admin-settings.php:528 -msgid "Response" -msgstr "Resposta" - -#: includes/class-admin-settings.php:529 -msgid "String" -msgstr "Cadena de text" - -#: includes/class-admin-settings.php:531 -msgid "" -"Outputs the request URL and headers / response headers and body / string " -"that is being rewritten." -msgstr "" -"Emet l’URL de la petició i les capçaleres / encapçalaments de resposta i " -"el cos / cadena que s’està reescrivint." - -#: includes/class-admin-settings.php:537 -msgid "Disable SSL Verification" -msgstr "Desactiva la verificació SSL" - -#: includes/class-admin-settings.php:546 -msgid "Disables the verification of SSL to allow local testing." -msgstr "Desactiva la verificació de SSL per permetre proves locals." - -#: includes/class-admin-settings.php:609 -msgid "Generate API Key" -msgstr "Genera la clau de l’API" - -#. translators: 1: The name of the plugin, 2: The documentation URL. -#: includes/class-branding.php:89 -msgid "" -"Your plugin updates are now powered by %1$s. Learn more" -msgstr "" -"L’actualització dels teus plugins funciona ara amb %1$s. " -"Més informació" - -#. translators: 1: The name of the plugin, 2: The documentation URL. -#: includes/class-branding.php:98 -msgid "" -"Your theme updates are now powered by %1$s. Learn more" -msgstr "" -"L’actualització dels teus temes funciona funcionen ara amb %1$s. Més informació" - -#. translators: 1: The name of the plugin, 2: The documentation URL. -#: includes/class-branding.php:106 -msgid "" -"Your WordPress, plugin, theme and translation updates are now powered by " -"%1$s. Learn more" -msgstr "" -"L’actualització de WordPress, els teus plugins i temes funciona ara amb " -"%1$s. Més informació" diff --git a/languages/AspireUpdate-de_DE.I10n.php b/languages/AspireUpdate-de_DE.I10n.php deleted file mode 100644 index 900ff0a..0000000 --- a/languages/AspireUpdate-de_DE.I10n.php +++ /dev/null @@ -1,27 +0,0 @@ -'AspireUpdate','report-msgid-bugs-to'=>'','pot-creation-date'=>'2024-11-04 00:29+0000','po-revision-date'=>'2024-11-04 00:29+0000','last-translator'=>'','language-team'=>'German (Germany)','language'=>'de_DE','plural-forms'=>'nplurals=2; plural=n != 1;','mime-version'=>'1.0','content-type'=>'text/plain; charset=UTF-8','content-transfer-encoding'=>'8bit','x-generator'=>'Loco https://localise.biz/','x-loco-version'=>'2.6.11; wp-6.6.2','x-domain'=>'AspireUpdate','messages'=>[ - - 'API Configuration'=>'API-Konfiguration', - 'API Debug Configuration'=>'API-Debug-Konfiguration', - 'API Host'=>'API-Host', - 'API Key'=>'API-Schlüssel', - 'AspirePress'=>'AspirePress', - 'AspireUpdate'=>'AspireUpdate', - 'AspireUpdate Settings'=>'AspireUpdate-Einstellungen', - 'Disable SSL Verification'=>'SSL-Überprüfung deaktivieren', - 'Disables the verification of SSL to allow local testing.'=>'Deaktiviert die SSL-Überprüfung, um lokale Tests zu ermöglichen.', - 'Enable AspireUpdate API Rewrites'=>'Aktivieren der AspireUpdate API-Umschreibungen', - 'Enable Debug Mode'=>'Debug-Modus aktivieren', - 'Enable Debug Type'=>'Debug-Typ aktivieren', - 'Enables debug mode for the plugin.'=>'Aktiviert den Debug-Modus für das Plugin.', - 'https://aspirepress.org/'=>'AspireUpdate', - 'https://docs.aspirepress.org/aspireupdate/'=>'https://docs.aspirepress.org/aspireupdate/', - 'Outputs the request URL and headers / response headers and body / string that is being rewritten.'=>'Gibt die Anfrage-URL und Header / Antwort-Header und -Body / Zeichenfolge aus, die umgeschrieben wird.', - 'Provides an API key for repositories that may require authentication.'=>'Stellt einen API-Schlüssel für Repositories bereit, die möglicherweise eine Authentifizierung erfordern.', - 'Request'=>'Anfrage', - 'Response'=>'Antwort', - 'String'=>'Zeichenkette', - 'Update plugins and themes for WordPress.'=>'Aktualisiert Plugins und Themes für WordPress.', - 'Your new API Host.'=>'Ihr neuer API-Host' - -]]; diff --git a/languages/AspireUpdate-de_DE.mo b/languages/AspireUpdate-de_DE.mo deleted file mode 100644 index f0c491b099fda5abcee93e881004f440925e846c..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 3283 zcmcJQJ8WD<6oxO5@L0ktya|skI zTyJcN6o?W5MJNyvLZm^WAry!ro#~-L6d)>ugp`Jk0tx;z_xcr5fJCme``x)SbLKy1 z&Ybyq=e7?bJTKt)EPjvO5k&{U9e3gn&llh$;5G0`a2324{1Lnd`~|!pyaDb2{{SBc zx8D^-Pl3C@LGUmrzz)dv-YxhExCiYo!H2=`!R_F$pagG#f`_!r1J7cluC=)kuTgO5SB^CA{uzh44* zy(#=X2%ZJmZvxrx3*a;0CGdIhL-08GHCP7!1fKv8-G>;1$3R~19QZW&7RdUqfKBi! zxCoX?x!+6R1883=+V6lhv@e6a{=UogG35N>*zogQju6X7 zi+2XLJH(x1g^)!^r;rz%Q;;4-qtg@OxY143%B=Lt=RIa+-%lCm!+_JY9F4lJ zvNUbUx#E4kn@CSv8e*2bSGwh*G38`EB{4fYDbA8rP1VR3EIORr{f zx@p!@x*VM(O$ZJJV7rWH(l!$R_ zjjcsRxbqOPz=T8AfgX37?z@KsX4M|-@snC=jbF!t3}6H8m`Er`RbZ_A$**@ zg`ix;?O86w;eR*X_P*e8Y)qxxa)ehC_q(ajI)55*K}?n@XjJM58S& z5_@ER?nFGeF^+XM$;RWlVG^9Yni#ArUwSnz&O19WX&OeXML3in<)~a&D;136&J7I% z4bx8EO@e#ZZV8EE^K)}`*N2pNo>6c(&0_SFbxq>Ax$y@wn2? zQ<`SFMLI&&jaRSK$#(7P^(MX{;BwKcC57{)qp|gd7l{f*dh75$k#$gi7bPnA94eg? zE1AGo=9M;LCEz=5l;Gp2hAfIss(S9@sBT(LO|ID)>es1Ivr(2u zweRsUC_Zpsd@Qfn3lyAfnzY4**7b#GWt|qWZ;I-W*Hbp(%8A%}fs&3-H;D?O`K+xM zacm4JpIcjxsqGQ6Etn9aMNx066?nt@M;4V99&zMzPojkko7-4KuCHKE3pb)Ii6D9z zCTVDI<{Rx%x}{A}W^uu-SKJ1?Kbx+D31q-VyRVqiC&KVBF=Q#P4<})&xDcR^WuIqVV#(-RUkA9xIF8UC zqW_QEVT#(811F(EhYJFFgr8h-;k CYsg># diff --git a/languages/AspireUpdate-de_DE.po b/languages/AspireUpdate-de_DE.po deleted file mode 100644 index 201dcfd..0000000 --- a/languages/AspireUpdate-de_DE.po +++ /dev/null @@ -1,142 +0,0 @@ -msgid "" -msgstr "" -"Project-Id-Version: AspireUpdate\n" -"Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-11-04 00:29+0000\n" -"PO-Revision-Date: 2024-11-07 18:22+0000\n" -"Last-Translator: \n" -"Language-Team: German (Germany)\n" -"Language: de_DE\n" -"Plural-Forms: nplurals=2; plural=n != 1;\n" -"MIME-Version: 1.0\n" -"Content-Type: text/plain; charset=UTF-8\n" -"Content-Transfer-Encoding: 8bit\n" -"X-Generator: Loco https://localise.biz/\n" -"X-Loco-Version: 2.6.11; wp-6.6.2\n" -"X-Domain: AspireUpdate" - -#: includes/class-admin-settings.php:313 -msgid "API Configuration" -msgstr "API-Konfiguration" - -#: includes/class-admin-settings.php:378 -msgid "API Debug Configuration" -msgstr "API-Debug-Konfiguration" - -#: includes/class-admin-settings.php:337 -msgid "API Host" -msgstr "API-Host" - -#: includes/class-admin-settings.php:364 -msgid "API Key" -msgstr "API-Schlüssel" - -#. Author of the plugin -msgid "AspirePress" -msgstr "AspirePress" - -#. Name of the plugin -msgid "AspireUpdate" -msgstr "AspireUpdate" - -#: includes/class-admin-settings.php:272 -msgid "AspireUpdate Settings" -msgstr "AspireUpdate-Einstellungen" - -#: includes/class-admin-settings.php:422 -msgid "Disable SSL Verification" -msgstr "SSL-Überprüfung deaktivieren" - -#: includes/class-admin-settings.php:431 -msgid "Disables the verification of SSL to allow local testing." -msgstr "Deaktiviert die SSL-Überprüfung, um lokale Tests zu ermöglichen." - -#: includes/class-admin-settings.php:324 -msgid "Enable AspireUpdate API Rewrites" -msgstr "Aktivieren der AspireUpdate API-Umschreibungen" - -#: includes/class-admin-settings.php:389 -msgid "Enable Debug Mode" -msgstr "Debug-Modus aktivieren" - -#: includes/class-admin-settings.php:403 -msgid "Enable Debug Type" -msgstr "Debug-Typ aktivieren" - -#: includes/class-admin-settings.php:397 -msgid "Enables debug mode for the plugin." -msgstr "Aktiviert den Debug-Modus für das Plugin." - -#. URI of the plugin -msgid "https://aspirepress.org/" -msgstr "AspireUpdate" - -#. Author URI of the plugin -msgid "https://docs.aspirepress.org/aspireupdate/" -msgstr "https://docs.aspirepress.org/aspireupdate/" - -#: includes/class-admin-settings.php:416 -msgid "" -"Outputs the request URL and headers / response headers and body / string " -"that is being rewritten." -msgstr "" -"Gibt die Anfrage-URL und Header / Antwort-Header und -Body / Zeichenfolge " -"aus, die umgeschrieben wird." - -#: includes/class-admin-settings.php:372 -msgid "Provides an API key for repositories that may require authentication." -msgstr "" -"Stellt einen API-Schlüssel für Repositories bereit, die möglicherweise eine " -"Authentifizierung erfordern." - -#: includes/class-admin-settings.php:412 -msgid "Request" -msgstr "Anfrage" - -#: includes/class-admin-settings.php:413 -msgid "Response" -msgstr "Antwort" - -#: includes/class-admin-settings.php:414 -msgid "String" -msgstr "Zeichenkette" - -#. Description of the plugin -msgid "Update plugins and themes for WordPress." -msgstr "Aktualisiert Plugins und Themes für WordPress." - -#: includes/class-admin-settings.php:345 -msgid "Your new API Host." -msgstr "Ihr neuer API-Host" - -#: includes/class-admin-settings.php:133 -msgid "Settings have been reset to default." -msgstr "Einstellungen wurden auf die Standardwerte zurückgesetzt." - -#: includes/class-admin-settings.php:298 -msgid "Unexpected Error:" -msgstr "Unerwarteter Fehler:" - -#: includes/class-admin-settings.php:329 -msgid "Reset" -msgstr "Zurücksetzen" - -#: includes/class-admin-settings.php:470 -msgid "Other" -msgstr "Andere" - -#: includes/class-admin-settings.php:609 -msgid "Generate API Key" -msgstr "API-Schlüssel generieren" - -#: includes/class-branding.php:89 -msgid "Your plugin updates are now powered by %1$s. Learn more" -msgstr "Ihre Plugin-Updates werden jetzt von %1$s bereitgestellt. Mehr erfahren" - -#: includes/class-branding.php:98 -msgid "Your theme updates are now powered by %1$s. Learn more" -msgstr "Ihre Theme-Updates werden jetzt von %1$s bereitgestellt. Mehr erfahren" - -#: includes/class-branding.php:106 -msgid "Your WordPress, plugin, theme and translation updates are now powered by %1$s. Learn more" -msgstr "Ihre WordPress, Plugin, Theme und Übersetzungs updates werden jetzt von %1$s bereitgestellt. Mehr erfahren" diff --git a/languages/AspireUpdate-es_ES.po b/languages/AspireUpdate-es_ES.po deleted file mode 100644 index c5670f4..0000000 --- a/languages/AspireUpdate-es_ES.po +++ /dev/null @@ -1,145 +0,0 @@ -msgid "" -msgstr "" -"Project-Id-Version: AspireUpdate 0.5\n" -"Report-Msgid-Bugs-To: https://github.com/aspirepress/AspireUpdate\n" -"Last-Translator: David Marín Carreño \n" -"Language-Team: es_ES\n" -"MIME-Version: 1.0\n" -"Content-Type: text/plain; charset=UTF-8\n" -"Content-Transfer-Encoding: 8bit\n" -"POT-Creation-Date: \n" -"PO-Revision-Date: 2024-11-07 14:05+0100\n" -"Language: es_ES \n" -"X-Generator: WP-CLI 2.11.0\n" -"X-Domain: AspireUpdate\n" - -#. Plugin Name of the plugin -#: aspire-update.php -msgid "AspireUpdate" -msgstr "AspireUpdate" - -#. Plugin URI of the plugin -#: aspire-update.php -msgid "https://aspirepress.org/" -msgstr "https://aspirepress.org/" - -#. Description of the plugin -#: aspire-update.php -msgid "Update plugins and themes for WordPress." -msgstr "Actualizar plugins y temas para WordPress." - -#. Author of the plugin -#: aspire-update.php -msgid "AspirePress" -msgstr "AspirePress" - -#. Author URI of the plugin -#: aspire-update.php -#: includes/class-branding.php:91 -#: includes/class-branding.php:100 -#: includes/class-branding.php:108 -msgid "https://docs.aspirepress.org/aspireupdate/" -msgstr "https://docs.aspirepress.org/aspireupdate/" - -#: includes/class-admin-settings.php:133 -msgid "Settings have been reset to default." -msgstr "Los ajustes se han reestablecido a sus valores por defecto." - -#: includes/class-admin-settings.php:298 -msgid "Unexpected Error:" -msgstr "Error inesperado:" - -#: includes/class-admin-settings.php:319 -msgid "AspireUpdate Settings" -msgstr "Ajustes de AspireUpdate" - -#: includes/class-admin-settings.php:329 -msgid "Reset" -msgstr "Reestablecer" - -#: includes/class-admin-settings.php:428 -msgid "API Configuration" -msgstr "Configuración de API" - -#: includes/class-admin-settings.php:439 -msgid "Enable AspireUpdate API Rewrites" -msgstr "Activar reescrituras de API de AspireUpdate" - -#: includes/class-admin-settings.php:452 -msgid "API Host" -msgstr "Host de API" - -#: includes/class-admin-settings.php:460 -msgid "Your new API Host." -msgstr "Tu nuevo host de API" - -#: includes/class-admin-settings.php:470 -msgid "Other" -msgstr "Otros" - -#: includes/class-admin-settings.php:479 -msgid "API Key" -msgstr "Clave de API" - -#: includes/class-admin-settings.php:487 -msgid "Provides an API key for repositories that may require authentication." -msgstr "Proporciona una clave de API para los repositorios que pueden requerir autenticación." - -#: includes/class-admin-settings.php:493 -msgid "API Debug Configuration" -msgstr "Configuración de depuración de API" - -#: includes/class-admin-settings.php:504 -msgid "Enable Debug Mode" -msgstr "Activa modo de depuración" - -#: includes/class-admin-settings.php:512 -msgid "Enables debug mode for the plugin." -msgstr "Activa el modo depuración para el plugin." - -#: includes/class-admin-settings.php:518 -msgid "Enable Debug Type" -msgstr "Activa tipo de depuración" - -#: includes/class-admin-settings.php:527 -msgid "Request" -msgstr "Solicitud" - -#: includes/class-admin-settings.php:528 -msgid "Response" -msgstr "Respuesta" - -#: includes/class-admin-settings.php:529 -msgid "String" -msgstr "Cadena" - -#: includes/class-admin-settings.php:531 -msgid "Outputs the request URL and headers / response headers and body / string that is being rewritten." -msgstr "Muestra la URL y las cabeceras de la solicitud / las cabeceras y cuerpo de la respuesta / la cadena que se reescribe." - -#: includes/class-admin-settings.php:537 -msgid "Disable SSL Verification" -msgstr "Desactivar verificación de SSL" - -#: includes/class-admin-settings.php:546 -msgid "Disables the verification of SSL to allow local testing." -msgstr "Desactiva la verificación de SSL para permitir pruebas locales." - -#: includes/class-admin-settings.php:609 -msgid "Generate API Key" -msgstr "Generar clave de API" - -#. translators: 1: The name of the plugin, 2: The documentation URL. -#: includes/class-branding.php:89 -msgid "Your plugin updates are now powered by %1$s. Learn more" -msgstr "La actualización de tus plugins ahora funciona con %1$s. Leer más " - -#. translators: 1: The name of the plugin, 2: The documentation URL. -#: includes/class-branding.php:98 -msgid "Your theme updates are now powered by %1$s. Learn more" -msgstr "La actualización de tus temas ahora funciona con %1$s. Leer más" - -#. translators: 1: The name of the plugin, 2: The documentation URL. -#: includes/class-branding.php:106 -msgid "Your WordPress, plugin, theme and translation updates are now powered by %1$s. Learn more" -msgstr "La actualización de WordPress, plugins, temas y traducciones ahora funciona con %1$s. Leer más" diff --git a/languages/AspireUpdate-fr_FR.l10n.php b/languages/AspireUpdate-fr_FR.l10n.php deleted file mode 100644 index 597964d..0000000 --- a/languages/AspireUpdate-fr_FR.l10n.php +++ /dev/null @@ -1,2 +0,0 @@ -'AspireUpdate','report-msgid-bugs-to'=>'','pot-creation-date'=>'2024-11-03 17:59+0000','po-revision-date'=>'2024-11-08 08:14+0000','last-translator'=>'','language-team'=>'Français','language'=>'fr_FR','plural-forms'=>'nplurals=2; plural=n > 1;','mime-version'=>'1.0','content-type'=>'text/plain; charset=UTF-8','content-transfer-encoding'=>'8bit','x-generator'=>'Loco https://localise.biz/','x-loco-version'=>'2.6.11; wp-6.6.2','x-domain'=>'AspireUpdate','messages'=>['API Configuration'=>'Configuration de l’API','API Debug Configuration'=>'Configuration du débogage de l’API','API Host'=>'Hôte de l’API','API Key'=>'Clé API','AspirePress'=>'AspirePress','AspireUpdate'=>'AspireUpdate','AspireUpdate Settings'=>'Réglages d’AspireUpdate','Disable SSL Verification'=>'Désactiver la vérification du SSL','Disables the verification of SSL to allow local testing.'=>'Désactive la vérification du SSL pour autoriser le test en local.','Enable AspireUpdate API Rewrites'=>'Activer la réécriture de l’API AspireUpdate','Enable Debug Mode'=>'Activer le mode débogage','Enable Debug Type'=>'Activer le type de débogage','Enables debug mode for the plugin.'=>'Active le mode débogage de l’extension.','Generate API Key'=>'Générer une clé API','https://aspirepress.org/'=>'https://aspirepress.org/','https://docs.aspirepress.org/aspireupdate/'=>'https://docs.aspirepress.org/aspireupdate/','Other'=>'Autre','Outputs the request URL and headers / response headers and body / string that is being rewritten.'=>'Affiche l’URL et les en-têtes de la requête/les en-têtes et le corps de la réponse/la chaîne qui est en train d\'être réécrite.','Provides an API key for repositories that may require authentication.'=>'Fournit une clé API pour les dépôts qui peuvent nécessiter une authentification.','Request'=>'Rquête','Reset'=>'Réinitialiser','Response'=>'Réponse','Settings have been reset to default.'=>'Les réglages ont été réinitialisés à ceux par défaut.','String'=>'Chaine','Unexpected Error:'=>'Erreur inattendue :','Update plugins and themes for WordPress.'=>'Mets à jour les extensions et thème pour WordPress','Your new API Host.'=>'Votre nouvel hôte pour l’API','Your plugin updates are now powered by %1$s. Learn more'=>'Vos mises à jour d’extension sont maintenant propulsées par %1$s. En savoir plus','Your theme updates are now powered by %1$s. Learn more'=>'Vos mises à jour de thèmes sont maintenant propulsés par %1$s. En savoir plus','Your WordPress, plugin, theme and translation updates are now powered by %1$s. Learn more'=>'Vos mises à jour de WordPress, d’extensions et de thèmes sont maintenant propulsés par %1$s. En savoir plus']]; diff --git a/languages/AspireUpdate-fr_FR.mo b/languages/AspireUpdate-fr_FR.mo deleted file mode 100644 index d79a18740c87ca09491b7a0a73fd34b3b5a1a06e..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 3260 zcmcJQ&u<$=6vwyFQZNNU`HhhJ6j~LPtR1JNO`RX2%@0!HsKIf{j~>w2JGQs1XSOr5 zPErZM32}r&k>Jz|0(0PmkT|b6a6tVJsKgO*=n+r_d}r1_qgDbzBRQX)owxJ8@6DSx zKONkA)x+N*{GP+_@jZ6rc?a$p@=-iKgz;10A@F|i6u2LJ8GI021rLB#@ClHCPlH?F z4EPa9;18f(@0T8LffE=%e6Qy{0v5r2;8~D?tKc&D6=?n4?9KlMS{;9ahr#`OJ?}nn z613|d2VVe}!FNFc9t3{{FM@x8Z-E!#%+(=5F33wf}d)t86D|R02fO{a?#=Q+513$Jw zoLN6di&8YgW}=u0rEqVScr9t(=KZSF#u>cIcf2z?4i#TlTf6*j_p=CC)R$+S3iMrKGhoVAg}qDXF0Bl?S|Ba@=h1`Y_HKcM{;wWi`BJaJz1xIqYTiix|9!iyW zJ~44(GTDk>P9TdmD`jFLpcZEVSDFfh^u$tVK6quPYckluoHh!9z!x(VYN~NNQck_$ zaJ;T$Ck(j8lFs)#e8-7XJeE2%QiYgvU$@x~KD?Y@Lx?4iCrmHBd9RXb12s4HztiLO zH-=iQ!{M6?tCbr!mwOkrf!&l(nJ9X76>W z0#_J$?@gJEj3+7kVluPNzEe!-$khTRu7a>0;t<&JSZ;9zueBYTL$;)7E*vQy)^mm4 zAWw6QT8cO3Cyq=X))Nb5&Xl0GRD7<$7BcUGZ@Ki@>g@^2RNNhRE)W0v(k)|RT`Clq zJ9RO(O6R3&7QFsMAnQ86do~+qSuNOlx`bWy&jmhCpvGx0(dg;PRZv*U_-ncu2L9Qk zsr{-fQEvTw)n8QHZIQo(lTf1Rsp%7bvFJ}7r{by7OQ&C)!XFI%3h#t=<=u8OG&NHy zp2+OVOdG%2+jo=`<;qMn6V~K@m9ut09pflc^z-|lqOa|qNGM3VHQ7YgMy*!UZ_uhnKa0|?t^YeW z>`K~gMpy=2(7JLJmK|_!DeY=jHzE2mMT|OWci6cpNNj%|vAL58&M~?G8WUQUwkvVh z#R)yf@XUnVsyq}r|k;6C$0bSuljya6kOQy zMb}Te0?|TkA~@9tNlc8w71zM^h3m?0jqUkpn-S8-g>TZYaP_$Lm}|*)To|8p)>M}& z9vG%w*Od#%F{&~B8ZObz$=)eQl2IrV3XWneO9URH9JE_2 z=1B+jPl&3H?tvRJ3$1@&^e<%G7?%^P+CyE0SUhBr-8DPRu8uO6hKOFx;8;=GH7GK? z8`z_6D7{8?o@`Uhl$C-z1^suig;;R!D#cL~pA|+TbugbTrAb@y_6$M;!(*&uoJ87+x1#^y zr9;btH0#Jv*(QYB2{+FLX}3y9 1;\n" -"MIME-Version: 1.0\n" -"Content-Type: text/plain; charset=UTF-8\n" -"Content-Transfer-Encoding: 8bit\n" -"X-Generator: Loco https://localise.biz/\n" -"X-Loco-Version: 2.6.11; wp-6.6.2\n" -"X-Domain: AspireUpdate" - -#: includes/class-admin-settings.php:428 -msgid "API Configuration" -msgstr "Configuration de l’API" - -#: includes/class-admin-settings.php:493 -msgid "API Debug Configuration" -msgstr "Configuration du débogage de l’API" - -#: includes/class-admin-settings.php:452 -msgid "API Host" -msgstr "Hôte de l’API" - -#: includes/class-admin-settings.php:479 -msgid "API Key" -msgstr "Clé API" - -#. Author of the plugin -#: aspire-update.php -msgid "AspirePress" -msgstr "AspirePress" - -#. Plugin Name of the plugin -#: aspire-update.php -msgid "AspireUpdate" -msgstr "AspireUpdate" - -#: includes/class-admin-settings.php:319 -msgid "AspireUpdate Settings" -msgstr "Réglages d’AspireUpdate" - -#: includes/class-admin-settings.php:537 -msgid "Disable SSL Verification" -msgstr "Désactiver la vérification du SSL" - -#: includes/class-admin-settings.php:546 -msgid "Disables the verification of SSL to allow local testing." -msgstr "Désactive la vérification du SSL pour autoriser le test en local." - -#: includes/class-admin-settings.php:439 -msgid "Enable AspireUpdate API Rewrites" -msgstr "Activer la réécriture de l’API AspireUpdate" - -#: includes/class-admin-settings.php:504 -msgid "Enable Debug Mode" -msgstr "Activer le mode débogage" - -#: includes/class-admin-settings.php:518 -msgid "Enable Debug Type" -msgstr "Activer le type de débogage" - -#: includes/class-admin-settings.php:512 -msgid "Enables debug mode for the plugin." -msgstr "Active le mode débogage de l’extension." - -#: includes/class-admin-settings.php:609 -msgid "Generate API Key" -msgstr "Générer une clé API" - -#. Plugin URI of the plugin -#: aspire-update.php -msgid "https://aspirepress.org/" -msgstr "https://aspirepress.org/" - -#. Author URI of the plugin -#: aspire-update.php includes/class-branding.php:91 -#: includes/class-branding.php:100 includes/class-branding.php:108 -msgid "https://docs.aspirepress.org/aspireupdate/" -msgstr "https://docs.aspirepress.org/aspireupdate/" - -#: includes/class-admin-settings.php:470 -msgid "Other" -msgstr "Autre" - -#: includes/class-admin-settings.php:531 -msgid "" -"Outputs the request URL and headers / response headers and body / string " -"that is being rewritten." -msgstr "" -"Affiche l’URL et les en-têtes de la requête/les en-têtes et le corps de la " -"réponse/la chaîne qui est en train d'être réécrite." - -#: includes/class-admin-settings.php:487 -msgid "Provides an API key for repositories that may require authentication." -msgstr "" -"Fournit une clé API pour les dépôts qui peuvent nécessiter une " -"authentification." - -#: includes/class-admin-settings.php:527 -msgid "Request" -msgstr "Rquête" - -#: includes/class-admin-settings.php:329 -msgid "Reset" -msgstr "Réinitialiser" - -#: includes/class-admin-settings.php:528 -msgid "Response" -msgstr "Réponse" - -#: includes/class-admin-settings.php:133 -msgid "Settings have been reset to default." -msgstr "Les réglages ont été réinitialisés à ceux par défaut." - -#: includes/class-admin-settings.php:529 -msgid "String" -msgstr "Chaine" - -#: includes/class-admin-settings.php:298 -msgid "Unexpected Error:" -msgstr "Erreur inattendue :" - -#. Description of the plugin -#: aspire-update.php -msgid "Update plugins and themes for WordPress." -msgstr "Mets à jour les extensions et thème pour WordPress" - -#: includes/class-admin-settings.php:460 -msgid "Your new API Host." -msgstr "Votre nouvel hôte pour l’API" - -#. translators: 1: The name of the plugin, 2: The documentation URL. -#: includes/class-branding.php:89 -msgid "" -"Your plugin updates are now powered by %1$s. Learn more" -msgstr "" -"Vos mises à jour d’extension sont maintenant propulsées par " -"%1$s. En savoir plus" - -#. translators: 1: The name of the plugin, 2: The documentation URL. -#: includes/class-branding.php:98 -msgid "" -"Your theme updates are now powered by %1$s. Learn more" -msgstr "" -"Vos mises à jour de thèmes sont maintenant propulsés par " -"%1$s. En savoir plus" - -#. translators: 1: The name of the plugin, 2: The documentation URL. -#: includes/class-branding.php:106 -msgid "" -"Your WordPress, plugin, theme and translation updates are now powered by " -"%1$s. Learn more" -msgstr "" -"Vos mises à jour de WordPress, d’extensions et de thèmes sont maintenant " -"propulsés par %1$s. En savoir plus" diff --git a/languages/AspireUpdate-nl_NL.l10n.php b/languages/AspireUpdate-nl_NL.l10n.php deleted file mode 100644 index 7fc8a97..0000000 --- a/languages/AspireUpdate-nl_NL.l10n.php +++ /dev/null @@ -1,2 +0,0 @@ -'AspireUpdate','plural-forms'=>NULL,'language'=>'nl_NL','project-id-version'=>'AspireUpdate','pot-creation-date'=>'','po-revision-date'=>'2024-11-09 14:01+0100','x-generator'=>'Poedit 3.5','messages'=>['AspireUpdate'=>'AspireUpdate','https://aspirepress.org/'=>'https://aspirepress.org/','Update plugins and themes for WordPress.'=>'Update plugins en thema\'s voor WordPress.','AspirePress'=>'AspirePress','https://docs.aspirepress.org/aspireupdate/'=>'https://docs.aspirepress.org/aspireupdate/','Settings have been reset to default.'=>'Instellingen zijn opnieuw ingesteld naar de standaardwaarden.','Unexpected Error:'=>'Onverwachte fout:','AspireUpdate Settings'=>'AspireUpdate Instellingen','Reset'=>'Opnieuw instellen','API Configuration'=>'API Configuratie','Enable AspireUpdate API Rewrites'=>'AspireUpdate API herschrijfregels inschakelen','API Host'=>'API Host','Your new API Host.'=>'Je nieuwe API Host.','Other'=>'Overig','API Key'=>'API Sleutel','Provides an API key for repositories that may require authentication.'=>'Biedt een API sleutel voor repositories waarvoor authenticatie vereist kan zijn.','API Debug Configuration'=>'API Debug Configuratie','Enable Debug Mode'=>'Debug Modus inschakelen','Enables debug mode for the plugin.'=>'Schakelt debug modus in voor de plugin.','Enable Debug Type'=>'Debug Type inschakelen','Request'=>'Aanvraag','Response'=>'Antwoord','String'=>'Tekst','Outputs the request URL and headers / response headers and body / string that is being rewritten.'=>'Toon de aanvraag URL en headers / antwoord headers en body / tekst die wordt herschreven.','Disable SSL Verification'=>'SSL Verificatie uitschakelen','Disables the verification of SSL to allow local testing.'=>'Schakel SSL verificatie uit om lokaal testen mogelijk te maken.','Generate API Key'=>'Genereer API Sleutel','Your plugin updates are now powered by %1$s. Learn more'=>'Je plugin updates worden nu mogelijk gemaakt door %1$s. Lees meer','Your theme updates are now powered by %1$s. Learn more'=>'Je thema updates worden nu mogelijk gemaakt door %1$s. Lees meer','Your WordPress, plugin, theme and translation updates are now powered by %1$s. Learn more'=>'Je WordPress, plugin, thema en vertalingen updates worden nu mogelijk gemaakt door %1$s. Lees meer']]; \ No newline at end of file diff --git a/languages/AspireUpdate-nl_NL.mo b/languages/AspireUpdate-nl_NL.mo deleted file mode 100644 index 8de163d4145e8f53e435c71f3e3836277b832088..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 3200 zcmcJQNpBoQ7={~2SWMVLSVCAzQKBrQXE7lP6DP>Q1|00zvd4i0AyhN{O;3AzswP#{ zo;VT`ClD9JAzTnb2qZ3W0R94hfD7b+goK15A>{{fgZHcM@ys|mM2NK1^GvPZR`vGp zJGXrr;CT-3(|C8?5d??89e3gf&-dUX;1A#v;7{Pa;BVkP;Gf|A;B{~Z_&4|%xc#mm zcoN(L9tV$t0_=jk-^T^N1oxu-Bls}*3%DJ;21@WcI18TLmfO1m^7!W<`|%aH5BwIq z8~hpM{jY)t!N0)wz@1pM6Z`~x8~hr)0R98ApBJ$BFlfQc$iWvN`?DKH9tRJDY;PJr z9PgQe=Rl6T0qzDh$a(w-d>Q-(48dz4=Wo}2`F=;h18Bbj?gBd?`~N<89{dno0{;N9 zG?<*o<2nIydjUKNo&ym=aHSak3_OJPci;!$ui&HLJ8+u7i(mv^1v&01IDZ&i1rhex z1JePP`?z>6KM&;y9w^AM^Vwk^kZOM>IG#OtpTf&Aao#z0&dalS`FSQs@F2+k4IY%+ z*N=0~apE}nI`Em|ya&@ubK(`PT1lK4=@PAc&kQxP_$K|YYwP@kH)tc6w!OsAk|Ar0 z|Es-7IvQ(;6>=_7u?=PtD;p_^m6dsMj!e=@nz_MZzzWwUu|6^)bj#0nTF5ljeUa*> zOob!MJC=f3C<~;gr60m+a22Q&Kc@yn>cL}jQQ1Fxq*cjGZaL~4DKmc zq_-3-=e~iK9RGTMfuKb*ZcwTb+}CRPrtNZL!xoDKcloV}4t&@BAPwumOPtB7wN_4fMsj@tkTUXTg>EqK|IFx&F zd(8Pf{O?=0o$J|Jxh(yy>!DP(q)l871_P09+S1n1yq#yY%;#whRSf5%5I4}`w%5ey z?U`7{!7?sfuyGQFr?c3GbzKt!3vuGwS)>J@hRd{`@ZRAJ?o3TgRwj>z z)oNIINmP&4D%IyJ)k_Ll6 zIIEgE!u6|($qO%Z52-OWTn|E)j>`F?Rqx2S)c1~GLP7wsDU|eNMWQns#L5ETv%>Q|D9SW|W zBy<-t+mVINLKM0>rZidWAe*9#4WLV-756s_CBp6|S!)@>Y%3Bqw6-a~+0FX7Qe)E# z=iE?{{W`I(AuLemF;ylq-hn};7CD?asB5iwu9RxsNEv%wMl3^Fmdf?9;ZUhDTBx$4 z4wO7fNc1tmVUZ7x);aXk389O{k_%|_0_DDqsd8UR<2@c#WB+-h1iN>j=$Df<&Sl|Z zu-H=xWqr;Cml0)}E_@6|E9;jDy*W9?XNS^AC>Z3Bt;1cx|A;+^*yTFM6D%sErZ1aq zl(D5VcY}l@BvvkYz~%1$s. Learn more" -msgstr "" -"Je plugin updates worden nu mogelijk gemaakt door %1$s. Lees meer" - -#. translators: 1: The name of the plugin, 2: The documentation URL. -#: includes/class-branding.php:98 -msgid "" -"Your theme updates are now powered by %1$s. Learn more" -msgstr "" -"Je thema updates worden nu mogelijk gemaakt door %1$s. Lees meer" - -#. translators: 1: The name of the plugin, 2: The documentation URL. -#: includes/class-branding.php:106 -msgid "" -"Your WordPress, plugin, theme and translation updates are now powered by " -"%1$s. Learn more" -msgstr "" -"Je WordPress, plugin, thema en vertalingen updates worden nu mogelijk " -"gemaakt door %1$s. Lees meer" - -#~ msgid "Save Changes" -#~ msgstr "Wijzigingen opslaan" diff --git a/languages/AspireUpdate-sv_SE.mo b/languages/AspireUpdate-sv_SE.mo deleted file mode 100644 index 47855b3ec313f36c80f8d20a9516cf63fd8dcc36..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 2449 zcmb`I&5ImG7{*JDUt^3KHGV@O3P$Ok*(BmJA{gC`uF1N~&a8~RN^;T8S zW{x6y_7XhkaW@diNg?Ev%izVMmmCzqga3g-KoOs}x@UGa>dl6pUsqT4ThIGZ@BDoD zz$J$3+3Nlid=d9gci;zCekWs(fLq`b;HThy;8)G>6W8T<=;4?Z4+F2oBlW&m3*va)3{SGZR`pc3+_0K(-1j9P z&CPJr3#+~1BFoG+&rDZj+)GCmW45e=!BR)LHz$8KrBOBCviH+B-8L31%m<)Rl7%}_M6qakb9UP$giCN$K+%@ZU5eg{B zt}ZqP06TSe-k zwrTR|_Nnsyq7!$`a9&A$-b!tKE!vPHMfRg5lt7aoYaBZfEi6Qh*LdT2^TgsSjfF;| zc1AcKwXM)D6Ua-G=M*ON9{)?JgJbeepzqkQdLR23}gST{0Jo*zdv&P7XR z2z&bjRbx0Z(O_Q-I9-i!7EzF5#CtMxlWPM_Lq(YkAB`qEHVIF9+#Sg5zdOQ;c7C#x zWn@5D-kV&r`?AGWv>14W!!N21FxwjKVs6&XPorX?jrxh3>~i5f8pNP#5JBny=f(|W z%uY^?o1q(6HL7&Ll~96vy<>0XoXako?4)RGQzL$y-xieF92$qpXn88p8UA6T>LuhR zMSU7Jt%YYT5+*G#$}VEM{aMQh@uHueo$RJU*WE~1+F;sdXtB~-_9wepR!3Wz>>yLl z4BI7+LOX2pLv|W zkX_cor%2X(uC?Hk-Pwvng!rKGkq(=L3ZhPjK0}h(+5qqrIBGHBtWRrj)>9%chmb}- VN7HD>_$d&*A diff --git a/languages/AspireUpdate-sv_SE.po b/languages/AspireUpdate-sv_SE.po deleted file mode 100644 index 329737e..0000000 --- a/languages/AspireUpdate-sv_SE.po +++ /dev/null @@ -1,134 +0,0 @@ -# Copyright (C) 2024 AspirePress -# This file is distributed under the GPLv2. -msgid "" -msgstr "" -"Project-Id-Version: AspireUpdate 0.5\n" -"Report-Msgid-Bugs-To: https://github.com/aspirepress/AspireUpdate\n" -"POT-Creation-Date: \n" -"PO-Revision-Date: 2024-11-07 03:48+0100\n" -"Last-Translator: \n" -"Language-Team: \n" -"Language: sv_SE\n" -"MIME-Version: 1.0\n" -"Content-Type: text/plain; charset=UTF-8\n" -"Content-Transfer-Encoding: 8bit\n" -"X-Generator: Poedit 3.5\n" -"X-Domain: AspireUpdate\n" - -#. Plugin Name of the plugin -#: aspire-update.php -msgid "AspireUpdate" -msgstr "AspireUpdate" - -#. Plugin URI of the plugin -#: aspire-update.php -msgid "https://aspirepress.org/" -msgstr "https://aspirepress.org/" - -#. Description of the plugin -#: aspire-update.php -msgid "Update plugins and themes for WordPress." -msgstr "Uppdatering av WordPress-teman och -tillägg." - -#. Author of the plugin -#: aspire-update.php -msgid "AspirePress" -msgstr "AspirePress" - -#. Author URI of the plugin -#: aspire-update.php -msgid "https://docs.aspirepress.org/aspireupdate/" -msgstr "https://docs.aspirepress.org/aspireupdate/" - -#: includes/class-admin-settings.php:133 -msgid "Settings have been reset to default." -msgstr "Inställningarna återställda till standardvärden." - -#: includes/class-admin-settings.php:298 -msgid "Unexpected Error:" -msgstr "Okänt fel:" - -#: includes/class-admin-settings.php:319 -msgid "AspireUpdate Settings" -msgstr "Inställningar för AspireUpdate" - -#: includes/class-admin-settings.php:329 -msgid "Reset" -msgstr "Återställ" - -#: includes/class-admin-settings.php:428 -msgid "API Configuration" -msgstr "API-konfiguration" - -#: includes/class-admin-settings.php:439 -msgid "Enable AspireUpdate API Rewrites" -msgstr "Aktivera omskrivningar i AspireUpdate API" - -#: includes/class-admin-settings.php:452 -msgid "API Host" -msgstr "API-värd" - -#: includes/class-admin-settings.php:460 -msgid "Your new API Host." -msgstr "Din nya API-värd." - -#: includes/class-admin-settings.php:470 -msgid "Other" -msgstr "Annat" - -#: includes/class-admin-settings.php:479 -msgid "API Key" -msgstr "API-nyckel" - -#: includes/class-admin-settings.php:487 -msgid "Provides an API key for repositories that may require authentication." -msgstr "" -"Tillhandahåller API-nyckel för filförvar som kan kräva autentisering." - -#: includes/class-admin-settings.php:493 -msgid "API Debug Configuration" -msgstr "Konfigurering av felsökning i API" - -#: includes/class-admin-settings.php:504 -msgid "Enable Debug Mode" -msgstr "Aktivera felsökningsläge" - -#: includes/class-admin-settings.php:512 -msgid "Enables debug mode for the plugin." -msgstr "Aktiverar tilläggets felsökningsläge." - -#: includes/class-admin-settings.php:518 -msgid "Enable Debug Type" -msgstr "Aktivera typ av felsökning" - -#: includes/class-admin-settings.php:527 -msgid "Request" -msgstr "Förfrågan" - -#: includes/class-admin-settings.php:528 -msgid "Response" -msgstr "Svar" - -#: includes/class-admin-settings.php:529 -msgid "String" -msgstr "Sträng" - -#: includes/class-admin-settings.php:531 -msgid "" -"Outputs the request URL and headers / response headers and body / string " -"that is being rewritten." -msgstr "" -"Skriver ut URL och headers för förfrågan/svarets headers och innehåll/" -"sträng som skrivs om." - -#: includes/class-admin-settings.php:537 -msgid "Disable SSL Verification" -msgstr "Inaktivera verifiering av SSL" - -#: includes/class-admin-settings.php:546 -msgid "Disables the verification of SSL to allow local testing." -msgstr "Inaktiverar verifieringen av SSL så att lokal testning kan ske." - -#: includes/class-admin-settings.php:609 -msgid "Generate API Key" -msgstr "Generera API-nyckel" diff --git a/languages/AspireUpdate-zh_TW.l10n.php b/languages/AspireUpdate-zh_TW.l10n.php deleted file mode 100644 index 609d2ec..0000000 --- a/languages/AspireUpdate-zh_TW.l10n.php +++ /dev/null @@ -1,4 +0,0 @@ -NULL,'plural-forms'=>NULL,'language'=>'zh_TW','project-id-version'=>'AspireUpdate','pot-creation-date'=>'2024-11-02 12:34-0700','po-revision-date'=>'2024-11-02 12:40-0700','x-generator'=>'Poedit 3.5','messages'=>['Settings have been reset to default.'=>'設定已重設為預設值。','AspireUpdate Settings'=>'AspireUpdate 設定','Save Changes'=>'儲存設定','Reset'=>'重設','API Configuration'=>'API 組態','Enable AspireUpdate API Rewrites'=>'啟用 AspireUpdate API 重寫','API Host'=>'API 主機','Your new API Host.'=>'設定新的 API 主機。','Other'=>'其他主機','API Key'=>'API 金鑰','Provides an API key for repositories that may require authentication.'=>'為需要驗證的存放庫提供 API 金鑰。','API Debug Configuration'=>'API 偵錯組態','Enable Debug Mode'=>'啟用偵錯模式','Enables debug mode for the plugin.'=>'為外掛啟用偵錯模式。','Enable Debug Type'=>'啟用偵錯類型','Request'=>'要求','Response'=>'回應','String'=>'字串','Outputs the request URL and headers / response headers and body / string that is being rewritten.'=>'輸出經過重寫的要求網址、標頭、回應標頭、內容及字串。','Disable SSL Verification'=>'停用 SSL 驗證','Disables the verification of SSL to allow local testing.'=>'停用 SSL 驗證,便能在本機環境進行測試。','Generate API Key'=>'產生 API 金鑰','AspireUpdate'=>'AspireUpdate','https://aspirepress.org/'=>'https://aspirepress.org/','Update plugins and themes for WordPress.'=>'更新 WordPress 的外掛及佈景主題。','AspirePress'=>'AspirePress','https://docs.aspirepress.org/aspireupdate/'=>'https://docs.aspirepress.org/aspireupdate/']]; - diff --git a/languages/AspireUpdate-zh_TW.mo b/languages/AspireUpdate-zh_TW.mo deleted file mode 100644 index 2700e329f2c2f00fce15c57efe7b8e6adb2208f6..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 2659 zcmb`HTWl0n7{^D!+p35t-lIo@i6P8%TQD|TF>)zFEU;;dXkxNXcTRT)W@m;uXWOk$ zZGlvvP|#9@mP<*4CA3@`!CFdr^3lZj;)BMR(Amq2#>5vB6aAkv)7_#xXyPQhzjMCt zJKybmGe0g_cvQjjT=@F~d>OwV?!q4)_ijab6x;yqJ=@cW>Dzg2Spw&poqH@ zTn6UAd%=_7E8qyY1pFEl`TPVf2Y&}=kkc|ai(r2X#fbPngJS<@$OwXn`j&zs&Wqq< zpazP*tOZ4V&EWIkK~TgS3wbk?e+vrxUqRt#!2^o21zZePfeBFL-4}8o1y(qVlcC)Kj)*xtrxd+8*7N zMOtKAV*}A`gQTf$P>+!+g7&zM&1hL9)GdzD0UhHW3PCKL6O)k^Dt4aCo>K&ldrq5a zPzIMW_DvjsAn!6>E7Sa|#nY$PrO-Xa^vRGA>E@#I@45m3=s;aCooFvo!t_}8CIbBtvD?4bCtD6iJbHp&S zF*1J!BJr(iBW*KYCW9s2Y7O8jUpQjH}I_ZZk_qGvURe zInsb*O37InpTl+u=EsDb1A&42puD;svCxiax+MZt>)zx zu~_BM_V`9QQ4>ZWNik)jh!_c~C})FrsU73O8cYUdB2ky1bqPCG zy`rWrkrPNlGPkgEu~o?xLPuFLp>yuxKzT_k%kY3urFq5*t>iMWlFPE&gzY$P5Yx^D zo0UPFL;~-IY)RQ>US$}NWIB#ss!??FPKx?m(#jgt5C+S&3_c}0SVR$DsKV7f`Mn3^ z((k%j>b*2iFgtlYfBv-8m3oepj$HniAKK#RxPS44;&%-d`bXt=vvmGgaeUuDCBIDf z&d%H{?!MsW&iB%Qs+c*xHmsJRy=?1R%f^3A3ZHx&40J#t6b_i=wG@J zs)PLVqr?7m-)*AO@G1Y)0j1DA<&O;H4-E$1=9`Nch5oaJ{?nmbS*^eK+U)g#unWcM zNxx^RaP5;)*P$S6;l!Texvu<`?!vVR|77Q_&aV9E@zR-bEd0S!`JR21?cUG)i(mSE z`~C4_vy&4tTK80Gs1xUd*1(rP{%O8{#-F;7?>js@GdM31VIM?N5E\n" -"Language-Team: Alex Lion \n" -"Language: zh_TW\n" -"MIME-Version: 1.0\n" -"Content-Type: text/plain; charset=UTF-8\n" -"Content-Transfer-Encoding: 8bit\n" -"X-Generator: Poedit 3.5\n" -"X-Poedit-Basepath: ..\n" -"X-Poedit-Flags-xgettext: --add-comments=translators:\n" -"X-Poedit-WPHeader: aspire-update.php\n" -"X-Poedit-SourceCharset: UTF-8\n" -"X-Poedit-KeywordsList: __;_e;_n:1,2;_x:1,2c;_ex:1,2c;_nx:4c,1,2;esc_attr__;" -"esc_attr_e;esc_attr_x:1,2c;esc_html__;esc_html_e;esc_html_x:1,2c;" -"_n_noop:1,2;_nx_noop:3c,1,2;__ngettext_noop:1,2\n" -"X-Poedit-SearchPath-0: .\n" -"X-Poedit-SearchPathExcluded-0: *.min.js\n" - -#: includes/class-admin-settings.php:119 -msgid "Settings have been reset to default." -msgstr "設定已重設為預設值。" - -#: includes/class-admin-settings.php:272 -msgid "AspireUpdate Settings" -msgstr "AspireUpdate 設定" - -#: includes/class-admin-settings.php:279 -msgid "Save Changes" -msgstr "儲存設定" - -#: includes/class-admin-settings.php:280 -msgid "Reset" -msgstr "重設" - -#: includes/class-admin-settings.php:313 -msgid "API Configuration" -msgstr "API 組態" - -#: includes/class-admin-settings.php:324 -msgid "Enable AspireUpdate API Rewrites" -msgstr "啟用 AspireUpdate API 重寫" - -#: includes/class-admin-settings.php:337 -msgid "API Host" -msgstr "API 主機" - -#: includes/class-admin-settings.php:345 -msgid "Your new API Host." -msgstr "設定新的 API 主機。" - -#: includes/class-admin-settings.php:355 -msgid "Other" -msgstr "其他主機" - -#: includes/class-admin-settings.php:364 -msgid "API Key" -msgstr "API 金鑰" - -#: includes/class-admin-settings.php:372 -msgid "Provides an API key for repositories that may require authentication." -msgstr "為需要驗證的存放庫提供 API 金鑰。" - -#: includes/class-admin-settings.php:378 -msgid "API Debug Configuration" -msgstr "API 偵錯組態" - -#: includes/class-admin-settings.php:389 -msgid "Enable Debug Mode" -msgstr "啟用偵錯模式" - -#: includes/class-admin-settings.php:397 -msgid "Enables debug mode for the plugin." -msgstr "為外掛啟用偵錯模式。" - -#: includes/class-admin-settings.php:403 -msgid "Enable Debug Type" -msgstr "啟用偵錯類型" - -#: includes/class-admin-settings.php:412 -msgid "Request" -msgstr "要求" - -#: includes/class-admin-settings.php:413 -msgid "Response" -msgstr "回應" - -#: includes/class-admin-settings.php:414 -msgid "String" -msgstr "字串" - -#: includes/class-admin-settings.php:416 -msgid "" -"Outputs the request URL and headers / response headers and body / string " -"that is being rewritten." -msgstr "輸出經過重寫的要求網址、標頭、回應標頭、內容及字串。" - -#: includes/class-admin-settings.php:422 -msgid "Disable SSL Verification" -msgstr "停用 SSL 驗證" - -#: includes/class-admin-settings.php:431 -msgid "Disables the verification of SSL to allow local testing." -msgstr "停用 SSL 驗證,便能在本機環境進行測試。" - -#: includes/class-admin-settings.php:494 -msgid "Generate API Key" -msgstr "產生 API 金鑰" - -#. Plugin Name of the plugin/theme -msgid "AspireUpdate" -msgstr "AspireUpdate" - -#. Plugin URI of the plugin/theme -msgid "https://aspirepress.org/" -msgstr "https://aspirepress.org/" - -#. Description of the plugin/theme -msgid "Update plugins and themes for WordPress." -msgstr "更新 WordPress 的外掛及佈景主題。" - -#. Author of the plugin/theme -msgid "AspirePress" -msgstr "AspirePress" - -#. Author URI of the plugin/theme -msgid "https://docs.aspirepress.org/aspireupdate/" -msgstr "https://docs.aspirepress.org/aspireupdate/" diff --git a/languages/AspireUpdate.pot b/languages/AspireUpdate.pot index a4cf65b..d91f733 100644 --- a/languages/AspireUpdate.pot +++ b/languages/AspireUpdate.pot @@ -2,14 +2,14 @@ # This file is distributed under the GPLv2. msgid "" msgstr "" -"Project-Id-Version: AspireUpdate 0.5\n" +"Project-Id-Version: AspireUpdate 0.6\n" "Report-Msgid-Bugs-To: https://github.com/aspirepress/AspireUpdate\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"POT-Creation-Date: \n" +"POT-Creation-Date: 2024-11-14T00:37:56+00:00\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "X-Generator: WP-CLI 2.11.0\n" "X-Domain: AspireUpdate\n" @@ -36,111 +36,149 @@ msgstr "" #. Author URI of the plugin #: aspire-update.php -#: includes/class-branding.php:91 -#: includes/class-branding.php:100 -#: includes/class-branding.php:108 +#: includes/class-branding.php:99 +#: includes/class-branding.php:114 +#: includes/class-branding.php:127 msgid "https://docs.aspirepress.org/aspireupdate/" msgstr "" -#: includes/class-admin-settings.php:133 +#: includes/class-admin-settings.php:139 msgid "Settings have been reset to default." msgstr "" -#: includes/class-admin-settings.php:298 -msgid "Unexpected Error:" -msgstr "" - -#: includes/class-admin-settings.php:319 -msgid "AspireUpdate Settings" +#: includes/class-admin-settings.php:156 +msgid "Settings Saved" msgstr "" #: includes/class-admin-settings.php:329 -msgid "Reset" +msgid "Unexpected Error" msgstr "" -#: includes/class-admin-settings.php:428 +#: includes/class-admin-settings.php:383 msgid "API Configuration" msgstr "" -#: includes/class-admin-settings.php:439 +#: includes/class-admin-settings.php:394 msgid "Enable AspireUpdate API Rewrites" msgstr "" -#: includes/class-admin-settings.php:452 +#: includes/class-admin-settings.php:407 msgid "API Host" msgstr "" -#: includes/class-admin-settings.php:460 +#: includes/class-admin-settings.php:415 msgid "Your new API Host." msgstr "" -#: includes/class-admin-settings.php:470 +#: includes/class-admin-settings.php:425 msgid "Other" msgstr "" -#: includes/class-admin-settings.php:479 +#: includes/class-admin-settings.php:434 msgid "API Key" msgstr "" -#: includes/class-admin-settings.php:487 +#: includes/class-admin-settings.php:442 msgid "Provides an API key for repositories that may require authentication." msgstr "" -#: includes/class-admin-settings.php:493 +#: includes/class-admin-settings.php:448 msgid "API Debug Configuration" msgstr "" -#: includes/class-admin-settings.php:504 +#: includes/class-admin-settings.php:459 msgid "Enable Debug Mode" msgstr "" -#: includes/class-admin-settings.php:512 +#: includes/class-admin-settings.php:467 msgid "Enables debug mode for the plugin." msgstr "" -#: includes/class-admin-settings.php:518 +#: includes/class-admin-settings.php:473 msgid "Enable Debug Type" msgstr "" -#: includes/class-admin-settings.php:527 +#: includes/class-admin-settings.php:482 msgid "Request" msgstr "" -#: includes/class-admin-settings.php:528 +#: includes/class-admin-settings.php:483 msgid "Response" msgstr "" -#: includes/class-admin-settings.php:529 +#: includes/class-admin-settings.php:484 msgid "String" msgstr "" -#: includes/class-admin-settings.php:531 +#: includes/class-admin-settings.php:486 msgid "Outputs the request URL and headers / response headers and body / string that is being rewritten." msgstr "" -#: includes/class-admin-settings.php:537 +#: includes/class-admin-settings.php:492 msgid "Disable SSL Verification" msgstr "" -#: includes/class-admin-settings.php:546 +#: includes/class-admin-settings.php:501 msgid "Disables the verification of SSL to allow local testing." msgstr "" -#: includes/class-admin-settings.php:609 +#: includes/class-admin-settings.php:564 msgid "Generate API Key" msgstr "" #. translators: 1: The name of the plugin, 2: The documentation URL. -#: includes/class-branding.php:89 +#: includes/class-branding.php:97 msgid "Your plugin updates are now powered by %1$s. Learn more" msgstr "" #. translators: 1: The name of the plugin, 2: The documentation URL. -#: includes/class-branding.php:98 +#: includes/class-branding.php:112 msgid "Your theme updates are now powered by %1$s. Learn more" msgstr "" #. translators: 1: The name of the plugin, 2: The documentation URL. -#: includes/class-branding.php:106 +#: includes/class-branding.php:125 msgid "Your WordPress, plugin, theme and translation updates are now powered by %1$s. Learn more" msgstr "" + +#: includes/class-controller.php:62 +#: includes/class-controller.php:92 +msgid "Error: You are not authorized to access this resource." +msgstr "" + +#: includes/class-controller.php:78 +msgid "Log file cleared successfully." +msgstr "" + +#: includes/class-debug.php:85 +msgid "Error: Unable to read the log file." +msgstr "" + +#: includes/class-debug.php:98 +msgid "*****Log file is empty.*****" +msgstr "" + +#. translators: 1: The number of lines at which the content was truncated. +#: includes/class-debug.php:102 +msgid "*****Log truncated at %s lines.*****" +msgstr "" + +#: includes/class-debug.php:118 +msgid "Error: Unable to access the log file." +msgstr "" + +#: includes/views/page-admin-settings.php:8 +msgid "AspireUpdate Settings" +msgstr "" + +#: includes/views/page-admin-settings.php:17 +msgid "Reset" +msgstr "" + +#: includes/views/page-admin-settings.php:18 +msgid "Clear Log" +msgstr "" + +#: includes/views/page-admin-settings.php:19 +msgid "View Log" +msgstr "" diff --git a/vendor/afragen/autoloader/Autoloader.php b/vendor/afragen/autoloader/Autoloader.php new file mode 100644 index 0000000..0ec881f --- /dev/null +++ b/vendor/afragen/autoloader/Autoloader.php @@ -0,0 +1,135 @@ + + * @license MIT + * @link http://github.com/afragen/autoloader + * @copyright 2015 Andy Fragen + * @package autoloader + */ + +namespace Fragen; + +/* + * Exit if called directly. + */ +if ( ! defined( 'WPINC' ) ) { + die; +} + +if ( ! class_exists( 'Fragen\\Autoloader' ) ) { + /** + * Class Autoloader + * + * To use with different plugins be sure to create a new namespace. + * + * @author Andy Fragen + * @author Barry Hughes + * @link http://github.com/afragen/autoloader + * @copyright 2015-2018 Andy Fragen + * @version 3.0.0 + */ + class Autoloader { + /** + * Roots to scan when autoloading. + * + * @var array + */ + protected $roots = array(); + + /** + * List of class names and locations in filesystem, for situations + * where they deviate from convention etc. + * + * @var array + */ + protected $map = array(); + + /** + * Constructor. + * + * @access public + * + * @param array $roots Roots to scan when autoloading. + * @param array|null $static_map Array of classes that deviate from convention. + * Defaults to null. + */ + public function __construct( array $roots, array $static_map = null ) { + $this->roots = $roots; + if ( null !== $static_map ) { + $this->map = $static_map; + } + spl_autoload_register( array( $this, 'autoload' ) ); + } + + /** + * Load classes. + * + * @access protected + * + * @param string $class The class name to autoload. + * + * @return void + */ + protected function autoload( $class ) { + // Check for a static mapping first of all. + if ( isset( $this->map[ $class ] ) && file_exists( $this->map[ $class ] ) ) { + include_once $this->map[ $class ]; + + return; + } + + // Else scan the namespace roots. + foreach ( $this->roots as $namespace => $root_dir ) { + // If the class doesn't belong to this namespace, move on to the next root. + if ( 0 !== strpos( $class, $namespace ) ) { + continue; + } + + $psr4_fname = substr( $class, strlen( $namespace ) + 1 ); + $psr4_fname = str_replace( '\\', DIRECTORY_SEPARATOR, $psr4_fname ); + + // Determine the possible path to the class, include all subdirectories. + $objects = new \RecursiveIteratorIterator( new \RecursiveDirectoryIterator( $root_dir ), \RecursiveIteratorIterator::SELF_FIRST ); + foreach ( $objects as $name => $object ) { + if ( is_dir( $name ) ) { + $directories[] = rtrim( $name, './' ); + } + } + $directories = array_unique( $directories ); + + $paths = $this->get_paths( $directories, array( $psr4_fname ) ); + + // Test for its existence and load if present. + foreach ( $paths as $path ) { + if ( file_exists( $path ) ) { + include_once $path; + break; + } + } + } + } + + /** + * Get and return an array of possible file paths. + * + * @param array $dirs Array of plugin directories and subdirectories. + * @param array $file_names Array of possible file names. + * + * @return mixed + */ + private function get_paths( $dirs, $file_names ) { + foreach ( $file_names as $file_name ) { + $paths[] = array_map( + function ( $dir ) use ( $file_name ) { + return $dir . DIRECTORY_SEPARATOR . $file_name . '.php'; + }, + $dirs + ); + } + + return call_user_func_array( 'array_merge', $paths ); + } + } +} diff --git a/vendor/afragen/autoloader/CHANGES.md b/vendor/afragen/autoloader/CHANGES.md new file mode 100644 index 0000000..fbbdec3 --- /dev/null +++ b/vendor/afragen/autoloader/CHANGES.md @@ -0,0 +1,17 @@ +#### 3.0.0 +* refactor as composer library, though likely better to just use composer's autoloader + +#### 2.0.0 +* use proper namespacing +* show proper loading of TEC/ECP compatibility classes + +#### 1.1.1 +* change directory spacer to double underscore per PSR 4 +* change directory/file naming for PSR 4 + +#### 1.1.0 +* redesign to load classes like PSR 0 and add `_` as directory spacer +* rename TEC/ECP alias directory and files for PSR 0 style loading + +#### 1.0.0 +* initial commit diff --git a/vendor/afragen/autoloader/LICENSE b/vendor/afragen/autoloader/LICENSE new file mode 100644 index 0000000..b913d48 --- /dev/null +++ b/vendor/afragen/autoloader/LICENSE @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2018 Andy Fragen + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/vendor/afragen/autoloader/README.md b/vendor/afragen/autoloader/README.md new file mode 100644 index 0000000..41e9e24 --- /dev/null +++ b/vendor/afragen/autoloader/README.md @@ -0,0 +1,24 @@ +## Autoloader + +This repository contains a generic class autoloader that will load classes from a PSR-4 namespace root directory and an alternate directory/location for vendor or classmap of classes necessary for your plugin. + +PRs welcome, especially for additional class aliases as you find needing them. Please refer to the readme in that folder for additional information on how to create these. + +This is an alternative to composer's autoload creator. + +```php +$root = [ 'My_Namespace' => 'path/to/my-namespace' ]; +$classmap = [ + 'Extra_Class' => 'path/to/extra-class.php', + 'AnotherClass' => 'path/to/class-another.php', +]; + +require_once 'Autoloader.php'; +new \Fragen\Autoloader( $root, $classmap ); +``` + +## Changelog +[CHANGES.md](CHANGES.md) + +## Credits +Built by [Andy Fragen](https://thefragens.com/) diff --git a/vendor/afragen/autoloader/composer.json b/vendor/afragen/autoloader/composer.json new file mode 100644 index 0000000..697b1fe --- /dev/null +++ b/vendor/afragen/autoloader/composer.json @@ -0,0 +1,28 @@ +{ + "name": "afragen/autoloader", + "description": "PSR-4 style autoloader and classmap loader.", + "version": "3.0.0", + "type": "library", + "keywords": [ + "autoload" + ], + "license": "MIT", + "repositories": [ + { + "type": "vcs", + "url": "https://github.com/afragen/autoload" + } + ], + "authors": [ + { + "name": "Andy Fragen", + "email": "andy@thefragens.com", + "homepage": "https://thefragens.com", + "role": "Developer" + } + ], + "prefer-stable": true, + "require": { + "php": ">=5.6" + } +} diff --git a/vendor/afragen/translations-updater/CHANGES.md b/vendor/afragen/translations-updater/CHANGES.md new file mode 100644 index 0000000..71017b9 --- /dev/null +++ b/vendor/afragen/translations-updater/CHANGES.md @@ -0,0 +1,19 @@ +#### [unreleased] + +#### 1.0.1 / 2024-11-12 +* fixed a hard-coded 'master' branch in `Language_Pack_API::process_language_pack_package()` + +#### 1.0.0 / 2024-11-12 +* added WPCS-style linting +* return empty array in `API::get_repo_data()` as appropriate +* lowercase slugs for GlotPress compatibility +* more checks to correctly update appropriate transient +* update to select repository branch +* make work with self-hosted installs of git hosts +* update `Init::can_update()` for parity with GitHub Updater +* update for possible universal EDD SL Updater plugin +* switch to `site_transient_update_{plugins|themes}` filter +* convert to composer dependency from [EDD Translations Updater](https://github.com/afragen/edd-translations-updater) and make more generic for any WordPress plugin or theme +* support EDD Software Licensing `post_edd_sl_{plugin|theme}_updater_setup` action hooks +* update for Bitbucket API 2.0 +* initial commit diff --git a/vendor/afragen/translations-updater/LICENSE b/vendor/afragen/translations-updater/LICENSE new file mode 100644 index 0000000..03e5b17 --- /dev/null +++ b/vendor/afragen/translations-updater/LICENSE @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2017 Andy Fragen + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/vendor/afragen/translations-updater/README.md b/vendor/afragen/translations-updater/README.md new file mode 100644 index 0000000..eb38dd6 --- /dev/null +++ b/vendor/afragen/translations-updater/README.md @@ -0,0 +1,103 @@ + +# Translations Updater + +* Contributors: [Andy Fragen](https://github.com/afragen) +* Tags: plugins, themes, edd software licensing, language pack, updater +* Requires at least: 4.6 +* Requires PHP: 5.4 +* Donate link: +* License: MIT +* License URI: + +## Description + +This framework allows for decoupled language pack updates for your WordPress plugins or themes that are hosted on public repositories in GitHub, Bitbucket, GitLab, or Gitea. + + The URI should point to a repository that contains the translations files. Refer to [GitHub Updater Translations](https://github.com/afragen/github-updater-translations) as an example. It is created using the [Language Pack Maker](https://github.com/afragen/language-pack-maker). The repo **must** be a public repo. + +## Usage + +Install via Composer: `composer require afragen/translations-updater:dev-master` + +**Prior to release use the following command** +`composer require afragen/translations-updater:dev-` currently `dev-master` + +Add `require_once __DIR__ . '/vendor/autoload.php';` to the main plugin file or theme's functions.php file. + +A configuration array with the following format is needed. All array elements are required. + +```php +add_action( 'admin_init', function() { + $config = [ + 'git' => '(github|bitbucket|gitlab|gitea)', + 'type' => '(plugin|theme)', + 'slug' => 'my-repo-slug', // Should be lowercase. + 'version' => 'my-repo-version', // Current version of plugin|theme. + 'languages' => 'https://my-path-to/language-packs', + 'branch' => 'master', // Default. + ]; + + ( new \Fragen\Translations_Updater\Init() )->run( $config ); +} ); +``` + +If you wish to delete the data stored in the options table associated with this framework you will need to issue the following command. + +```php +( new \Fragen\Translations_Updater\Init() )->delete_cached_data(); +``` + +## EDD Software Licensing Usage + +If using this framework with EDD Software Licensing you will need to update to the latest versions of the updaters in the EDD Software Licensing sample code to ensure the appropriate action hooks are present. + +You will need to add two key/value pairs to your setup array similar to the following, +```php +'git' => 'github', +'languages' => 'https://github.com//my-language-pack', +``` + +You will need to include the following command to your bootstrap file to activate the updater. + +```php +( new \Fragen\Translations_Updater\Init( __NAMESPACE__ ) )->edd_run(); +``` + +### Plugins + +You must add two additional key/value pairs to the setup array in your `EDD_SL_Plugin_Updater` setup. The array will be similar to the following from the `edd-sample-plugin.php` file. + +```php + $edd_updater = new EDD_SL_Plugin_Updater( EDD_SAMPLE_STORE_URL, __FILE__, array( + 'version' => '1.0', // current version number + 'license' => $license_key, // license key (used get_option above to retrieve from DB) + 'item_name' => EDD_SAMPLE_ITEM_NAME, // name of this plugin + 'author' => 'Pippin Williamson', // author of this plugin + 'beta' => false, + 'git' => 'bitbucket', + 'languages' => 'https://bitbucket.org/afragen/test-language-pack', + ) +``` + +### Themes + +You must add two additional key/value pairs to the setup array in your `EDD_Theme_Updater_Admin` setup. The array will be similar to the following from the `edd-sample-theme/updater/theme-updater.php` file. + +```php +$updater = new EDD_Theme_Updater_Admin( + + // Config settings + $config = array( + 'remote_api_url' => 'https://easydigitaldownloads.com', // Site where EDD is hosted + 'item_name' => 'Theme Name', // Name of theme + 'theme_slug' => 'theme-slug', // Theme slug + 'version' => '1.0.0', // The current version of this theme + 'author' => 'Easy Digital Downloads', // The author of this theme + 'download_id' => '', // Optional, used for generating a license renewal link + 'renew_url' => '', // Optional, allows for a custom license renewal link + 'beta' => false, // Optional, set to true to opt into beta versions + 'git' => 'github', + 'languages' => 'https://github.com//my-language-pack', + ), + ... +``` diff --git a/vendor/afragen/translations-updater/composer.json b/vendor/afragen/translations-updater/composer.json new file mode 100644 index 0000000..7d049ab --- /dev/null +++ b/vendor/afragen/translations-updater/composer.json @@ -0,0 +1,55 @@ +{ + "name": "afragen/translations-updater", + "description": "This framework provides automatic decoupled languate pack updates from a public repository for your WordPress plugin or theme.", + "type": "library", + "license": "MIT", + "version": "1.0.1", + "keywords": [ + "wordpress", + "plugin", + "theme", + "updater", + "language pack", + "translations" + ], + "authors": [ + { + "name": "Andy Fragen", + "email": "andy@thefragens.com", + "homepage": "https://thefragens.com", + "role": "Developer" + } + ], + "support": { + "issues": "https://github.com/afragen/translations-updater/issues", + "source": "https://github.com/afragen/translations-updater" + }, + "repositories": [ + { + "type": "vcs", + "url": "https://github.com/afragen/translations-updater" + } + ], + "prefer-stable": true, + "require": { + "php": ">=5.4" + }, + "require-dev": { + "wp-coding-standards/wpcs": "^3.0.0" + }, + "autoload": { + "psr-4": { + "Fragen\\Translations_Updater\\": "src/Translations_Updater/" + } + }, + "config": { + "allow-plugins": { + "dealerdirect/phpcodesniffer-composer-installer": true + } + }, + "scripts": { + "wpcs": [ + "vendor/bin/phpcbf .; vendor/bin/phpcs ." + ] + } +} diff --git a/vendor/afragen/translations-updater/src/Translations_Updater/API.php b/vendor/afragen/translations-updater/src/Translations_Updater/API.php new file mode 100644 index 0000000..5fd6951 --- /dev/null +++ b/vendor/afragen/translations-updater/src/Translations_Updater/API.php @@ -0,0 +1,175 @@ +repo->type; + $arr['branch'] = $this->repo->branch; + + switch ( $this->repo->git ) { + case 'github': + $arr['git'] = 'github'; + $arr['base_uri'] = 'https://api.github.com'; + $arr['base_download'] = 'https://github.com'; + break; + case 'bitbucket': + $arr['git'] = 'bitbucket'; + $arr['base_uri'] = 'https://bitbucket.org/api'; + $arr['base_download'] = 'https://bitbucket.org'; + break; + case 'gitlab': + $arr['git'] = 'gitlab'; + $arr['base_uri'] = 'https://gitlab.com/api/v4'; + $arr['base_download'] = 'https://gitlab.com'; + break; + case 'gitea': + $arr['git'] = 'gitea'; + // TODO: make sure this works. + $arr['base_uri'] = $this->repo->languages . '/api/v1'; + $arr['base_download'] = $this->repo->languages; + break; + } + + return $arr; + } + + /** + * Call the API and return a json decoded body. + * + * @param string $url Repository URL. + * + * @return boolean|\stdClass + */ + final protected function api( $url ) { + $response = wp_remote_get( $this->get_api_url( $url ) ); + + if ( is_wp_error( $response ) ) { + return false; + } + + return json_decode( wp_remote_retrieve_body( $response ) ); + } + + /** + * Return API url. + * + * @access protected + * + * @param string $endpoint API endpoint. + * + * @return string $endpoint + */ + final protected function get_api_url( $endpoint ) { + $type = $this->return_repo_type(); + + switch ( $type['git'] ) { + case 'bitbucket': + case 'gitea': + break; + case 'github': + case 'gitlab': + $endpoint = add_query_arg( 'ref', $type['branch'], $endpoint ); + break; + default: + } + + return $type['base_uri'] . $endpoint; + } + + /** + * Validate wp_remote_get response. + * + * @param \stdClass $response API response. + * + * @return bool true if invalid + */ + final protected function validate_response( $response ) { + return empty( $response ) || isset( $response->message ); + } + + /** + * Returns repo cached data. + * + * @param string|bool $repo Repo name or false. + * + * @return array|bool false for expired cache + */ + final protected function get_repo_cache( $repo = false ) { + if ( ! $repo ) { + $repo = isset( $this->type->slug ) ? $this->type->slug : 'tu'; + } + $cache_key = 'tu-' . md5( $repo ); + $cache = get_site_option( $cache_key ); + + if ( empty( $cache['timeout'] ) || time() > $cache['timeout'] ) { + return []; + } + + return $cache; + } + + /** + * Sets repo data for cache in site option. + * + * @param string $id Data Identifier. + * @param mixed $response Data to be stored. + * @param string|bool $repo Repo name or false. + * + * @return bool + */ + final protected function set_repo_cache( $id, $response, $repo = false ) { + if ( ! $repo ) { + $repo = isset( $this->type->slug ) ? $this->type->slug : 'tu'; + } + $cache_key = 'tu-' . md5( $repo ); + $timeout = '+' . self::$hours . ' hours'; + + $this->response['timeout'] = strtotime( $timeout ); + $this->response[ $id ] = $response; + + update_site_option( $cache_key, $this->response ); + + return true; + } +} diff --git a/vendor/afragen/translations-updater/src/Translations_Updater/Base.php b/vendor/afragen/translations-updater/src/Translations_Updater/Base.php new file mode 100644 index 0000000..40d5e89 --- /dev/null +++ b/vendor/afragen/translations-updater/src/Translations_Updater/Base.php @@ -0,0 +1,114 @@ +languages ) ) { + return false; + } + + $this->config[ $config->slug ] = $config; + $language_pack = new Language_Pack( $config, new Language_Pack_API( $config ) ); + $language_pack->run(); + + return true; + } + + /** + * Parse URI param returning array of parts. + * + * @param string $repo_header Repository URI. + * + * @return array $header + */ + final protected function parse_header_uri( $repo_header ) { + $header_parts = parse_url( $repo_header ); + $header_path = pathinfo( $header_parts['path'] ); + $header['original'] = $repo_header; + $header['scheme'] = isset( $header_parts['scheme'] ) ? $header_parts['scheme'] : null; + $header['host'] = isset( $header_parts['host'] ) ? $header_parts['host'] : null; + $header['type'] = explode( '.', $header['host'] )[0] . '_' . $this->repo->type; + $header['owner'] = trim( $header_path['dirname'], '/' ); + $header['repo'] = $header_path['filename']; + $header['owner_repo'] = implode( '/', [ $header['owner'], $header['repo'] ] ); + $header['base_uri'] = str_replace( $header_parts['path'], '', $repo_header ); + $header['uri'] = isset( $header['scheme'] ) ? trim( $repo_header, '/' ) : null; + + $header = $this->sanitize( $header ); + + return $header; + } + + /** + * Sanitize each setting field as needed. + * + * @param array $input Contains all settings fields as array keys. + * + * @return array + */ + final public function sanitize( $input ) { + $new_input = []; + foreach ( array_keys( (array) $input ) as $id ) { + $new_input[ sanitize_file_name( $id ) ] = sanitize_text_field( $input[ $id ] ); + } + + return $new_input; + } + + /** + * Delete options from database. + * + * @return void + */ + final public function delete_cached_data() { + global $wpdb; + + $table = is_multisite() ? $wpdb->base_prefix . 'sitemeta' : $wpdb->base_prefix . 'options'; + $column = is_multisite() ? 'meta_key' : 'option_name'; + // phpcs:disable WordPress.DB + $delete_string = 'DELETE FROM ' . $table . ' WHERE ' . $column . ' LIKE %s LIMIT 1000'; + + $wpdb->query( $wpdb->prepare( $delete_string, [ '%tu-%' ] ) ); + // phpcs:enable + } +} diff --git a/vendor/afragen/translations-updater/src/Translations_Updater/Init.php b/vendor/afragen/translations-updater/src/Translations_Updater/Init.php new file mode 100644 index 0000000..82d2ac4 --- /dev/null +++ b/vendor/afragen/translations-updater/src/Translations_Updater/Init.php @@ -0,0 +1,113 @@ +caller = $caller; + } + + /** + * Test for proper user capabilities. + * + * @return bool + */ + private function can_update() { + // WP-CLI access has full capabilities. + if ( defined( 'WP_CLI' ) && \WP_CLI ) { + return true; + } + + $can_user_update = current_user_can( 'update_plugins' ) && current_user_can( 'update_themes' ); + + return $can_user_update; + } + + /** + * Start the processing. + * + * @param mixed $config [ 'git' => '{github|bitbucket|gitlab|gitea}', + * 'type' => '{plugin|theme}', + * 'slug' => 'my-repo-slug', + * 'version => '1.0', + * 'languages' => 'https://github.com//my-translations', + * ]. + * @return void|bool + */ + public function run( $config ) { + if ( ! isset( $config['git'], $config['type'], $config['slug'], $config['version'], $config['languages'] ) ) { + return false; + } + $config['branch'] = isset( $config['branch'] ) ? $config['branch'] : 'master'; + if ( $this->can_update() ) { + $config = $this->sanitize( $config ); + $this->get_remote_repo_data( $config ); + } + } + + /** + * Load relevant action hooks for EDD Software Licensing. + */ + public function edd_run() { + add_action( 'post_edd_sl_plugin_updater_setup', [ $this, 'parse_edd_config' ], 15, 1 ); + add_action( 'post_edd_sl_theme_updater_setup', [ $this, 'parse_edd_config' ], 15, 1 ); + } + + /** + * Parse passed config from EDD SL. + * + * @param array $config EDD SL config array. + * + * @return void + */ + public function parse_edd_config( $config ) { + $edd_sl_updater = 'EDD\Software_Licensing\Updater'; + if ( $edd_sl_updater !== $this->caller ) { + if ( 'post_edd_sl_plugin_updater_setup' === current_filter() ) { + $slug = array_keys( $config )[0]; + $config = array_values( $config )[0]; + $config['type'] = 'plugin'; + $config['slug'] = $slug; + } + if ( 'post_edd_sl_theme_updater_setup' === current_filter() ) { + $config['type'] = 'theme'; + $config['slug'] = $config['theme_slug']; + } + } + $this->run( $config ); + } +} diff --git a/vendor/afragen/translations-updater/src/Translations_Updater/Language_Pack.php b/vendor/afragen/translations-updater/src/Translations_Updater/Language_Pack.php new file mode 100644 index 0000000..4d074f6 --- /dev/null +++ b/vendor/afragen/translations-updater/src/Translations_Updater/Language_Pack.php @@ -0,0 +1,120 @@ +languages ) { + return; + } + + $this->repo = $config; + $this->repo_api = $api; + } + + /** + * Do the Language Pack integration. + */ + public function run() { + $headers = $this->parse_header_uri( $this->repo->languages ); + $repo = $this->repo_api->get_language_pack( $headers ); + $this->config[ $repo->slug ] = $repo; + + add_filter( 'site_transient_update_plugins', [ $this, 'update_site_transient' ] ); + add_filter( 'site_transient_update_themes', [ $this, 'update_site_transient' ] ); + } + + /** + * Add language translations to update_plugins or update_themes transients. + * + * @param \stdClass $transient Update transient. + * + * @return mixed + */ + public function update_site_transient( $transient ) { + $locales = get_available_languages(); + $locales = ! empty( $locales ) ? $locales : [ get_locale() ]; + $repos = []; + + if ( ! isset( $transient->translations ) ) { + return $transient; + } + + if ( 'site_transient_update_plugins' === current_filter() ) { + $translations = wp_get_installed_translations( 'plugins' ); + } + if ( 'site_transient_update_themes' === current_filter() ) { + $translations = wp_get_installed_translations( 'themes' ); + } + + $repos = array_filter( + (array) $this->config, + function ( $e ) { + return isset( $e->language_packs ); + } + ); + + foreach ( $repos as $repo ) { + if ( ! str_contains( current_filter(), $repo->type ) ) { + continue; + } + foreach ( $locales as $locale ) { + $lang_pack_mod = isset( $repo->language_packs->$locale ) + ? strtotime( $repo->language_packs->$locale->updated ) + : 0; + $translation_mod = isset( $translations[ $repo->slug ][ $locale ] ) + ? strtotime( $translations[ $repo->slug ][ $locale ]['PO-Revision-Date'] ) + : 0; + if ( $lang_pack_mod > $translation_mod ) { + $transient->translations[] = (array) $repo->language_packs->$locale; + } + } + } + + $transient->translations = array_unique( $transient->translations, SORT_REGULAR ); + + return $transient; + } +} diff --git a/vendor/afragen/translations-updater/src/Translations_Updater/Language_Pack_API.php b/vendor/afragen/translations-updater/src/Translations_Updater/Language_Pack_API.php new file mode 100644 index 0000000..65500ed --- /dev/null +++ b/vendor/afragen/translations-updater/src/Translations_Updater/Language_Pack_API.php @@ -0,0 +1,155 @@ +repo = $config; + $this->response = $this->get_repo_cache( $config->slug ); + } + + /** + * Get/process Language Packs. + * + * @param array $headers Array of headers of Language Pack. + * + * @return bool When invalid response. + */ + public function get_language_pack( $headers ) { + $response = ! empty( $this->response['languages'] ) ? $this->response['languages'] : false; + + if ( ! $response ) { + $response = $this->get_language_pack_json( $this->repo->git, $headers ); + + if ( $response ) { + foreach ( $response as $locale ) { + $package = $this->process_language_pack_package( $this->repo->git, $locale, $headers ); + + $response->{$locale->language}->package = $package; + $response->{$locale->language}->type = $this->repo->type; + $response->{$locale->language}->version = $this->repo->version; + } + $this->set_repo_cache( 'languages', $response, $this->repo->slug ); + } else { + return false; + } + } + $this->repo->language_packs = $response; + + return $this->repo; + } + + /** + * Get language-pack.json from appropriate host. + * + * @param string $git ( github|bitbucket|gitlab|gitea ). + * @param array $headers Repository headers. + * + * @return array|bool|mixed|object $response API response object. + */ + private function get_language_pack_json( $git, $headers ) { + $type = $this->return_repo_type(); + switch ( $git ) { + // phpcs:disable WordPress.PHP.DiscouragedPHPFunctions.obfuscation_base64_decode + case 'github': + $response = $this->api( "/repos/{$headers['owner']}/{$headers['repo']}/contents/language-pack.json" ); + $response = isset( $response->content ) + ? json_decode( base64_decode( $response->content ) ) + : null; + break; + case 'bitbucket': + $response = $this->api( "/2.0/repositories/{$headers['owner']}/{$headers['repo']}/src/{$type['branch']}/language-pack.json" ); + break; + case 'gitlab': + $id = rawurlencode( $headers['owner'] . '/' . $headers['repo'] ); + $response = $this->api( "/projects/{$id}/repository/files/language-pack.json" ); + $response = isset( $response->content ) + ? json_decode( base64_decode( $response->content ) ) + : null; + break; + case 'gitea': + $response = $this->api( "/repos/{$headers['owner']}/{$headers['repo']}/raw/{$type['branch']}/language-pack.json" ); + $response = isset( $response->content ) + ? json_decode( base64_decode( $response->content ) ) + : null; + break; + // phpcs:enable + } + + if ( $this->validate_response( $response ) ) { + return false; + } + + return $response; + } + + /** + * Process $package for update transient. + * + * @param string $git ( github|bitbucket|gitlab|gitea ). + * @param \stdClass $locale Site locale. + * @param array $headers Repository headers. + * + * @return array|null|string + */ + private function process_language_pack_package( $git, $locale, $headers ) { + $package = null; + $type = $this->return_repo_type(); + switch ( $git ) { + case 'github': + $package = [ $headers['uri'], "blob/{$type['branch']}" ]; + $package = implode( '/', $package ) . $locale->package; + $package = add_query_arg( [ 'raw' => 'true' ], $package ); + break; + case 'bitbucket': + $package = [ $headers['uri'], "raw/{$type['branch']}" ]; + $package = implode( '/', $package ) . $locale->package; + break; + case 'gitlab': + $package = [ $headers['uri'], "raw/{$type['branch']}" ]; + $package = implode( '/', $package ) . $locale->package; + break; + case 'gitea': + // TODO: make sure this works. + $package = [ $headers['uri'], "raw/{$type['branch']}" ]; + $package = implode( '/', $package ) . $locale->package; + break; + } + + return $package; + } +} From fb1def942f9f9430f83abc491481cfaa9ac45289 Mon Sep 17 00:00:00 2001 From: Andy Fragen Date: Thu, 14 Nov 2024 14:56:04 -0800 Subject: [PATCH 02/10] Change textdomain from mixed case to lowercase (#191) * update mixed case textdomain to lowercase of aspireupdate references * rename `AspireUpdate` repository to `aspireupdate` * change text domain header * add composer script to more easily create POT file * requires WP-CLI installed locally Signed-off-by: Andy Fragen --- aspire-update.php | 2 +- composer.json | 3 +- includes/class-admin-settings.php | 50 +++++++++---------- includes/class-branding.php | 12 ++--- includes/class-controller.php | 16 ++---- includes/class-debug.php | 8 +-- includes/views/page-admin-settings.php | 8 +-- .../{AspireUpdate.pot => aspireupdate.pot} | 12 ++--- 8 files changed, 51 insertions(+), 60 deletions(-) rename languages/{AspireUpdate.pot => aspireupdate.pot} (95%) diff --git a/aspire-update.php b/aspire-update.php index 4bbcaad..5f45efa 100644 --- a/aspire-update.php +++ b/aspire-update.php @@ -18,7 +18,7 @@ * Tested up to: 6.7 * License: GPLv2 * License URI: https://www.gnu.org/licenses/old-licenses/gpl-2.0.txt - * Text Domain: AspireUpdate + * Text Domain: aspireupdate * Domain Path: /languages * GitHub Plugin URI: https://github.com/aspirepress/AspireUpdate * Primary Branch: main diff --git a/composer.json b/composer.json index 69c86e5..fa95c5d 100644 --- a/composer.json +++ b/composer.json @@ -33,6 +33,7 @@ "test:multisite": [ "Composer\\Config::disableProcessTimeout", "@php ./vendor/phpunit/phpunit/phpunit -c tests/multisite.xml" - ] + ], + "make-pot": "wp i18n make-pot --headers='{\"Report-Msgid-Bugs-To\":\"https://github.com/aspirepress/AspireUpdate/issues\"}' . languages/aspireupdate.pot" } } diff --git a/includes/class-admin-settings.php b/includes/class-admin-settings.php index 55c0f82..c82a113 100644 --- a/includes/class-admin-settings.php +++ b/includes/class-admin-settings.php @@ -136,7 +136,7 @@ public function admin_notices() { add_settings_error( $this->option_name, 'aspireupdate_settings_reset', - esc_html__( 'Settings have been reset to default.', 'AspireUpdate' ), + esc_html__( 'Settings have been reset to default.', 'aspireupdate' ), 'success' ); settings_errors( $this->option_name ); @@ -153,7 +153,7 @@ public function admin_notices() { add_settings_error( $this->option_name, 'aspireupdate_settings_saved', - esc_html__( 'Settings Saved', 'AspireUpdate' ), + esc_html__( 'Settings Saved', 'aspireupdate' ), 'success' ); settings_errors( $this->option_name ); @@ -322,11 +322,11 @@ public function admin_enqueue_scripts( $hook ) { 'aspire_update_settings_js', 'aspireupdate', [ - 'ajax_url' => network_admin_url( 'admin-ajax.php' ), - 'nonce' => wp_create_nonce( 'aspireupdate-ajax' ), - 'domain' => Utilities::get_top_level_domain(), - 'line_ending' => PHP_EOL, - 'unexpected_error' => esc_html__( 'Unexpected Error', 'AspireUpdate' ), + 'ajax_url' => network_admin_url( 'admin-ajax.php' ), + 'nonce' => wp_create_nonce( 'aspireupdate-ajax' ), + 'domain' => Utilities::get_top_level_domain(), + 'line_ending' => PHP_EOL, + 'unexpected_error' => esc_html__( 'Unexpected Error', 'aspireupdate' ), ] ); } @@ -380,7 +380,7 @@ public function register_settings() { add_settings_section( 'aspireupdate_settings_section', - esc_html__( 'API Configuration', 'AspireUpdate' ), + esc_html__( 'API Configuration', 'aspireupdate' ), null, 'aspireupdate-settings', [ @@ -391,7 +391,7 @@ public function register_settings() { add_settings_field( 'enable', - esc_html__( 'Enable AspireUpdate API Rewrites', 'AspireUpdate' ), + esc_html__( 'Enable AspireUpdate API Rewrites', 'aspireupdate' ), [ $this, 'add_settings_field_callback' ], 'aspireupdate-settings', 'aspireupdate_settings_section', @@ -404,7 +404,7 @@ public function register_settings() { add_settings_field( 'api_host', - esc_html__( 'API Host', 'AspireUpdate' ), + esc_html__( 'API Host', 'aspireupdate' ), [ $this, 'add_settings_field_callback' ], 'aspireupdate-settings', 'aspireupdate_settings_section', @@ -412,7 +412,7 @@ public function register_settings() { 'id' => 'api_host', 'type' => 'hosts', 'data' => $options, - 'description' => esc_html__( 'Your new API Host.', 'AspireUpdate' ), + 'description' => esc_html__( 'Your new API Host.', 'aspireupdate' ), 'options' => [ [ 'value' => 'api.aspirecloud.org', @@ -422,7 +422,7 @@ public function register_settings() { ], [ 'value' => 'other', - 'label' => esc_html__( 'Other', 'AspireUpdate' ), + 'label' => esc_html__( 'Other', 'aspireupdate' ), 'require-api-key' => 'false', ], ], @@ -431,7 +431,7 @@ public function register_settings() { add_settings_field( 'api_key', - esc_html__( 'API Key', 'AspireUpdate' ), + esc_html__( 'API Key', 'aspireupdate' ), [ $this, 'add_settings_field_callback' ], 'aspireupdate-settings', 'aspireupdate_settings_section', @@ -439,13 +439,13 @@ public function register_settings() { 'id' => 'api_key', 'type' => 'api-key', 'data' => $options, - 'description' => esc_html__( 'Provides an API key for repositories that may require authentication.', 'AspireUpdate' ), + 'description' => esc_html__( 'Provides an API key for repositories that may require authentication.', 'aspireupdate' ), ] ); add_settings_section( 'aspireupdate_debug_settings_section', - esc_html__( 'API Debug Configuration', 'AspireUpdate' ), + esc_html__( 'API Debug Configuration', 'aspireupdate' ), null, 'aspireupdate-settings', [ @@ -456,7 +456,7 @@ public function register_settings() { add_settings_field( 'enable_debug', - esc_html__( 'Enable Debug Mode', 'AspireUpdate' ), + esc_html__( 'Enable Debug Mode', 'aspireupdate' ), [ $this, 'add_settings_field_callback' ], 'aspireupdate-settings', 'aspireupdate_debug_settings_section', @@ -464,13 +464,13 @@ public function register_settings() { 'id' => 'enable_debug', 'type' => 'checkbox', 'data' => $options, - 'description' => esc_html__( 'Enables debug mode for the plugin.', 'AspireUpdate' ), + 'description' => esc_html__( 'Enables debug mode for the plugin.', 'aspireupdate' ), ] ); add_settings_field( 'enable_debug_type', - esc_html__( 'Enable Debug Type', 'AspireUpdate' ), + esc_html__( 'Enable Debug Type', 'aspireupdate' ), [ $this, 'add_settings_field_callback' ], 'aspireupdate-settings', 'aspireupdate_debug_settings_section', @@ -479,17 +479,17 @@ public function register_settings() { 'type' => 'checkbox-group', 'data' => $options, 'options' => [ - 'request' => esc_html__( 'Request', 'AspireUpdate' ), - 'response' => esc_html__( 'Response', 'AspireUpdate' ), - 'string' => esc_html__( 'String', 'AspireUpdate' ), + 'request' => esc_html__( 'Request', 'aspireupdate' ), + 'response' => esc_html__( 'Response', 'aspireupdate' ), + 'string' => esc_html__( 'String', 'aspireupdate' ), ], - 'description' => esc_html__( 'Outputs the request URL and headers / response headers and body / string that is being rewritten.', 'AspireUpdate' ), + 'description' => esc_html__( 'Outputs the request URL and headers / response headers and body / string that is being rewritten.', 'aspireupdate' ), ] ); add_settings_field( 'disable_ssl_verification', - esc_html__( 'Disable SSL Verification', 'AspireUpdate' ), + esc_html__( 'Disable SSL Verification', 'aspireupdate' ), [ $this, 'add_settings_field_callback' ], 'aspireupdate-settings', 'aspireupdate_debug_settings_section', @@ -498,7 +498,7 @@ public function register_settings() { 'type' => 'checkbox', 'data' => $options, 'class' => 'advanced-setting', - 'description' => esc_html__( 'Disables the verification of SSL to allow local testing.', 'AspireUpdate' ), + 'description' => esc_html__( 'Disables the verification of SSL to allow local testing.', 'aspireupdate' ), ] ); } @@ -561,7 +561,7 @@ public function add_settings_field_callback( $args = [] ) { case 'api-key': ?> - +

%1$s. Learn more', 'AspireUpdate' ), + __( 'Your plugin updates are now powered by %1$s. Learn more', 'aspireupdate' ), 'AspireUpdate', - __( 'https://docs.aspirepress.org/aspireupdate/', 'AspireUpdate' ) + __( 'https://docs.aspirepress.org/aspireupdate/', 'aspireupdate' ) ); break; case 'themes': @@ -109,9 +109,9 @@ public function output_admin_notice() { case 'theme-install-network': $message = sprintf( /* translators: 1: The name of the plugin, 2: The documentation URL. */ - __( 'Your theme updates are now powered by %1$s. Learn more', 'AspireUpdate' ), + __( 'Your theme updates are now powered by %1$s. Learn more', 'aspireupdate' ), 'AspireUpdate', - __( 'https://docs.aspirepress.org/aspireupdate/', 'AspireUpdate' ) + __( 'https://docs.aspirepress.org/aspireupdate/', 'aspireupdate' ) ); break; case 'update-core': @@ -122,9 +122,9 @@ public function output_admin_notice() { case 'update-core-network': $message = sprintf( /* translators: 1: The name of the plugin, 2: The documentation URL. */ - __( 'Your WordPress, plugin, theme and translation updates are now powered by %1$s. Learn more', 'AspireUpdate' ), + __( 'Your WordPress, plugin, theme and translation updates are now powered by %1$s. Learn more', 'aspireupdate' ), 'AspireUpdate', - __( 'https://docs.aspirepress.org/aspireupdate/', 'AspireUpdate' ) + __( 'https://docs.aspirepress.org/aspireupdate/', 'aspireupdate' ) ); break; } diff --git a/includes/class-controller.php b/includes/class-controller.php index 43b41c7..672dd1d 100644 --- a/includes/class-controller.php +++ b/includes/class-controller.php @@ -20,7 +20,6 @@ public function __construct() { Themes_Screens::get_instance(); Branding::get_instance(); $this->api_rewrite(); - add_action( 'init', [ $this, 'load_textdomain' ] ); add_action( 'wp_ajax_aspireupdate_clear_log', [ $this, 'clear_log' ] ); add_action( 'wp_ajax_aspireupdate_read_log', [ $this, 'read_log' ] ); } @@ -59,7 +58,7 @@ public function clear_log() { if ( ! isset( $_POST['nonce'] ) || ! wp_verify_nonce( sanitize_key( $_POST['nonce'] ), 'aspireupdate-ajax' ) ) { wp_send_json_error( [ - 'message' => __( 'Error: You are not authorized to access this resource.', 'AspireUpdate' ), + 'message' => __( 'Error: You are not authorized to access this resource.', 'aspireupdate' ), ] ); } @@ -75,7 +74,7 @@ public function clear_log() { wp_send_json_success( [ - 'message' => __( 'Log file cleared successfully.', 'AspireUpdate' ), + 'message' => __( 'Log file cleared successfully.', 'aspireupdate' ), ] ); } @@ -89,7 +88,7 @@ public function read_log() { if ( ! isset( $_POST['nonce'] ) || ! wp_verify_nonce( sanitize_key( $_POST['nonce'] ), 'aspireupdate-ajax' ) ) { wp_send_json_error( [ - 'message' => __( 'Error: You are not authorized to access this resource.', 'AspireUpdate' ), + 'message' => __( 'Error: You are not authorized to access this resource.', 'aspireupdate' ), ] ); } @@ -109,13 +108,4 @@ public function read_log() { ] ); } - - /** - * Load translations. - * - * @return void - */ - public function load_textdomain() { - \load_plugin_textdomain( 'AspireUpdate', false, AP_PATH . '/languages/' ); - } } diff --git a/includes/class-debug.php b/includes/class-debug.php index 182cc02..eba51fd 100644 --- a/includes/class-debug.php +++ b/includes/class-debug.php @@ -82,7 +82,7 @@ public static function read( $limit = 1000 ) { $wp_filesystem = self::init_filesystem(); $file_path = self::get_file_path(); if ( ! self::verify_filesystem( $wp_filesystem ) || ! $wp_filesystem->exists( $file_path ) || ! $wp_filesystem->is_readable( $file_path ) ) { - return new \WP_Error( 'not_readable', __( 'Error: Unable to read the log file.', 'AspireUpdate' ) ); + return new \WP_Error( 'not_readable', __( 'Error: Unable to read the log file.', 'aspireupdate' ) ); } $file_content = $wp_filesystem->get_contents_array( $file_path ); @@ -95,11 +95,11 @@ public static function read( $limit = 1000 ) { } } if ( '' === trim( $content ) ) { - $content = esc_html__( '*****Log file is empty.*****', 'AspireUpdate' ); + $content = esc_html__( '*****Log file is empty.*****', 'aspireupdate' ); } elseif ( $limit < count( $file_content ) ) { $content .= PHP_EOL . sprintf( /* translators: 1: The number of lines at which the content was truncated. */ - esc_html__( '*****Log truncated at %s lines.*****', 'AspireUpdate' ), + esc_html__( '*****Log truncated at %s lines.*****', 'aspireupdate' ), $limit ); } @@ -115,7 +115,7 @@ public static function clear() { $wp_filesystem = self::init_filesystem(); $file_path = self::get_file_path(); if ( ! self::verify_filesystem( $wp_filesystem ) || ! $wp_filesystem->exists( $file_path ) || ! $wp_filesystem->is_writable( $file_path ) ) { - return new \WP_Error( 'not_accessible', __( 'Error: Unable to access the log file.', 'AspireUpdate' ) ); + return new \WP_Error( 'not_accessible', __( 'Error: Unable to access the log file.', 'aspireupdate' ) ); } $wp_filesystem->put_contents( diff --git a/includes/views/page-admin-settings.php b/includes/views/page-admin-settings.php index 4649029..5662ce4 100644 --- a/includes/views/page-admin-settings.php +++ b/includes/views/page-admin-settings.php @@ -5,7 +5,7 @@ $option_group = $args['option_group'] ?? ''; ?>
-

+

- - - + + +

diff --git a/languages/AspireUpdate.pot b/languages/aspireupdate.pot similarity index 95% rename from languages/AspireUpdate.pot rename to languages/aspireupdate.pot index d91f733..8eb59b3 100644 --- a/languages/AspireUpdate.pot +++ b/languages/aspireupdate.pot @@ -3,16 +3,16 @@ msgid "" msgstr "" "Project-Id-Version: AspireUpdate 0.6\n" -"Report-Msgid-Bugs-To: https://github.com/aspirepress/AspireUpdate\n" +"Report-Msgid-Bugs-To: https://github.com/aspirepress/AspireUpdate/issues\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"POT-Creation-Date: 2024-11-14T00:37:56+00:00\n" +"POT-Creation-Date: 2024-11-14T19:18:59+00:00\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "X-Generator: WP-CLI 2.11.0\n" -"X-Domain: AspireUpdate\n" +"X-Domain: aspireupdate\n" #. Plugin Name of the plugin #: aspire-update.php @@ -141,12 +141,12 @@ msgstr "" msgid "Your WordPress, plugin, theme and translation updates are now powered by %1$s. Learn more" msgstr "" -#: includes/class-controller.php:62 -#: includes/class-controller.php:92 +#: includes/class-controller.php:61 +#: includes/class-controller.php:91 msgid "Error: You are not authorized to access this resource." msgstr "" -#: includes/class-controller.php:78 +#: includes/class-controller.php:77 msgid "Log file cleared successfully." msgstr "" From d65f3298b719b82252d029f6f60db3527893519d Mon Sep 17 00:00:00 2001 From: Andy Fragen Date: Thu, 14 Nov 2024 15:50:34 -0800 Subject: [PATCH 03/10] update referenced to mixed case repository (#193) --- .github/ISSUE_TEMPLATE/BugReport.yml | 19 +++++++++---------- .github/workflows/playground-blueprint.yml | 3 +-- README.md | 4 ++-- aspire-update.php | 2 +- composer.json | 2 +- languages/aspireupdate.pot | 2 +- 6 files changed, 15 insertions(+), 17 deletions(-) diff --git a/.github/ISSUE_TEMPLATE/BugReport.yml b/.github/ISSUE_TEMPLATE/BugReport.yml index ddbdcab..92355b2 100644 --- a/.github/ISSUE_TEMPLATE/BugReport.yml +++ b/.github/ISSUE_TEMPLATE/BugReport.yml @@ -37,7 +37,7 @@ body: default: 0 validations: required: true - + - type: dropdown id: os attributes: @@ -50,7 +50,7 @@ body: - Android - Linux - Other - + - type: dropdown id: browsers @@ -70,19 +70,19 @@ body: attributes: label: 'WordPress' description: 'The version of WordPress that your site uses.' - + - type: input id: php attributes: label: 'PHP' description: 'The version of PHP your site runs on.' - + - type: input id: server attributes: label: 'Server' description: 'The server your site runs on (apache, nginx, etc).' - + - type: input id: database attributes: @@ -94,19 +94,19 @@ body: attributes: label: 'Theme' description: 'The currently active theme.' - + - type: input id: must_use_plugins attributes: label: 'Must-Use Plugins' description: 'A list of Must-Use Plugins.' - + - type: input id: plugins attributes: label: 'Plugins' description: 'A list of active plugins.' - + - type: textarea @@ -140,9 +140,8 @@ body: id: terms attributes: label: Code of Conduct - description: By submitting this issue, you agree to follow the AspirePress [Code of Conduct](https://github.com/aspirepress/AspireUpdate?tab=coc-ov-file). + description: By submitting this issue, you agree to follow the AspirePress [Code of Conduct](https://github.com/aspirepress/aspireupdate?tab=coc-ov-file). options: - label: I agree to follow the Code of Conduct. required: true - diff --git a/.github/workflows/playground-blueprint.yml b/.github/workflows/playground-blueprint.yml index 99e9406..74c2643 100644 --- a/.github/workflows/playground-blueprint.yml +++ b/.github/workflows/playground-blueprint.yml @@ -9,7 +9,7 @@ on: jobs: update-blueprint: - if: github.repository == 'aspirepress/AspireUpdate' + if: github.repository == 'aspirepress/aspireupdate' runs-on: ubuntu-latest permissions: contents: write @@ -43,4 +43,3 @@ jobs: fi env: name: ${{ env.name }} - diff --git a/README.md b/README.md index efbdde1..81384bf 100644 --- a/README.md +++ b/README.md @@ -59,9 +59,9 @@ NOTE 2: Setting AP_REMOVE_UI to `true` removes the plugin user interface. This i ## WP Playgrounds Support -The AspireUpdate current build ('main' branch) can be [experimented with in the WP Playground environment](https://playground.wordpress.net/?blueprint-url=https://raw.githubusercontent.com/aspirepress/AspireUpdate/refs/heads/main/assets/playground/blueprint.json). +The AspireUpdate current build ('main' branch) can be [experimented with in the WP Playground environment](https://playground.wordpress.net/?blueprint-url=https://raw.githubusercontent.com/aspirepress/aspireupdate/refs/heads/main/assets/playground/blueprint.json). -The AspireUpdate stable build ('playground-ready' branch) can be [tested with in the WP Playground environment](https://playground.wordpress.net/?blueprint-url=https://raw.githubusercontent.com/aspirepress/AspireUpdate/refs/heads/playground-ready/assets/playground/blueprint.json). +The AspireUpdate stable build ('playground-ready' branch) can be [tested with in the WP Playground environment](https://playground.wordpress.net/?blueprint-url=https://raw.githubusercontent.com/aspirepress/aspireupdate/refs/heads/playground-ready/assets/playground/blueprint.json). ## Debug Logging diff --git a/aspire-update.php b/aspire-update.php index 5f45efa..1c2a792 100644 --- a/aspire-update.php +++ b/aspire-update.php @@ -20,7 +20,7 @@ * License URI: https://www.gnu.org/licenses/old-licenses/gpl-2.0.txt * Text Domain: aspireupdate * Domain Path: /languages - * GitHub Plugin URI: https://github.com/aspirepress/AspireUpdate + * GitHub Plugin URI: https://github.com/aspirepress/aspireupdate * Primary Branch: main */ diff --git a/composer.json b/composer.json index fa95c5d..8cc2c4f 100644 --- a/composer.json +++ b/composer.json @@ -34,6 +34,6 @@ "Composer\\Config::disableProcessTimeout", "@php ./vendor/phpunit/phpunit/phpunit -c tests/multisite.xml" ], - "make-pot": "wp i18n make-pot --headers='{\"Report-Msgid-Bugs-To\":\"https://github.com/aspirepress/AspireUpdate/issues\"}' . languages/aspireupdate.pot" + "make-pot": "wp i18n make-pot --headers='{\"Report-Msgid-Bugs-To\":\"https://github.com/aspirepress/aspireupdate/issues\"}' . languages/aspireupdate.pot" } } diff --git a/languages/aspireupdate.pot b/languages/aspireupdate.pot index 8eb59b3..3ae99fc 100644 --- a/languages/aspireupdate.pot +++ b/languages/aspireupdate.pot @@ -3,7 +3,7 @@ msgid "" msgstr "" "Project-Id-Version: AspireUpdate 0.6\n" -"Report-Msgid-Bugs-To: https://github.com/aspirepress/AspireUpdate/issues\n" +"Report-Msgid-Bugs-To: https://github.com/aspirepress/aspireupdate/issues\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" "MIME-Version: 1.0\n" From 2a87d5fe81b59877e6aab42dad13c507f4a63023 Mon Sep 17 00:00:00 2001 From: Andy Fragen Date: Sat, 16 Nov 2024 02:36:57 -0800 Subject: [PATCH 04/10] add GA to generate POT on tag/release (#196) --- .github/workflows/generate-pot.yml | 22 ++++++++++++++++++++++ composer.json | 3 +-- 2 files changed, 23 insertions(+), 2 deletions(-) create mode 100644 .github/workflows/generate-pot.yml diff --git a/.github/workflows/generate-pot.yml b/.github/workflows/generate-pot.yml new file mode 100644 index 0000000..03cb925 --- /dev/null +++ b/.github/workflows/generate-pot.yml @@ -0,0 +1,22 @@ +name: Generate POT + +on: + push: + tags: + - "**" + +jobs: + WP_POT_Generator: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@master + - name: WordPress POT Generator + uses: varunsridharan/action-wp-pot-generator@^2 + with: + save_path: "./languages" + item_slug: "${{ github.event.repository.name }}" + domain: "${{ github.event.repository.name }}" + package_name: "${{ github.event.repository.name }}" + headers: '{"Report-Msgid-Bugs-To":"https://github.com/${{ github.event.repository.full_name }}/issues"}' + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} diff --git a/composer.json b/composer.json index 8cc2c4f..69c86e5 100644 --- a/composer.json +++ b/composer.json @@ -33,7 +33,6 @@ "test:multisite": [ "Composer\\Config::disableProcessTimeout", "@php ./vendor/phpunit/phpunit/phpunit -c tests/multisite.xml" - ], - "make-pot": "wp i18n make-pot --headers='{\"Report-Msgid-Bugs-To\":\"https://github.com/aspirepress/aspireupdate/issues\"}' . languages/aspireupdate.pot" + ] } } From e91fe5d17f236fbe2ed7b8a64b6dbc1c9dbaa39d Mon Sep 17 00:00:00 2001 From: Andy Fragen Date: Sun, 17 Nov 2024 12:50:54 -0800 Subject: [PATCH 05/10] run GA on push to `main` and feature branch (#197) --- .github/workflows/generate-pot.yml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/.github/workflows/generate-pot.yml b/.github/workflows/generate-pot.yml index 03cb925..13424d0 100644 --- a/.github/workflows/generate-pot.yml +++ b/.github/workflows/generate-pot.yml @@ -2,11 +2,15 @@ name: Generate POT on: push: + branches: + - main + - translations tags: - "**" jobs: WP_POT_Generator: + if: github.repository == 'aspirepress/aspireupdate' runs-on: ubuntu-latest steps: - uses: actions/checkout@master From 974b8fe79a0e586cc406b687c2c80930a7fbab8b Mon Sep 17 00:00:00 2001 From: Andy Fragen Date: Fri, 22 Nov 2024 17:04:34 -0800 Subject: [PATCH 06/10] update afragen/translations-updater with error caching/logging (#199) * update afragen/translations-updater with error caching/logging * fix return of false due to validation failure * return WP_Error instead of false * better error handling * updates to afragen/translations-updater * composer update * update error log messaging * update library --- composer.lock | 10 +- .../afragen/translations-updater/CHANGES.md | 9 ++ vendor/afragen/translations-updater/README.md | 6 +- .../translations-updater/composer.json | 2 +- .../src/Translations_Updater/API.php | 91 +++++++++++++++++-- .../Translations_Updater/Language_Pack.php | 7 +- .../Language_Pack_API.php | 10 +- 7 files changed, 115 insertions(+), 20 deletions(-) diff --git a/composer.lock b/composer.lock index b196fe0..84cc1c4 100644 --- a/composer.lock +++ b/composer.lock @@ -49,16 +49,16 @@ }, { "name": "afragen/translations-updater", - "version": "1.0.1", + "version": "1.2.0", "source": { "type": "git", "url": "https://github.com/afragen/translations-updater.git", - "reference": "0bde072a1bf92ddc43837f6a27b9475b651350ea" + "reference": "c688e85eeef136f9cd7a4719db94ab0fc241601e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/afragen/translations-updater/zipball/0bde072a1bf92ddc43837f6a27b9475b651350ea", - "reference": "0bde072a1bf92ddc43837f6a27b9475b651350ea", + "url": "https://api.github.com/repos/afragen/translations-updater/zipball/c688e85eeef136f9cd7a4719db94ab0fc241601e", + "reference": "c688e85eeef136f9cd7a4719db94ab0fc241601e", "shasum": "" }, "require": { @@ -98,7 +98,7 @@ "issues": "https://github.com/afragen/translations-updater/issues", "source": "https://github.com/afragen/translations-updater" }, - "time": "2024-11-13T00:36:43+00:00" + "time": "2024-11-19T17:24:59+00:00" } ], "packages-dev": [ diff --git a/vendor/afragen/translations-updater/CHANGES.md b/vendor/afragen/translations-updater/CHANGES.md index 71017b9..baa0190 100644 --- a/vendor/afragen/translations-updater/CHANGES.md +++ b/vendor/afragen/translations-updater/CHANGES.md @@ -1,5 +1,14 @@ #### [unreleased] +#### 1.2.0 / 2024-11-19 +* return `WP_Error` in `Language_Pack_API::get_language_pack()` with validation error +* exit gracefully if `Language_Pack_API::get_language_pack()` returns `WP_Error` +* updated error logging for GitHub API rate limits + +#### 1.1.0 / 2024-11-16 +* add API error caching/logging +* always return `$this->repo` in `Language_Pack_API::get_language_pack()` + #### 1.0.1 / 2024-11-12 * fixed a hard-coded 'master' branch in `Language_Pack_API::process_language_pack_package()` diff --git a/vendor/afragen/translations-updater/README.md b/vendor/afragen/translations-updater/README.md index eb38dd6..1c7acc6 100644 --- a/vendor/afragen/translations-updater/README.md +++ b/vendor/afragen/translations-updater/README.md @@ -13,11 +13,11 @@ This framework allows for decoupled language pack updates for your WordPress plugins or themes that are hosted on public repositories in GitHub, Bitbucket, GitLab, or Gitea. - The URI should point to a repository that contains the translations files. Refer to [GitHub Updater Translations](https://github.com/afragen/github-updater-translations) as an example. It is created using the [Language Pack Maker](https://github.com/afragen/language-pack-maker). The repo **must** be a public repo. + The URI should point to a repository that contains the translations files. Refer to [Git Updater Translations](https://github.com/afragen/git-updater-translations) as an example. It is created using the [Language Pack Maker](https://github.com/afragen/language-pack-maker). The repo **must** be a public repo. ## Usage -Install via Composer: `composer require afragen/translations-updater:dev-master` +Install via Composer: `composer require afragen/translations-updater:^1` **Prior to release use the following command** `composer require afragen/translations-updater:dev-` currently `dev-master` @@ -34,7 +34,7 @@ add_action( 'admin_init', function() { 'slug' => 'my-repo-slug', // Should be lowercase. 'version' => 'my-repo-version', // Current version of plugin|theme. 'languages' => 'https://my-path-to/language-packs', - 'branch' => 'master', // Default. + 'branch' => 'master', // Default (optional). ]; ( new \Fragen\Translations_Updater\Init() )->run( $config ); diff --git a/vendor/afragen/translations-updater/composer.json b/vendor/afragen/translations-updater/composer.json index 7d049ab..ead3d9f 100644 --- a/vendor/afragen/translations-updater/composer.json +++ b/vendor/afragen/translations-updater/composer.json @@ -3,7 +3,7 @@ "description": "This framework provides automatic decoupled languate pack updates from a public repository for your WordPress plugin or theme.", "type": "library", "license": "MIT", - "version": "1.0.1", + "version": "1.2.0", "keywords": [ "wordpress", "plugin", diff --git a/vendor/afragen/translations-updater/src/Translations_Updater/API.php b/vendor/afragen/translations-updater/src/Translations_Updater/API.php index 5fd6951..db12835 100644 --- a/vendor/afragen/translations-updater/src/Translations_Updater/API.php +++ b/vendor/afragen/translations-updater/src/Translations_Updater/API.php @@ -37,6 +37,13 @@ trait API { */ protected $response = []; + /** + * Holds HTTP error code from API call. + * + * @var array ( $this->repo->slug => $code ) + */ + protected static $error_code = []; + /** * Return repo data for API calls. * @@ -82,10 +89,59 @@ final protected function return_repo_type() { * @return boolean|\stdClass */ final protected function api( $url ) { - $response = wp_remote_get( $this->get_api_url( $url ) ); + $url = $this->get_api_url( $url ); + $args = []; + + // Use cached API failure data to avoid hammering the API. + $response = $this->get_repo_cache( md5( $url ) ); + $cached = isset( $response['error_cache'] ); + $response = $response ? $response['error_cache'] : $response; + $response = empty( $response ) + ? wp_remote_get( $url, $args ) + : $response; + + $code = (int) wp_remote_retrieve_response_code( $response ); + $allowed_codes = [ 200 ]; if ( is_wp_error( $response ) ) { - return false; + // phpcs:ignore WordPress.PHP.DevelopmentFunctions + error_log( var_export( $response, true ) ); + + return $response; + } + + // Cache HTTP API error code for 60 minutes. + if ( ! in_array( $code, $allowed_codes, true ) && ! $cached ) { + $timeout = 60; + + // Set timeout to GitHub rate limit reset. + $timeout = static::ratelimit_reset( $response, $this->repo->slug ); + $response['timeout'] = $timeout; + $this->set_repo_cache( 'error_cache', $response, md5( $url ), "+{$timeout} minutes" ); + } + + static::$error_code[ $this->repo->slug ] = static::$error_code[ $this->repo->slug ] ?? []; + static::$error_code[ $this->repo->slug ] = array_merge( + static::$error_code[ $this->repo->slug ], + [ + 'repo' => $this->repo->slug, + 'code' => $code, + 'name' => $this->repo->name ?? $this->repo->slug, + 'git' => $this->repo->git, + ] + ); + if ( isset( $response['timeout'] ) ) { + static::$error_code[ $this->repo->slug ]['wait'] = static::ratelimit_reset( $response, $this->repo->slug ); + } + + if ( isset( $response['timeout'] ) && defined( 'WP_DEBUG' ) && WP_DEBUG ) { + $response_body = json_decode( wp_remote_retrieve_body( $response ) ); + if ( null !== $response_body && property_exists( $response_body, 'message' ) ) { + $log_message = "Translations Updater Error: {$this->repo->slug} - {$response_body->message}" + . "\nTime remaining for rate limiting: {$this->ratelimit_reset($response, $this->repo->slug)} minutes"; + // phpcs:ignore WordPress.PHP.DevelopmentFunctions.error_log_error_log + error_log( $log_message ); + } } return json_decode( wp_remote_retrieve_body( $response ) ); @@ -137,7 +193,7 @@ final protected function validate_response( $response ) { */ final protected function get_repo_cache( $repo = false ) { if ( ! $repo ) { - $repo = isset( $this->type->slug ) ? $this->type->slug : 'tu'; + $repo = isset( $this->repo->slug ) ? $this->repo->slug : 'tu'; } $cache_key = 'tu-' . md5( $repo ); $cache = get_site_option( $cache_key ); @@ -158,12 +214,12 @@ final protected function get_repo_cache( $repo = false ) { * * @return bool */ - final protected function set_repo_cache( $id, $response, $repo = false ) { + final protected function set_repo_cache( $id, $response, $repo = false, $timeout = false ) { if ( ! $repo ) { - $repo = isset( $this->type->slug ) ? $this->type->slug : 'tu'; + $repo = isset( $this->repo->slug ) ? $this->repo->slug : 'tu'; } $cache_key = 'tu-' . md5( $repo ); - $timeout = '+' . self::$hours . ' hours'; + $timeout = $timeout ? $timeout : '+' . static::$hours . ' hours'; $this->response['timeout'] = strtotime( $timeout ); $this->response[ $id ] = $response; @@ -172,4 +228,27 @@ final protected function set_repo_cache( $id, $response, $repo = false ) { return true; } + + /** + * Calculate and store time until rate limit reset. + * + * @param array $response HTTP headers. + * @param string $repo Repo name. + * + * @return void|int + */ + final public static function ratelimit_reset( $response, $repo ) { + $headers = wp_remote_retrieve_headers( $response ); + $data = $headers->getAll(); + $wait = 0; + if ( isset( $data['x-ratelimit-reset'] ) ) { + $reset = (int) $data['x-ratelimit-reset']; + //phpcs:ignore WordPress.DateTime.RestrictedFunctions.date_date + $wait = date( 'i', $reset - time() ); + static::$error_code[ $repo ] = static::$error_code[ $repo ] ?? []; + static::$error_code[ $repo ] = array_merge( static::$error_code[ $repo ], [ 'wait' => $wait ] ); + + return $wait; + } + } } diff --git a/vendor/afragen/translations-updater/src/Translations_Updater/Language_Pack.php b/vendor/afragen/translations-updater/src/Translations_Updater/Language_Pack.php index 4d074f6..0386183 100644 --- a/vendor/afragen/translations-updater/src/Translations_Updater/Language_Pack.php +++ b/vendor/afragen/translations-updater/src/Translations_Updater/Language_Pack.php @@ -58,8 +58,11 @@ public function __construct( $config, Language_Pack_API $api ) { * Do the Language Pack integration. */ public function run() { - $headers = $this->parse_header_uri( $this->repo->languages ); - $repo = $this->repo_api->get_language_pack( $headers ); + $headers = $this->parse_header_uri( $this->repo->languages ); + $repo = $this->repo_api->get_language_pack( $headers ); + if ( is_wp_error( $repo ) ) { + return; + } $this->config[ $repo->slug ] = $repo; add_filter( 'site_transient_update_plugins', [ $this, 'update_site_transient' ] ); diff --git a/vendor/afragen/translations-updater/src/Translations_Updater/Language_Pack_API.php b/vendor/afragen/translations-updater/src/Translations_Updater/Language_Pack_API.php index 65500ed..b69fb90 100644 --- a/vendor/afragen/translations-updater/src/Translations_Updater/Language_Pack_API.php +++ b/vendor/afragen/translations-updater/src/Translations_Updater/Language_Pack_API.php @@ -47,7 +47,7 @@ public function __construct( $config ) { * * @param array $headers Array of headers of Language Pack. * - * @return bool When invalid response. + * @return \stdClass|\WP_Error */ public function get_language_pack( $headers ) { $response = ! empty( $this->response['languages'] ) ? $this->response['languages'] : false; @@ -65,7 +65,11 @@ public function get_language_pack( $headers ) { } $this->set_repo_cache( 'languages', $response, $this->repo->slug ); } else { - return false; + return new \WP_Error( + 'language_pack_validation_error', + 'API timeout error', + [ self::$error_code ] + ); } } $this->repo->language_packs = $response; @@ -124,7 +128,7 @@ private function get_language_pack_json( $git, $headers ) { * @param \stdClass $locale Site locale. * @param array $headers Repository headers. * - * @return array|null|string + * @return string */ private function process_language_pack_package( $git, $locale, $headers ) { $package = null; From 412fd82ee460d6c8eeaa8453e46b51e3d09086fa Mon Sep 17 00:00:00 2001 From: Andy Fragen Date: Sat, 23 Nov 2024 17:43:19 -0800 Subject: [PATCH 07/10] Fix version number in POT workflow (#202) --- .github/workflows/generate-pot.yml | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/.github/workflows/generate-pot.yml b/.github/workflows/generate-pot.yml index 13424d0..90c6744 100644 --- a/.github/workflows/generate-pot.yml +++ b/.github/workflows/generate-pot.yml @@ -5,8 +5,6 @@ on: branches: - main - translations - tags: - - "**" jobs: WP_POT_Generator: @@ -15,7 +13,7 @@ jobs: steps: - uses: actions/checkout@master - name: WordPress POT Generator - uses: varunsridharan/action-wp-pot-generator@^2 + uses: varunsridharan/action-wp-pot-generator@2 with: save_path: "./languages" item_slug: "${{ github.event.repository.name }}" From cac938b38375978c093a72c4d6dfcc805d2cccc1 Mon Sep 17 00:00:00 2001 From: Colin Stewart <79332690+costdev@users.noreply.github.com> Date: Sun, 24 Nov 2024 02:02:42 +0000 Subject: [PATCH 08/10] Set POT generation action version to `2.0`. (#204) --- .github/workflows/generate-pot.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/generate-pot.yml b/.github/workflows/generate-pot.yml index 90c6744..0f82133 100644 --- a/.github/workflows/generate-pot.yml +++ b/.github/workflows/generate-pot.yml @@ -13,7 +13,7 @@ jobs: steps: - uses: actions/checkout@master - name: WordPress POT Generator - uses: varunsridharan/action-wp-pot-generator@2 + uses: varunsridharan/action-wp-pot-generator@2.0 with: save_path: "./languages" item_slug: "${{ github.event.repository.name }}" From 63a7e5baf55b36dfea5a43c824b30492885391f1 Mon Sep 17 00:00:00 2001 From: Colin Stewart <79332690+costdev@users.noreply.github.com> Date: Sun, 24 Nov 2024 02:58:21 +0000 Subject: [PATCH 09/10] Add write permissions to POT generation workflow. (#205) --- .github/workflows/generate-pot.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/generate-pot.yml b/.github/workflows/generate-pot.yml index 0f82133..e3e39bf 100644 --- a/.github/workflows/generate-pot.yml +++ b/.github/workflows/generate-pot.yml @@ -10,6 +10,8 @@ jobs: WP_POT_Generator: if: github.repository == 'aspirepress/aspireupdate' runs-on: ubuntu-latest + permissions: + contents: write steps: - uses: actions/checkout@master - name: WordPress POT Generator From ce42edb0036487fde433ea462e3e4bb0a707cd20 Mon Sep 17 00:00:00 2001 From: WordPress BOT Date: Sun, 24 Nov 2024 02:58:38 +0000 Subject: [PATCH 10/10] =?UTF-8?q?=F0=9F=92=AC=20POT=20File=20Regenerated?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- languages/aspireupdate.pot | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/languages/aspireupdate.pot b/languages/aspireupdate.pot index 3ae99fc..37a204c 100644 --- a/languages/aspireupdate.pot +++ b/languages/aspireupdate.pot @@ -2,14 +2,14 @@ # This file is distributed under the GPLv2. msgid "" msgstr "" -"Project-Id-Version: AspireUpdate 0.6\n" +"Project-Id-Version: aspireupdate 0.6\n" "Report-Msgid-Bugs-To: https://github.com/aspirepress/aspireupdate/issues\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"POT-Creation-Date: 2024-11-14T19:18:59+00:00\n" +"POT-Creation-Date: 2024-11-24T02:58:38+00:00\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "X-Generator: WP-CLI 2.11.0\n" "X-Domain: aspireupdate\n"