Tools for Programmers - 2016


Atom
Alternatives - Sublime Text

iTerm2
brew cask install iterm2
Preferences > Profiles > General > Working Directory > Reuse previous seesion's directory

highlight errors and warnings
Preferences > Profiles > Advanced > Triggers > Edit
(?i:.*(conflict|fatal|error|warn).*) // Yellow on Black

Visual Studio Code: VSC
-- Auto complete for javascript
npm install tsd -g
tsd query -r -o -a install angular jquery

Auto Completion
Git Auto Completion
-- auto complete git commands, branche names, remote names etc
Maven Auto Completion
-- -DskipTests

Chrome
chrome://settings/cookies
chrome://about/
document.designMode='on'
- Enable copy & paste functions
Chrome Extensions
Quick Tabs
Sight
CheckChrome
Click to Remove Element
Postman
Grammarly Spell Checker & Grammar Checker
Octotree - Code tree for GitHub and GitLab

chrome flash is blocked on this website
Try setting chrome://flags/#prefer-html-over-flash as disable and restart Chrome.

JD-GUI - Java Decompiler
HomeBrew
brew update
brew upgrade $FORMULA

jq - command line json proccessor
jq ' .response.docs.[0].field | length ' solr-rsp.json
jq '.response.docs' solr-rsp.json
curl 'solr-query' | jq '.' > result.json collections_list = $(curl "http://host:port/solr/admin/collections?action=LIST&wt=json" | jq '.' curl "" | jq '.collections|join(" ")'')

Docker
docker run -d -p 80:80 --name webserver nginx
docker ps
docker exec -it container_id /bin/sh

docker kill/stop $(docker ps -q)
docker build --no-cache .
docker-compose build --no-cache mysql

Delete all containers
docker rm $(docker ps -a -q)
Delete all images
docker rmi $(docker images -q)

Redis
redis-server to start server
redis-cli
redis-cli shutdown
KEYS *
KEYS pattern

TTL key
TYPE key
FLUSHDB - Removes data from your connection's CURRENT database.

FLUSHALL - Removes data from ALL databases.
ZRANGE key start stop [WITHSCORES]

Kafka
Delete a topic in dev:
./bin/kafka-configs.sh --zookeeper localhost:2181 --alter --entity-type topics --entity-name $topic-name --add-config retention.ms=1000
-- wait for several minutes, and verify there is no data:
bin/kafka-console-consumer.sh --bootstrap-server localhost:9092 --topic $topic-name  --from-beginning


bin/kafka-configs.sh --zookeeper localhost:2181 --alter --entity-type topics --entity-name $topic-name --delete-config retention.ms

Commands
mysql.server stop
mysql.server start
SHOW CREATE TABLE tbl_name
DESCRIBE tbl_name

SourceTree
Postman

Markdown
List: +, *, -
Link:
[link text](link url "hover popup text")
```shell(java etc)
``` Java 
CFR 
- A decompiler that supports Java 8 language features, including lambda expressions and me
thod references.
JD-GUI

cygwi
jcmd: One JDK Command-Line Tool to Rule Them All
sudo -u tomcat jcmd pid Thread.print > thread.print
sudo -u tomcat jcmd pid GC.heap_dump heapdump.hprof

Thread dump Analyzer
http://fastthread.io/
https://spotify.github.io/threaddump-analyzer/

Heap dump Analyzer
Eclipse MAT

GC Log Analyzer
http://gceasy.io/
https://github.com/chewiebug/GCViewer

Misc
Blogspot
Search for multiple labels
search/label/LABEL1+LABEL2
/search/?q=label:LABEL1|label:LABEL2

Labels

adsense (5) Algorithm (69) Algorithm Series (35) Android (7) ANT (6) bat (8) Big Data (7) Blogger (14) Bugs (6) Cache (5) Chrome (19) Code Example (29) Code Quality (7) Coding Skills (5) Database (7) Debug (16) Design (5) Dev Tips (63) Eclipse (32) Git (5) Google (33) Guava (7) How to (9) Http Client (8) IDE (7) Interview (88) J2EE (13) J2SE (49) Java (186) JavaScript (27) JSON (7) Learning code (9) Lesson Learned (6) Linux (26) Lucene-Solr (112) Mac (10) Maven (8) Network (9) Nutch2 (18) Performance (9) PowerShell (11) Problem Solving (11) Programmer Skills (6) regex (5) Scala (6) Security (9) Soft Skills (38) Spring (22) System Design (11) Testing (7) Text Mining (14) Tips (17) Tools (24) Troubleshooting (29) UIMA (9) Web Development (19) Windows (21) xml (5)