Github will be the main account and bitbucket the secondary.
ssh-keygen -t rsa -C "github email"
Enter passphrase when prompted. If you see an option to save the passphrase in your keychain, do it for an easier life.
This is an example how to perform multi-select faceting in ElasticSearch. | |
Selecting multiple values from the same facet will result in an OR filter between each of the values: | |
(facet1.value1 OR facet1.value2) | |
Faceting on more than one facet will result in an AND filter between each facet: | |
(facet1.value1 OR facet1.value2) AND (facet2.value1) | |
I have chosen to update the counts for each facet the selected value DOES NOT belong to since we are performing an AND between each facet. I have included an example that shows how to keep the counts if you don't want to do this (filter0.sh). |
#!/bin/sh | |
curl -XDELETE localhost:9200/foo >/dev/null | |
curl -XPOST localhost:9200/foo/t -d' | |
{ | |
"clicks": 10, | |
"impressions": 1000, | |
"when": "2013-10-01" | |
} |
############## UPDATE UBUNTU ############## | |
sudo local-gen UTF-8 | |
sudo apt-get update | |
sudo apt-get upgrade | |
############## GIT ############## | |
$ sudo add-apt-repository ppa:git-core/ppa | |
$ sudo apt-get update |
############## Chrome ############## | |
sudo apt-get install libxss1 libappindicator1 libindicator7 | |
wget https://dl.google.com/linux/direct/google-chrome-stable_current_amd64.deb | |
sudo dpkg -i google-chrome-stable_current_amd64.deb | |
Remove | |
sudo apt-get remove google-chrome-stable | |
sudo apt-get purge google-chrome-stable | |
sudo apt-get autoremove |
Service | |
sudo status mongodb //tell status of mongodb start or stop | |
sudo service mongodb restart | stop | start | |
Config | |
#bind_ip = 127.0.0.1 //comment it which so anyone can connect using mongo client | |
//copy db from one host to another host or in host | |
db.copyDatabase('from_db', 'to_db', 'from_hostname', 'username', 'password'); |
curl -XDELETE http://domain:9200/index/type | |
http://domain/createmapping | |
http://domain/mongo2elastic/finder | |
################################################################################ | |
FINDER SEARCH API |
################################# ALIAS ############################ | |
To Make permanent add into | |
~/bashrc | |
To Make permanent global add into | |
/etc/bashrc | |
//create shortcuts | |
alias fit="cd /var/www/html/fit" | |
alias .="cd ../" |
Installtion of node and express | |
apt-get install libssl-dev | |
download node source code | |
wget http://nodejs.org/dist/v0.6.19/node-v0.6.19.tar.gz | |
tar -vxf node-v0.6.19.tar.gz | |
go inside source code dir after run configure and build source code and install | |
cd /node-v0.6.19 | |
1) ./configure | |
2) make | |
3) sudo make install |
// php upload function | |
Array | |
( | |
[file] => /tmp/phpRZl57f | |
[wait] => 1 | |
[lossy] => 1 | |
[s3_store] => Array | |
( |