From adfb053040d71a2228670578bf68444b4281f388 Mon Sep 17 00:00:00 2001 From: Marcel Bootsman Date: Mon, 11 Nov 2024 13:43:29 +0100 Subject: [PATCH 1/2] Added primary branch tag in plugin header Added override to prevent w.org updates --- auto-hide-admin-bar.php | 27 +++++++++++++++++++++------ 1 file changed, 21 insertions(+), 6 deletions(-) diff --git a/auto-hide-admin-bar.php b/auto-hide-admin-bar.php index 03fba52..96c4c0f 100755 --- a/auto-hide-admin-bar.php +++ b/auto-hide-admin-bar.php @@ -6,6 +6,7 @@ Version: 1.6.5 Author URI: https://marcelbootsman.nl Github Plugin URI: https://github.com/mbootsman/auto-hide-admin-bar +Primary Branch: main Text Domain: auto-hide-admin-bar Domain Path: /languages/ @@ -306,14 +307,28 @@ function auto_hide_admin_bar_load_textdomain() { * @param */ -add_filter( 'load_textdomain_mofile', 'auto_hide_admin_bar_load_language_files', 10, 2 ); -function auto_hide_admin_bar_load_language_files( $mofile, $domain ) { - if ( 'auto-hide-admin-bar' === $domain && false !== strpos( $mofile, WP_LANG_DIR . '/plugins/' ) ) { - $locale = apply_filters( 'plugin_locale', determine_locale(), $domain ); - $mofile = WP_PLUGIN_DIR . '/' . dirname( plugin_basename( __FILE__ ) ) . '/languages/' . $domain . '-' . $locale . '.mo'; +add_filter('load_textdomain_mofile', 'auto_hide_admin_bar_load_language_files', 10, 2); +function auto_hide_admin_bar_load_language_files($mofile, $domain) { + if ('auto-hide-admin-bar' === $domain && false !== strpos($mofile, WP_LANG_DIR . '/plugins/')) { + $locale = apply_filters('plugin_locale', determine_locale(), $domain); + $mofile = WP_PLUGIN_DIR . '/' . dirname(plugin_basename(__FILE__)) . '/languages/' . $domain . '-' . $locale . '.mo'; echo $mofile; } return $mofile; } -?> \ No newline at end of file +/** + * Override w.org updates for Git-updater. Arrr. + */ + +add_filter( + 'gu_override_dot_org', + function ($overrides) { + return array_merge( + $overrides, + array( + 'auto-hide-admin-bar/auto-hide-admin-bar.php', // plugin format + ) + ); + } +); From dc9dfeb13cd3777b0caa1ae6728ebfc864c56d1e Mon Sep 17 00:00:00 2001 From: Marcel Bootsman Date: Mon, 11 Nov 2024 14:37:04 +0100 Subject: [PATCH 2/2] Upped version to 1.6.6 --- auto-hide-admin-bar.php | 2 +- readme.txt | 6 +++++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/auto-hide-admin-bar.php b/auto-hide-admin-bar.php index 96c4c0f..bc0c169 100755 --- a/auto-hide-admin-bar.php +++ b/auto-hide-admin-bar.php @@ -3,7 +3,7 @@ Plugin Name: Auto Hide Admin Bar Description: Automatically hides the Toolbar. Will show the Toolbar when hovering over the top of the site. Author: Marcel Bootsman -Version: 1.6.5 +Version: 1.6.6 Author URI: https://marcelbootsman.nl Github Plugin URI: https://github.com/mbootsman/auto-hide-admin-bar Primary Branch: main diff --git a/readme.txt b/readme.txt index 143ffc9..df907d7 100755 --- a/readme.txt +++ b/readme.txt @@ -3,7 +3,7 @@ Contributors: mbootsman Tags: admin bar, autohide, hide, toolbar Requires at least: 3.1 Tested up to: 6.6.2 -Stable tag: 1.6.5 +Stable tag: 1.6.6 This plugin adds an auto-hide feature to the WordPress Admin Bar or Toolbar. @@ -28,6 +28,10 @@ Sure, just go [here](https://translate.wordpress.org/projects/wp-plugins/auto-hi How do we make screenshots of things that are hidden? :) == Changelog == += 1.6.6 = +* Added primary branch tag in plugin header +* Added override to prevent w.org updates + = 1.6.5 = * Added language files (Dutch, Chinese (Taiwan))