Skip to content

Instantly share code, notes, and snippets.

View martylouis's full-sized avatar

Marty Thierry martylouis

View GitHub Profile
@martylouis
martylouis / README.md
Last active March 10, 2025 17:18
MP3 Archive Script for WordPress

MP3 Archive Script for WordPress

A WP-CLI script to archive MP3 files from your WordPress media library, create a ZIP file of the archive, and generate detailed logs.

Overview

This script helps WordPress administrators manage large collections of MP3 files by:

  1. Finding all MP3 files in the WordPress media library
  2. Creating a dated archive in a dedicated uploads directory
@martylouis
martylouis / IllustratorKeyboardShortcuts--2024-12-09.kys
Created December 10, 2024 00:14
Custom Illustrator Keyboard Shortcuts
/Menus {
/~superScript2 {
/Context 0
/Modifiers 0
/Represent 0
/Key 0
}
/~subscript2 {
/Context 0
/Modifiers 0
@martylouis
martylouis / download-website-images.js
Created October 12, 2023 22:41
Save all images on a website locally
async function selectDirectory() {
try {
const handle = await window.showDirectoryPicker();
return handle;
} catch (error) {
console.error("Error:", error);
}
}
function downloadImages(url, saveDirectoryHandle) {

Keybase proof

I hereby claim:

  • I am martylouis on github.
  • I am martylouis (https://keybase.io/martylouis) on keybase.
  • I have a public key ASAixACLhUJyQtT6yb264L0-gshVMuxXIpLaKXtnxZV9Bgo

To claim this, I am signing this object:

@martylouis
martylouis / .gitattributes
Created November 3, 2014 20:07
Fix line endings - .gitattributes
# Set the default behavior, in case people don't have core.autocrlf set.
* text=auto
# Explicitly declare text files you want to always be normalized and converted
# to native line endings on checkout.
*.c text
*.h text
# Declare files that will always have CRLF line endings on checkout.
*.sln text eol=crlf
@martylouis
martylouis / .gitignore
Last active September 29, 2016 16:23
WP Engine .gitignore
node_modules
*.log
*.bak
*.swp
*~
.cvs
.DS_Store
.svn
Thumbs.db
@martylouis
martylouis / acf-config.php
Last active August 29, 2015 14:07
Advanced Custom Fields 5.0 Config
<?php
/**
* Advanced Custom Fields 5.0 Config
*/
$acf_path = 'acf.php';
require_once $acf_path;
@martylouis
martylouis / markdown-cheatsheet.md
Created August 7, 2014 19:46
Markdown Cheatsheet

Sample Markdown Cheat Sheet

This is a sample markdown file to help you write Markdown quickly :)

If you use the fabulous [Sublime Text 2/3 editor][ST] along with the [Markdown Preview plugin][MarkdownPreview], open your ST2 Palette with CMD+⇧+P then choose Markdown Preview in browser to see the result in your browser.

Text basics

this is italic and this is bold . another italic and another bold

@martylouis
martylouis / search-social-template.html
Created June 8, 2014 23:43
Search and Social Media Meta Tags Starter Template
<!doctype html>
<html>
<head>
<!-- SEO -->
<meta name="author" content="Nicholas Cerminara">
<meta name="description" content="Bootstrap 3 has a ton of features and helpers to speed up front-end development. Sometimes you need something and you end up writing your own custom CSS and JavaScript without even realizing that Bootstrap could have done it for you....">
<link rel="canonical" href="http://scotch.io/bar-talk/bootstrap-3-tips-and-tricks-you-might-not-know">
<!-- Social: Twitter -->
<!-- Heads up! You must visit the Twitter Validator and request approval after setting up your Meta tags. -->
@martylouis
martylouis / wp-tinyMCE4.php
Created April 23, 2014 22:29
A custom WordPress TinyMCE v4 configuration with styles (now called "Formats") drop down menu and submenus.
<?php
/**
* TinyMCE v4 Config
*
* A custom WordPress TinyMCE v4 configuration with styles (now called "Format") drop down menu with submenus.
*
* style_formats: http://www.tinymce.com/wiki.php/Configuration:style_formats
*
*/