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
# ubuntu | |
/etc/postgresql/9.1/main | |
# centos | |
/var/lib/pgsql/9.x/data | |
postgresql.conf | |
listen_addresses = '*' | |
pg_hba.conf | |
host all all 0.0.0.0/0 md5 |
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
# INSTALL FROM BINARIES | |
wget https://nodejs.org/dist/v0.12.7/node-v0.12.7-linux-x64.tar.gz | |
sudo tar --strip-components 1 -xzvf node-v* -C /usr/local | |
# EPEL RELEASE | |
sudo yum install epel-release | |
sudo yum install nodejs | |
# COMPILE | |
wget https://nodejs.org/dist/v0.12.7/node-v0.12.7.tar.gz |
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
yum install http://yum.postgresql.org/9.4/redhat/rhel-6-x86_64/pgdg-redhat94-9.4-1.noarch.rpm | |
yum install postgresql94-server postgresql94-contrib postgresql-devel | |
service postgresql-9.4 initdb | |
chkconfig postgresql-9.4 on | |
# MANAGE | |
service postgresql-9.4 start | |
service postgresql-9.4 stop | |
service postgresql-9.4 restart |
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
HTTPS | |
git clone https://[email protected]/username/repo.git | |
insert password | |
GIT | |
register ssh key | |
git clone [email protected]:username/repo.git |
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
spring stop | |
bin/spring | |
rails c |
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
#install rvm, ruby | |
... | |
# install rails | |
gem install rails | |
# create project_folder, goto into folder | |
rails new . --database=postgresql | |
# edit database.yml filling username, passowrd, host, port |
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
The Role of Deliberate Practice in the Acquisition of Expert Performance | |
by James Somers, February 9, 2010 | |
I have just finished reading a famous paper by Ericsson, Krample, and Tesch-Romer called “The Role of Deliberate Practice in the Acquisition of Expert Performance” (1993, Psychological Review). | |
The paper’s key claim is that performance—be it in chess, or swimming, or violin—is a monotonic function of accumulated deliberate practice. More deliberate practice equals better performance. | |
So what is “deliberate” practice, and how is it different from the regular kind? | |
The most cited condition concerns the subjects’ motivation to attend to the task and exert effort to improve their performance. In addition, the design of the task should take into account the preexisting knowledge of the learners so that the task can be correctly understood after a brief period of instruction. The subjects should receive immediate informative feedback and knowledge of results of their performance. The subjects should repeat |
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
echo fs.inotify.max_user_watches=524288 | sudo tee -a /etc/sysctl.conf && sudo sysctl -p |
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
message = MyMailer.new_products(c, products) | |
customers.each do |c| | |
mail = message.dupe() | |
mail.to = c.email | |
mail.deliver | |
end |
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
File.open(file_path, 'r') do |f| | |
send_data f.read, type: "text/excel" | |
end | |
File.delete(file_path) |