For example, you want to set 40% alpha transparence to #000000
(black color), you need to add 66
like this #66000000
.
#!/bin/bash | |
# REFERENCE: http://stackoverflow.com/a/1638397/1260526 | |
# Absolute path to this script, e.g. /home/user/bin/foo.sh | |
SCRIPT=$(readlink -f "$0") | |
# Absolute path this script is in, thus /home/user/bin | |
SCRIPTPATH=$(dirname "$SCRIPT") | |
echo $SCRIPTPATH |
# script insstalls qemu and vagrant, then uses vagrant to build a qemu- | |
# supported rpi kernel for dev. | |
# - tested with 2015-02-16-raspbian-wheezy.zip on OSX El Capitan | |
# Variables | |
IMAGE=http://downloads.raspberrypi.org/raspbian_latest | |
IMG_PATH="/vagrant/raspbian_latest.img" | |
PI_LINUX=https://github.com/raspberrypi/linux | |
PI_LINUX_BRANCH="rpi-4.2.y" | |
PI_TOOLS=https://github.com/raspberrypi/tools |
<?php | |
// public/cliserver.php (router script) | |
if (php_sapi_name() !== 'cli-server') { | |
die('this is only for the php development server'); | |
} | |
if (is_file($_SERVER['DOCUMENT_ROOT'].'/'.$_SERVER['SCRIPT_NAME'])) { | |
// probably a static file... | |
return false; |
public class MainActivity extends Activity | |
// ... any code | |
/** | |
* Clear focus on touch outside for all EditText inputs. | |
*/ | |
@Override | |
public boolean dispatchTouchEvent(MotionEvent event) { | |
if (event.getAction() == MotionEvent.ACTION_DOWN) { | |
View v = getCurrentFocus(); |
Prior to Android 7, the system had a single preferred locale, and fallback behavior was quite rudimentary. Starting with Android 7, the user can now specify a priority list of locales, and fallback behavior is improved.
However, in many cases it is still surprisingly difficult to make full use of locale fallback, and there are some hidden gotchas when trying to fully support both Android 7 and earlier versions.
Currently the Serverless framework only offers lifecycle events that are bound to commands and also are very coarse. Each core plugin only exposes the events that are defined by the framework. This is suboptimal for plugin authors as they want to hook special events within the deployment process.
The PR adds fine grained lifecycles to the AWS deployment process (see below for the current implementation process) and makes the package/deploy plugin implementation non-breaking.
Sort .gitmodules, also easily adaptable to sort files in blocks (e.g. 4 lines at a time, or arbitrary region at a time).
See also:
#!/usr/bin/env bash
#!/bin/bash | |
if ! which hxselect > /dev/null; then | |
echo You need hxselect and hxnormalize | |
echo Run this: sudo apt-get install html-xml-utils | |
exit 1 | |
fi | |
hxselect="hxselect -s \n -i" | |
hxnormalize="hxnormalize -l 10000000 -x " |
{ | |
"schemes" : | |
[ | |
{ | |
"background" : "#fafafa", | |
"black" : "#000000", | |
"blue" : "#3199e1", | |
"brightBlack" : "#686868", | |
"brightBlue" : "#399ee6", | |
"brightCyan" : "#4cbf99", |