The most effective way to remove a git submodule (source):
git submodule deinit <path_to_submodule>
git rm <path_to_submodule>
git commit -m "Removed submodule "
rm -rf .git/modules/<path_to_submodule>| <?php | |
| /** | |
| * Remove script versions from frontend static scripts. | |
| * Place this code in your child theme's functions.php OR use the plugin below. | |
| */ | |
| add_filter( 'style_loader_src', 'myprefix_remove_script_versions', 9999 ); | |
| add_filter( 'script_loader_src', 'myprefix_remove_script_versions', 9999 ); | |
| function myprefix_remove_script_versions( $src ) { |
| /** | |
| * jQuery function to replace one or more CSS classes with others. Separate multiple | |
| * classes with spaces. | |
| * @param {string} remove - CSS classes to remove. | |
| * @param {string} add - CSS classes to add. | |
| * @example | |
| * $( '.selector' ).replaceClass( 'old-class', 'new-class some-other-class' ); | |
| * $( '.selector' ).replaceClass( 'old-class another-class', 'new-class' ); | |
| */ | |
| !function(s){s.fn.replaceClass=function(remove,add){var e=add||remove;return e&&this.removeClass(add?remove:this.className).addClass(e),this}}(jQuery); |
| <?php | |
| /** | |
| * Add the following to your child theme's functions.php file to remove | |
| * automatically tick the "Remember Me" checkbox at WordPress login. | |
| */ | |
| add_action( 'init', function() { | |
| add_filter( 'login_footer', function() { | |
| echo "<script>document.getElementById('rememberme').checked = true;</script>"; | |
| }); | |
| }); |
| <?php | |
| /** | |
| * Add the following to your child theme's functions.php file to remove | |
| * the "Try Gutenberg" callout introduced in WordPress 4.9.8 | |
| */ | |
| remove_filter( 'try_gutenberg_panel', 'wp_try_gutenberg_panel' ); |
| # Boilerplate .gitignore for WPMU Dev Hosting. Copy this to .gitignore in your web root. | |
| # Forked from: https://wpengine.com/wp-content/uploads/2013/10/recommended-gitignore-no-wp.txt | |
| # Maintainer: Daniel M. Hendricks (https://daniel.hn) | |
| # Version: 1.0.4 | |
| *~ | |
| .DS_Store | |
| .env | |
| .svn | |
| .cvs | |
| *.bak |
| <?php | |
| /* Add this to your child theme's functions.php to remove the generator meta tag from both | |
| * your web sites page head and from your RSS feeds (ex: /feed/) | |
| */ | |
| // Remove generator meta tag from page head | |
| remove_action( 'wp_head', 'wp_generator' ); | |
| // Remove generator tag from RSS feeds | |
| add_filter( 'the_generator', '__return_null' ); |
| /** | |
| * Because searching for a simple example of how to Base64 encode/decode in Java | |
| * that hasn't been deprecated since the Crimean War is an exercise in madness... | |
| * | |
| * Requires Java 8 or higher | |
| */ | |
| package hn.daniel; | |
| import java.util.Base64; |
The most effective way to remove a git submodule (source):
git submodule deinit <path_to_submodule>
git rm <path_to_submodule>
git commit -m "Removed submodule "
rm -rf .git/modules/<path_to_submodule>