// Command Prompts
WP-CLI
Site tree 4 folders deep
tree -L 4 -I "node_modules|gsap"
Update all Dist %2
scp -P 21098 "/home/mnrdjmke/public_html/wp-content/themes/swagdrip/dist/"* \
mnrdjmke@198.54.125.196:/home/mnrdjmke/public_html/wp-content/themes/swagdrip/dist/
Update Two Files
scp -P 21098 "/home/mnrdjmke/public_html/wp-content/themes/swagdrip/dist/main.min.css" \
"/home/mnrdjmke/public_html/wp-content/themes/swagdrip/dist/main.min.css.map" \
mnrdjmke@198.54.125.196:/home/mnrdjmke/public_html/wp-content/themes/swagdrip/dist/
List Users & Id’s
wp user list --fields=ID,user_login,display_name,email
Make a Dir W/files
mkdir -p includes && touch includes/{setup,custom-posts,batch-payments,helpers}.php functions.php
blank
blank
rm directory
rm -rf /path/to/directory
install woocommerce
wp plugin install woocommerce --version=8.8.3 --force
wget woo
wget https://downloads.wordpress.org/plugin/woocommerce.9.6.1.zip
My New Snippet
No content available.
My New Snippet
No content available.
My New Snippet 1
No content available.
Create 10 Snippets
for i in {1..10}; do
TITLE="My New Snippet $i"
NEW_ID=$(wp post create --post_type=snippet --post_title="$TITLE" --post_status=publish --porcelain)
wp post term set "$NEW_ID" snippet_category wp-cli
echo "Post $NEW_ID created with category 'wp-cli'."
done
10 Posts w/Titles&Categories
CATEGORIES=("wp-cli" "circuitpython" "database-sql" "prompts" "zmk" )
# Loop through numbers 1 to 10
for i in {1..10}; do
TITLE="My New Snippet $i"
CATEGORY=${CATEGORIES[$((i-1))]}
NEW_ID=$(wp post create --post_type=snippet --post_title="$TITLE" --post_status=publish --porcelain)
wp post term set "$NEW_ID" snippet_category "$CATEGORY"
echo "Post $NEW_ID created with category '$CATEGORY'."
done
10 Identical (Title and Category)
for i in {1..10}; do
TITLE="My New Snippet"
NEW_ID=$(wp post create --post_type=snippet --post_title="$TITLE" --post_status=publish --porcelain)
wp post term set "$NEW_ID" snippet_category wp-cli
echo "Post $NEW_ID created with category 'wp-cli'."
done
Assign category to snippet
for POST_ID in 290 288 287 283; do
wp post term set "$POST_ID" snippet_category wp-cli
echo "Assigned 'wp-cli' category to post ID $POST_ID."
done
Category to Snippet
No content available.wp post term set 290 snippet_category wp-cli
wp post term set 288 snippet_category wp-cli
wp post term set 287 snippet_category wp-cli
wp post term set 283 snippet_category wp-cli
My New Snippet 5
wp post create --post_type=snippet --post_title="My Snippet Title" --post_content="This is the content of my snippet." --post_status=publish --porcelain | xargs -I % wp post term set % snippet_category wp-cli
My New Snippet 4
No content available.
My New Snippet 3
No content available.
Verify Taxonomy Registration
wp taxonomy list --fields=name,object_type,public --format=table
list snippets without category terms
wp eval '
$args = [
"post_type" => "snippet",
"posts_per_page" => -1,
"tax_query" => [
[
"taxonomy" => "snippet_category",
"operator" => "NOT EXISTS",
],
],
];
$posts = get_posts($args);
if (empty($posts)) {
echo "No snippet posts without a category found.\n";
} else {
$ids = wp_list_pluck($posts, "ID");
echo implode(" ", $ids) . "\n";
}'
Delete List
wp post delete 291 280 279 278 277 276 260 259 256 255 251 250 248 247 246 245 244 243 241 240 239 238 237 236 234 233 --force --yes
to local site
cd /Users/mnrdsgn/Local\ Sites/mnrdsgn2025/app/public/wp-content/themes/swagdrip
move to root
cd /Users/mnrdsgn/Local\ Sites/mnrdsgn2025/app/public
open local shell
wp search-replace 'https://mnrdsgn.com' 'https://mnrdsgn.com' --export=live.sql
ssh to live
ssh -p 21098 mnrdjmke@198.54.125.196
Live root
cd public_html
Move SQL to Live
scp -P 21098 local-db.sql mnrdjmke@198.54.125.196:/home/mnrdjmke/public_html/
Import DB to Live
wp db import live.sql
Set Live URL’s
wp option update siteurl "https://mnrdsgn.com"
wp option update home "https://mnrdsgn.com"
Rewrite Flush
wp rewrite flush
Flush Cache
wp cache flush
CircuitPython
My New Snippet 2
No content available.
My New Snippet 4
No content available.
My New Snippet2
No content available.
My New Snippet
No content available.
No tax
No content available.
CircuitPython Serial Print
cd /Users/mnrdsgn/Local\ Sites/mnrdsgn2025/app/public/wp-content/themes/swagdrip
CircuitPython Read Sensor
git add .
git commit -m
git push origin main
CircuitPython Blinky
cd public_html/wp-content/themes
zmk
My New Snippet 5
No content available.
ZMK RGB Settings
git clone https://github.com/eboy79/swagdrip.git
ZMK Layer Switching
wp theme activate swagdrip
ZMK Keymap Config
wp cache flush
database-sql
My New Snippet 3
No content available.
Export Database
wp db export backup.sql
Prompts
My New Snippet 4
No content available.
Prompt for Future Posts
"Convert our debugging journey for the WordPress Snippets Page into a structured blog post. Use a concise intro (three-sentence excerpt). Format the title as , major sections as , and subsections as . Display code snippets in blocks, ensuring readability. At the end, include a section on lessons learned, debugging commands, and a 5-minute guide for setting this up again. Save the post as a .txt file formatted with HTML tags, and provide a direct download link."