See how a minor change to your commit message style can make you a better programmer.
Format: <type>(<scope>): <subject>
<scope>
is optional
version: '3' | |
networks: | |
mynetwork: | |
ipam: | |
config: | |
- subnet: 172.20.0.0/24 | |
services: | |
nodered1: | |
image: nodered/node-red-docker | |
ports: |
#!/bin/sh | |
movefrom='micronssd' | |
moveto='wdredpro' | |
for vm in $(qm list | awk '{print $1}' | grep -Eo '[0-9]{1,3}'); | |
do | |
for storage in $(qm config $vm | grep $movefrom: | awk '{print $1}' | grep -Eo '[a-z0-9]+'); | |
do | |
echo Moving VM$vm Storage $storage |
add_action( 'init', function(){ | |
if ( ! is_admin()) { | |
if( is_ssl() ){ | |
$protocol = 'https'; | |
}else { | |
$protocol = 'http'; | |
} | |
/** @var WP_Scripts $wp_scripts */ | |
global $wp_scripts; |
#!/bin/sh | |
# This script based on linux-vm-tools for Ubuntu 22.02. | |
# Thanks to https://github.com/Hinara/linux-vm-tools/ to script | |
# This script is for Ubuntu 22.04 Jammy Jellyfish to download and install XRDP+XORGXRDP via | |
# source. | |
# | |
# Major thanks to: http://c-nergy.be/blog/?p=11336 for the tips. | |
# |
<?php | |
/** | |
* Link the FR translation and the EN translation | |
* Called by API https://domain.com/wp-json/link_translation/post/ | |
*/ | |
function custom_rest_link_translation($data) { | |
//Source https://wpml.org/wpml-hook/wpml_set_element_language_details/ |
<?php | |
global $wp_query; | |
echo "<pre>"; | |
var_dump($wp_query->query_vars); | |
var_dump($wp_query); | |
echo "</pre>"; | |
?> |
<?php | |
/** | |
* Automatically login a single WordPress user upon arrival to a specific page. | |
* | |
* Redirect to home page once logged in and prevent viewing of the login page. | |
* Compatible with WordPress 3.9.1+ | |
* Updated 2014-07-18 to resolve WP_DEBUG notice: "get_userdatabylogin is deprecated since version 3.3! Use get_user_by('login') instead." | |
* Updated 2019-07-09 to reformat code, pass 2nd parameter to `do_action()`, and hook into priority 1. | |
* |
#!/bin/bash | |
for bucket in $(radosgw-admin bucket list | jq -r .[]); do | |
bucket_id=$(radosgw-admin metadata get bucket:${bucket} | jq -r .data.bucket.bucket_id) | |
marker=$(radosgw-admin metadata get bucket:${bucket} | jq -r .data.bucket.marker) | |
for instance in $(radosgw-admin metadata list bucket.instance | jq -r .[] | grep "^${bucket}:" | grep -v ${bucket_id} | grep -v ${marker}| cut -f2 -d':'); do | |
echo "${bucket}: ${instance}" | |
radosgw-admin bi purge --bucket=${bucket} --bucket-id=${instance} | |
radosgw-admin metadata rm bucket.instance:${bucket}:${instance} | |
done |
- name: 'good first issue' | |
color: '5319e7' | |
description: 'Good for newcomers' | |
aliases: [] | |
- name: 'help wanted' | |
color: '008672' | |
description: 'Extra attention is needed' | |
aliases: [] |