Commands for controlling the Raspberry Pi 2 LEDs.
See rpi-leds for a node module that does this.
- OK (ACT) LED =
led0
- Power (PWR) LED =
led1
Allow access
<?php | |
/** | |
* Returns all img tags in a HTML string with the option to include img tag attributes | |
* | |
* @author Joshua Baker | |
* | |
* @example $post_images[0]->html = <img src="example.jpg"> | |
* $post_images[0]->attr->width = 500 | |
* |
#!/bin/bash | |
function jsonval { | |
temp=`echo $json | sed 's/\\\\\//\//g' | sed 's/[{}]//g' | awk -v k="text" '{n=split($0,a,","); for (i=1; i<=n; i++) print a[i]}' | sed 's/\"\:\"/\|/g' | sed 's/[\,]/ /g' | sed 's/\"//g' | grep -w $prop` | |
echo ${temp##*|} | |
} | |
json=`curl -s -X GET http://twitter.com/users/show/$1.json` | |
prop='profile_image_url' | |
picurl=`jsonval` |
<?php | |
/* | |
This code is used for get the keywords from the | |
Google HotTrens.U can use the grabtrends() to get | |
the curerent trends words. it return an array of keywords | |
u can change the $url to get coountry specific keywords | |
ex: $url = "<a class="linkclass" href="http://www.google.co.in/trends/hottrends">http://www.google.co.in/trends/hottrends</a>"; | |
gives the INDIAN keywords | |
*/ |
module.exports = function(grunt) { | |
grunt.initConfig({ | |
pkg: grunt.file.readJSON('package.json'), | |
sass: { | |
options: { | |
includePaths: ['bower_components/foundation/scss'] | |
}, | |
dist: { | |
options: { |
#!/usr/bin/env bash | |
# Generate RSA private key | |
openssl genrsa -out private_key.pem 1024 |
Commands for controlling the Raspberry Pi 2 LEDs.
See rpi-leds for a node module that does this.
led0
led1
Allow access
# Backup | |
docker exec CONTAINER /usr/bin/mysqldump -u root --password=root DATABASE > backup.sql | |
# Restore | |
cat backup.sql | docker exec -i CONTAINER /usr/bin/mysql -u root --password=root DATABASE | |
server { | |
listen 80; | |
root /usr/share/nginx/html/laravel/public; | |
index index.php index.html index.htm; | |
server_name laravel.dev; | |
location / { | |
try_files $uri $uri/ /index.php?$query_string; |
request = (opts) => { | |
return new Promise((resolve, reject) => { | |
let xhr = new XMLHttpRequest(); | |
let url = opts.url; | |
let params = opts.query_params; | |
if (params && typeof params === 'object') { | |
params = Object.keys(params).map(function(key) { | |
return encodeURIComponent(key).replace(/%20/g, '+') + | |
'=' + encodeURIComponent(params[key]).replace(/%20/g, '+'); | |
}).join('&'); |
First step: Install Android SDK
yaourt -S android-sdk android-sdk-platform-tools android-sdk-build-tools
ncurses5-compat-libs
. In order to avoid this problem you have to use this command: gpg --recv-keys F7E48EDB
. You can find clarification here.yaourt -S genymotion
virtual-box
and his modules, yaourt
will make for you but you need choos between ArchLinux host modules or DKMS host modules.su -
and then do echo -e "vboxdrv\nvboxnetflt\nvboxnetadp\nvboxpci" > /etc/modules-load.d/virtualbox.conf
sudo
, for us at least, doesn't work.sudo modprobe vboxdrv vboxnetadp vboxnetflt
sudo chmod -R 777 /opt/android-sdk