(by @andrestaltz)
If you prefer to watch video tutorials with live-coding, then check out this series I recorded with the same contents as in this article: Egghead.io - Introduction to Reactive Programming.
(by @andrestaltz)
If you prefer to watch video tutorials with live-coding, then check out this series I recorded with the same contents as in this article: Egghead.io - Introduction to Reactive Programming.
<?php | |
// Begin FES integration | |
// add button to the post button listing | |
function fes_shipping_field_button( $title ) { | |
if ( version_compare( fes_plugin_version, '2.2', '>=' ) ) { | |
echo '<button class="fes-button button" data-name="edd_simple_shipping" data-type="action" title="' . $title . '">'. __( 'Shipping', 'edd-simple-shipping' ) . '</button>'; | |
} | |
} | |
add_action('fes_custom_post_button', 'fes_shipping_field_button'); |
#Simple Authentication with Bcrypt
This tutorial is for adding authentication to a vanilla Ruby on Rails app using Bcrypt and has_secure_password.
The steps below are based on Ryan Bates's approach from Railscast #250 Authentication from Scratch (revised).
You can see the final source code here: repo. I began with a stock rails app using rails new gif_vault
##Steps
<?php add_action('init', 'my_replace_image_urls' ); | |
function my_replace_image_urls() { | |
if ( defined('WP_SITEURL') && defined('LIVE_SITEURL') ) { | |
if ( WP_SITEURL != LIVE_SITEURL ){ | |
add_filter('wp_get_attachment_url', 'my_wp_get_attachment_url', 10, 2 ); | |
} | |
} | |
} | |
function my_wp_get_attachment_url( $url, $post_id) { |
NOTE: Easier way is the X86 way, described on https://www.genymotion.com/help/desktop/faq/#google-play-services | |
Download the following ZIPs: | |
ARM Translation Installer v1.1 (http://www.mirrorcreator.com/files/0ZIO8PME/Genymotion-ARM-Translation_v1.1.zip_links) | |
Download the correct GApps for your Android version: | |
Google Apps for Android 6.0 (https://www.androidfilehost.com/?fid=24052804347835438 - benzo-gapps-M-20151011-signed-chroma-r3.zip) | |
Google Apps for Android 5.1 (https://www.androidfilehost.com/?fid=96042739161891406 - gapps-L-4-21-15.zip) | |
Google Apps for Android 5.0 (https://www.androidfilehost.com/?fid=95784891001614559 - gapps-lp-20141109-signed.zip) |
#!/bin/bash | |
# | |
# Update to latest chromium nightly on linux | |
# Script requires root to properly set up the sandbox | |
# https://code.google.com/p/chromium/wiki/LinuxSUIDSandboxDevelopment | |
# | |
# I use it with a line like the following in my .bashrc: | |
# alias canary='CHROME_DEVEL_SANDBOX="/home/tif/bin/chrome-linux/chrome_sandbox" /home/tif/bin/chrome-linux/chrome-wrapper' | |
# | |
# ---------------------------------------------------------------------- |
close git-bash first
download bin-make.exe
put it in programs (x86)/Git/bin as 'make.exe'.
open git-bash $ cd to a temp or bullpen directory
try it:
#!/usr/bin/env bash | |
# MIT © Sindre Sorhus - sindresorhus.com | |
# git hook to run a command after `git pull` if a specified file was changed | |
# Run `chmod +x post-merge` to make it executable then put it into `.git/hooks/`. | |
changed_files="$(git diff-tree -r --name-only --no-commit-id ORIG_HEAD HEAD)" | |
check_run() { | |
echo "$changed_files" | grep --quiet "$1" && eval "$2" |