- Install a user scripts extension for your browser:
- Chrome - Tampermonkey: http://goo.gl/1DcTD2
- Firefox - Greasemonkey: http://goo.gl/p62F05
- Safari & IE - You're out of luck. :(
- Install this user script: http://goo.gl/H3RKQA - ignore the "invalid header" error - it's because I'm using the RAW output from the gist, without using the revision (so that it stays current)
- ???
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| # Script to backup git repo to S3 | |
| # Set bucket, dir, password and account to use for the backup. I keep mine in local env vars | |
| # These are set by localrc which lives on an encrypted home directory and is executed by my bashrc | |
| bucket=$GITHUB_BACKUP_BUCKET | |
| dir=$GITHUB_BACKUP_DIR | |
| password=$GITHUB_BACKUP_PASSWORD | |
| account=$GITHUB_ACCOUNT |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var oa = document.createElement('a'); | |
| oa.href="";oa.type="application/octet-stream";oa.download="named"; | |
| document.body.append(oa); | |
| var imageList = document.getElementsByClassName('image-thumb-body'); | |
| /* Donwload Images */ | |
| for ( x in imageList ) { | |
| if (typeof imageList[x] == 'number') break; | |
| var o = imageList[x]; | |
| oa.href = o.src; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <!DOCTYPE html> | |
| <meta charset="utf-8"> | |
| <style> | |
| .state{ | |
| fill: none; | |
| stroke: #a9a9a9; | |
| stroke-width: 1; | |
| } | |
| .state:hover{ | |
| fill-opacity:0.5; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| function calculate_median($arr) { | |
| $count = count($arr); //total numbers in array | |
| $middleval = floor(($count-1)/2); // find the middle value, or the lowest middle value | |
| if($count % 2) { // odd number, middle is the median | |
| $median = $arr[$middleval]; | |
| } else { // even number, calculate avg of 2 medians | |
| $low = $arr[$middleval]; | |
| $high = $arr[$middleval+1]; | |
| $median = (($low+$high)/2); | |
| } |
Getting started:
Related tutorials:
- Install ms-sys - if it is not in your repositories, get it here. Or alternatively, make sure lilo is installed (but do not run the liloconfig step on your local box if e.g. Grub is installed there!)
- Check what device your USB media is assigned - here we will assume it is
/dev/sdb. Delete all partitions, create a new one taking up all the space, set type to NTFS (7), and remember to set it bootable:
# cfdisk /dev/sdb
or fdisk /dev/sdb (partition type 7, and bootable flag)
Source: StackOverflow
With a Linux Guest run this:
sudo dd if=/dev/zero | pv | sudo dd of=/bigemptyfile bs=4096k
sudo rm -rf /bigemptyfile
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| /** | |
| Trasliterate method takes 5 , seaparated english words and transliterates them into Kannada, | |
| The result is an array of words in the same order. This uses Non public Google online transliteration API for this. | |
| When you run this method give a 10ms seconds gap between each call to be on the safer side. | |
| By : Thejesh GN http://thejeshgn.com | |
| More: http://thejeshgn.com/2011/02/04/batch-transliterating-names-into-kannada-using-google-api/ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/php -q | |
| <?php | |
| date_default_timezone_set('UCT'); | |
| $dryrun = FALSE; | |
| $interval = '24 hours'; | |
| $keep_for = '10 Days'; | |
| $volumes = array('vol-********'); | |
| $api_key = 'AKIAIXXXXXXXXXXXXXXX'; | |
| $api_secret = 'IzMni.........................emQKct'; |
NewerOlder