Skip to content

Instantly share code, notes, and snippets.

View ExponentiallyDigital's full-sized avatar

Andrew Newbury ExponentiallyDigital

View GitHub Profile
@LuisEGR
LuisEGR / install_rsync.ps1
Created May 6, 2024 06:10
Install rsync in Windows 11, easy
# Download and install Git for Windows if not already installed
if (-not (Test-Path "C:\Program Files\Git\bin\git.exe")) {
Write-Host "Git for Windows not found. Downloading installer..."
Invoke-WebRequest -Uri "https://github.com/git-for-windows/git/releases/download/v2.31.1.windows.1/Git-2.31.1-64-bit.exe" -OutFile "git-installer.exe"
Write-Host "Installing Git for Windows..."
Start-Process -FilePath ".\git-installer.exe" -ArgumentList "/VERYSILENT" -Wait
Remove-Item ".\git-installer.exe"
}
# Create a temporary directory for downloads
@EricBusch
EricBusch / add-webp-to-wordpress.php
Created October 6, 2017 18:03
This adds support for webp when importing webp images into WordPress. [datafeedr]
<?php
/**
* Add support for webp to WordPress.
*
* @param array $mime_types
*
* @return array Updated $mime_types array.
*/
add_filter( 'mime_types', 'mycode_mime_types', 20 );