Skip to content

Instantly share code, notes, and snippets.

@BrookeDot
BrookeDot / Readme.md
Last active July 28, 2021 06:17
MACROPAD Hotkeys with Consumer Key Support
@BrookeDot
BrookeDot / gist:151aee9fcb7eed370b007b8575246116
Created August 20, 2024 21:01
MSM Sitemap customization
<?php
function vip_customize_msm_sitemap_entry( $url ) {
if ( $url instanceof SimpleXMLElement ) {
// Add images to the sitemap entry.
$post_id = get_the_ID();
$thumbnail_id = get_post_thumbnail_id( $post_id );
if ( $thumbnail_id ) {
/**
* Remove Jetpack's sitemap feature so MSM sitemaps can take control.
* Unless we are trying to access the news sitemap, in which case we use JP.
*/
add_action( 'init', function() {
if ( ! class_exists( 'Jetpack_Sitemap_Manager' ) ) {
return;
}
$raw_uri = isset( $_SERVER['REQUEST_URI'] ) ? sanitize_text_field( wp_unslash( $_SERVER['REQUEST_URI'] ) ) : '';
if ( false === strpos( $raw_uri, '/news-sitemap.xml' ) && false === strpos( $raw_uri, '/news-sitemap.xsl' ) ) {
@BrookeDot
BrookeDot / biker.sql
Created October 16, 2025 23:05
Bike[R] database structure
DROP TABLE IF EXISTS `rwg_career_totals`;
CREATE TABLE `rwg_career_totals` (
`id` bigint(20) UNSIGNED NOT NULL,
`date` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(),
`trips` int(10) UNSIGNED NOT NULL,
`moving_time` int(11) UNSIGNED NOT NULL,
`elevation_gain` decimal(22,12) UNSIGNED NOT NULL,
`distance` decimal(22,12) UNSIGNED NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

Remove all follows on twitter.com

Originally By @foldleft.bsky.social, see also Unfollow everyone on bsky.app.

Go to https://twitter.com/YOUR_USER_NAME/following
Open the Developer Console. (COMMAND+ALT+I on Mac)
Paste this into the Developer Console and run it