This file contains 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
sudo sh -c "ulimit -n 65535 && exec su $LOGNAME" |
This file contains 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
// if the gesture started from a link, open link in new tab | |
var linkURL = FireGestures.getLinkURL(FireGestures.sourceNode); | |
if (linkURL) { | |
gTabDeque.moveTabToSecondPlaceInDeque(gBrowser.loadOneTab(linkURL, {inBackground: true})); | |
return; | |
} | |
// else duplicate tab | |
gTabDeque.moveTabToSecondPlaceInDeque(gBrowser.loadOneTab(gBrowser.currentURI.spec, {inBackground: true})); |
This file contains 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
// if the gesture started from a link, open link in new tab | |
var linkURL = FireGestures.getLinkURL(FireGestures.sourceNode); | |
if (linkURL) { | |
gBrowser.loadOneTab(linkURL, {inBackground: true}); | |
return; | |
} | |
// else duplicate tab | |
gBrowser.loadOneTab(gBrowser.currentURI.spec, {inBackground: true}); |
This file contains 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
# -*- mode: ruby -*- | |
# vi: set ft=ruby : | |
Vagrant.configure("2") do |config| | |
# All Vagrant configuration is done here. The most common configuration | |
# options are documented and commented below. For a complete reference, | |
# please see the online documentation at vagrantup.com. | |
# Every Vagrant virtual environment requires a box to build off of. | |
config.vm.box = "precise" |
This file contains 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
# -*- mode: ruby -*- | |
# vi: set ft=ruby : | |
Vagrant.configure("2") do |config| | |
# All Vagrant configuration is done here. The most common configuration | |
# options are documented and commented below. For a complete reference, | |
# please see the online documentation at vagrantup.com. | |
# Every Vagrant virtual environment requires a box to build off of. | |
config.vm.box = "trusty" |
This file contains 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
(^[^#\?]+\.(jpg|jpeg|png)((#|\?).*)?$|^[^#\?]+(#|\?).+\.(jpg|jpeg|png)(&;#)?.*$) |
This file contains 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
install nfs-common | |
sudo mkdir --parents /mnt/nfs/nas | |
sudo vim /etc/fstab | |
192.168.1.2:/data/Documents /mnt/nfs/nas/Documents nfs auto,bg,noatime,nolock 0 0 | |
192.168.1.2:/data/Music /mnt/nfs/nas/Music nfs auto,bg,noatime,nolock 0 0 | |
192.168.1.2:/data/Pictures /mnt/nfs/nas/Pictures nfs auto,bg,noatime,nolock 0 0 | |
192.168.1.2:/data/Transmission /mnt/nfs/nas/Transmission nfs auto,bg,noatime,nolock 0 0 | |
192.168.1.2:/data/Videos /mnt/nfs/nas/Videos nfs auto,bg,noatime,nolock 0 0 |
This file contains 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 | |
root=http://ngm.nationalgeographic.com | |
path=ngm/photo-contest/2012/entries/wallpaper | |
type=(nature places people) | |
for kind in "${type[@]}" | |
do | |
for week in {1..13} | |
do |
This file contains 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
import org.apache.avro.generic.GenericRecord | |
import org.apache.avro.mapred.AvroKey | |
import org.apache.avro.mapreduce.AvroKeyInputFormat | |
import org.apache.hadoop.io.NullWritable | |
import org.apache.spark.SparkContext | |
private def readAvro(sparkContext: SparkContext, path: String) = { | |
sparkContext.newAPIHadoopFile[ | |
AvroKey[GenericRecord], | |
NullWritable, |
This file contains 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
redshift -l 59.29:18.01 -t 5800:4500 |
OlderNewer