- Install fish via Brew
- Optionally install Oh My Fish!
- Add fish to known shells
- Set default shell to fish
brew install fish
curl -L https://get.oh-my.fish | fish
# Put this in your ~/.gitconfig or ~/.config/git/config | |
# Windows users: "~" is your profile's home directory, e.g. C:\Users\<YourName> | |
[user] | |
name = Your Full Name | |
email = your@email.tld | |
[color] | |
# Enable colors in color-supporting terminals | |
ui = auto | |
[alias] | |
# List available aliases |
#!/usr/bin/env python | |
""" | |
===================================== | |
PEP 20 (The Zen of Python) by example | |
===================================== | |
Usage: %prog | |
:Author: Hunter Blanks, hblanks@artifex.org / hblanks@monetate.com |
-- show running queries (pre 9.2) | |
SELECT procpid, age(clock_timestamp(), query_start), usename, current_query | |
FROM pg_stat_activity | |
WHERE current_query != '<IDLE>' AND current_query NOT ILIKE '%pg_stat_activity%' | |
ORDER BY query_start desc; | |
-- show running queries (9.2) | |
SELECT pid, age(clock_timestamp(), query_start), usename, query | |
FROM pg_stat_activity | |
WHERE query != '<IDLE>' AND query NOT ILIKE '%pg_stat_activity%' |
brew install fish
curl -L https://get.oh-my.fish | fish
curl -XPOST http://localhost:9200/test/articles/1 -d '{ | |
"content": "The quick brown fox" | |
}' | |
curl -XPOST http://localhost:9200/test/articles/2 -d '{ | |
"content": "What does the fox say?" | |
}' | |
curl -XPOST http://localhost:9200/test/articles/3 -d '{ | |
"content": "The quick brown fox jumped over the lazy dog" | |
}' | |
curl -XPOST http://localhost:9200/test/articles/4 -d '{ |
// | |
// SBT task for slick code generation for a live database | |
// ====================================================== | |
// | |
// This sbt task will generate slick scala classes to match your (MySQL) database schema, | |
// which will allow you to use the database through slick, in your scala application. | |
// | |
// Usage: Review all ? symbols and comments below, to adapt to your system. Embed in build.sbt. | |
// Make sure the database is up. Run: sbt slickGenerate | |
// In your scala application, import the resulting scala file |
Free O'Reilly books and convenient script to just download them.
Thanks /u/FallenAege/ and /u/ShPavel/ from this Reddit post
How to use:
download.sh
file and put it into a directory where you want the files to be saved.cd
into the directory and make sure that it has executable permissions (chmod +x download.sh
should do it)./download.sh
and wee there it goes. Also if you do not want all the files, just simply comment the ones you do not want.package services | |
import java.security.Security | |
import org.slf4j.LoggerFactory | |
object DnsCache { | |
private val logger = LoggerFactory.getLogger("DnsCache") |
{ | |
"fantasy-name": "Restaurant fantasy name", | |
"company name": "Restaurant company name", | |
"logo": "Restaurant logo", | |
"CNPJ": "Restaurant CNPJ", | |
"phone": "Restaurant phone", | |
"telephone": "Restaurant telephone", | |
"website": "Restaurant website", | |
"category": [ | |
"Fast Food", |
#!/bin/bash | |
echo "removing evaluation key" | |
rm ~/.IntelliJIdea2017.3/config/eval/idea173.evaluation.key | |
echo "resetting evalsprt in options.xml" | |
sed -i '/evlsprt/d' ~/.IntelliJIdea2017.3/config/options/options.xml | |
echo "resetting evalsprt in prefs.xml" | |
sed -i '/evlsprt/d' ~/.java/.userPrefs/prefs.xml |