Skip to content

Commit

Permalink
remove local languaged embedding
Browse files Browse the repository at this point in the history
  • Loading branch information
threadi committed Oct 21, 2023
1 parent 80df79a commit daf94a3
Show file tree
Hide file tree
Showing 8 changed files with 76 additions and 29 deletions.
11 changes: 0 additions & 11 deletions auto-category-for-posts.php
Original file line number Diff line number Diff line change
Expand Up @@ -25,17 +25,6 @@
// set version of this plugin.
const AUTOCATEGORY_VERSION = '@@VersionNumber@@';

/**
* Initialize the plugin.
*
* @return void
* @noinspection PhpUnused
*/
function auto_category_init(): void {
load_plugin_textdomain( 'auto-category-for-posts', false, dirname( plugin_basename( __FILE__ ) ) . '/languages' );
}
add_action( 'init', 'auto_category_init' );

/**
* Check for necessary steps after plugin-updates.
*
Expand Down
2 changes: 1 addition & 1 deletion build/build.xml
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@
<delete file="${build.dir}/${plugin.slug}_${plugin.version}.zip"/>
<zip destfile="${build.dir}/${plugin.slug}_${plugin.version}.zip">
<zipfileset dir="${src.dir}/admin" prefix="${plugin.slug}/admin" />
<zipfileset dir="${src.dir}/languages" prefix="${plugin.slug}/languages" />
<zipfileset dir="${src.dir}/languages" includes="*.json" prefix="${plugin.slug}/languages" />
<zipfileset dir="${src.dir}" includes="uninstall.php,readme.txt" prefix="${plugin.slug}" />
<zipfileset dir="${src.dir}" includes="${plugin.slug}-release.php" fullpath="${plugin.slug}/${plugin.slug}.php" />
</zip>
Expand Down
Binary file modified languages/auto-category-for-posts-de_DE.mo
Binary file not shown.
14 changes: 7 additions & 7 deletions languages/auto-category-for-posts-de_DE.po
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ msgstr ""
"Project-Id-Version: Auto Category for Posts 1.0.2\n"
"Report-Msgid-Bugs-To: https://wordpress.org/support/plugin/auto-category-for-"
"posts\n"
"POT-Creation-Date: 2022-02-09T15:01:42+01:00\n"
"PO-Revision-Date: 2022-02-09 15:03+0100\n"
"POT-Creation-Date: 2023-10-21T16:20:48+02:00\n"
"PO-Revision-Date: 2023-10-21 16:21+0200\n"
"Last-Translator: Thomas Zwirner <info@thomaszwirner.de>\n"
"Language-Team: \n"
"Language: de\n"
Expand Down Expand Up @@ -37,22 +37,22 @@ msgstr "Thomas Zwirner"
msgid "https://www.thomaszwirner.de"
msgstr "https://www.thomaszwirner.de"

#: auto-category-for-posts.php:97 admin/js.js:24
#: auto-category-for-posts.php:92 admin/js.js:24
msgid "Set as default"
msgstr "Setze als Standard-Kategorie"

#: auto-category-for-posts.php:100 admin/js.js:26
#: auto-category-for-posts.php:95 admin/js.js:26
msgid "Default category"
msgstr "Standard-Kategorie"

#: auto-category-for-posts.php:153
#: auto-category-for-posts.php:151
msgid "Error on saving new settings for default category."
msgstr "Fehler beim Speichern der neuen Einstellungen zur Standard-Kategorie."

#: auto-category-for-posts.php:184
#: auto-category-for-posts.php:183
msgid "Given category does not exists."
msgstr "Die übergebene Kategorie existiert nicht."

#: auto-category-for-posts.php:188
#: auto-category-for-posts.php:186
msgid "No new category-id given."
msgstr "Keine Kategorie übergeben."
Binary file added languages/auto-category-for-posts-de_DE_formal.mo
Binary file not shown.
58 changes: 58 additions & 0 deletions languages/auto-category-for-posts-de_DE_formal.po
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
# Copyright (C) 2022 Thomas Zwirner
# This file is distributed under the GPL-2.0-or-later.
msgid ""
msgstr ""
"Project-Id-Version: Auto Category for Posts 1.0.2\n"
"Report-Msgid-Bugs-To: https://wordpress.org/support/plugin/auto-category-for-"
"posts\n"
"POT-Creation-Date: 2023-10-21T16:20:48+02:00\n"
"PO-Revision-Date: 2023-10-21 16:21+0200\n"
"Last-Translator: Thomas Zwirner <info@thomaszwirner.de>\n"
"Language-Team: \n"
"Language: de\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
"X-Generator: Poedit 3.0.1\n"
"X-Domain: auto-category-for-posts\n"

#. Plugin Name of the plugin
msgid "Auto Category for Posts"
msgstr "Automatische Kategorie für Beiträge"

#. Description of the plugin
msgid ""
"Automatically add a default-category to each new post before it is first "
"saved."
msgstr ""
"Setzt die Standard-Kategorie an neuen Beiträgen bereits bevor diese erstmals "
"gespeichert werden."

#. Author of the plugin
msgid "Thomas Zwirner"
msgstr "Thomas Zwirner"

#. Author URI of the plugin
msgid "https://www.thomaszwirner.de"
msgstr "https://www.thomaszwirner.de"

#: auto-category-for-posts.php:92 admin/js.js:24
msgid "Set as default"
msgstr "Setze als Standard-Kategorie"

#: auto-category-for-posts.php:95 admin/js.js:26
msgid "Default category"
msgstr "Standard-Kategorie"

#: auto-category-for-posts.php:151
msgid "Error on saving new settings for default category."
msgstr "Fehler beim Speichern der neuen Einstellungen zur Standard-Kategorie."

#: auto-category-for-posts.php:183
msgid "Given category does not exists."
msgstr "Die übergebene Kategorie existiert nicht."

#: auto-category-for-posts.php:186
msgid "No new category-id given."
msgstr "Keine Kategorie übergeben."
18 changes: 9 additions & 9 deletions languages/auto-category-for-posts.pot
Original file line number Diff line number Diff line change
@@ -1,17 +1,17 @@
# Copyright (C) 2022 Thomas Zwirner
# Copyright (C) 2023 Thomas Zwirner
# This file is distributed under the GPL-2.0-or-later.
msgid ""
msgstr ""
"Project-Id-Version: Auto Category for Posts 1.0.2\n"
"Project-Id-Version: Auto Category for Posts @@VersionNumber@@\n"
"Report-Msgid-Bugs-To: https://wordpress.org/support/plugin/auto-category-for-posts\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"POT-Creation-Date: 2022-02-09T15:01:42+01:00\n"
"POT-Creation-Date: 2023-10-21T16:20:48+02:00\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"X-Generator: WP-CLI 2.6.0\n"
"X-Generator: WP-CLI 2.8.1\n"
"X-Domain: auto-category-for-posts\n"

#. Plugin Name of the plugin
Expand All @@ -30,24 +30,24 @@ msgstr ""
msgid "https://www.thomaszwirner.de"
msgstr ""

#: auto-category-for-posts.php:97
#: auto-category-for-posts.php:92
#: admin/js.js:24
msgid "Set as default"
msgstr ""

#: auto-category-for-posts.php:100
#: auto-category-for-posts.php:95
#: admin/js.js:26
msgid "Default category"
msgstr ""

#: auto-category-for-posts.php:153
#: auto-category-for-posts.php:151
msgid "Error on saving new settings for default category."
msgstr ""

#: auto-category-for-posts.php:184
#: auto-category-for-posts.php:183
msgid "Given category does not exists."
msgstr ""

#: auto-category-for-posts.php:188
#: auto-category-for-posts.php:186
msgid "No new category-id given."
msgstr ""
2 changes: 1 addition & 1 deletion readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ I recommend to use [PoEdit](https://poedit.net/) to translate texts for this plu

Run in main directory:

`wp i18n make-pot . languages/auto-category-for-posts.pot`
`wp i18n make-pot . languages/auto-category-for-posts.pot --exclude=svn`

### update translation-file

Expand Down

0 comments on commit daf94a3

Please sign in to comment.