- IdeaVim
- Lombok
- google-java-format
Base on MacOS X 10.5+
shortcuts | usage |
---|
import java.sql.ResultSet; | |
import java.sql.ResultSetMetaData; | |
import java.sql.SQLException; | |
public class ColorPrint { | |
public static final String ANSI_RESET = "\u001B[0m"; | |
public static final String ANSI_BLACK = "\u001B[30m"; | |
public static final String ANSI_RED = "\u001B[31m"; | |
public static final String ANSI_GREEN = "\u001B[32m"; | |
public static final String ANSI_YELLOW = "\u001B[33m"; |
unbind-key C-b | |
set -g prefix 'C-x' | |
bind-key 'C-x' send-prefix | |
set -g base-index 1 | |
# tmux attach - attach a session, if none exists, create one. | |
new-session -n $HOST | |
# Automatically set window title |
. ~/.bashrc |
#!/usr/bin/env python3 | |
''' | |
pip install pdfminer3k | |
''' | |
from pdfminer.pdfparser import PDFParser, PDFDocument | |
from pdfminer.pdfinterp import PDFTextExtractionNotAllowed | |
from pdfminer.layout import LAParams, LTTextContainer | |
from pdfminer.converter import PDFPageAggregator | |
from pdfminer.pdfinterp import PDFResourceManager, PDFPageInterpreter |
" vim-plug {{{ | |
call plug#begin() | |
Plug 'jiangmiao/auto-pairs' | |
call plug#end() | |
" }}} vim-plug | |
" Spaces & Tabs {{{ | |
set tabstop=4 " number of visual spaces per TAB | |
set softtabstop=4 " number of spaces in tab when editing | |
set shiftwidth=4 " number of spaces to use for autoindent |
#!/usr/bin/env expect | |
spawn some command ... | |
expect 'some string' | |
send 'sth...\n' | |
# Interaction (eg, for a shell) | |
interact |
#!/usr/bin/env bash | |
# namespace you want to create | |
NAMESPACE=<namespace> | |
# cluster configuration | |
CLUSTER_SERVER=https://<your-cluster-endpoint> | |
CLUSTER_NAME=<your-cluster-name> | |
# customize these names as needed |
(ns etaoin.dev-patch | |
(:require [etaoin.dev :refer [get-performance-logs]] | |
[clojure.string :as str])) | |
(defn- try-parse-int | |
[line] | |
(try (Integer/parseInt line) | |
(catch Exception _e | |
line))) |
;; Go to video. | |
;; Click the three dot menu below the video. | |
;; Click open transcript. | |
;; Click and drag to highlight the whole transcript. | |
;; Save to /tmp/a.txt | |
;; Run this with clj/babashka | |
(require '[clojure.string :as str]) | |
(->> (iterate (fn [[r lines]] |