Skip to content

Instantly share code, notes, and snippets.

@bbqtd
bbqtd / macos-tmux-256color.md
Last active June 14, 2024 17:47
Installing tmux-256color for macOS

Installing tmux-256color for macOS

  • macOS 10.15.5
  • tmux 3.1b

macOS has ncurses version 5.7 which does not ship the terminfo description for tmux. There're two ways that can help you to solve this problem.

The Fast Blazing Solution

Instead of tmux-256color, use screen-256color which comes with system. Place this command into ~/.tmux.conf or ~/.config/tmux/tmux.conf(for version 3.1 and later):

@giannisp
giannisp / gist:b53a76047b07751ed3ade3c1db1d2c51
Created November 18, 2016 05:50
Upgrade PostgreSQL 9.5.5 to 9.6.1 using Homebrew (macOS)
After automatically updating Postgres to 9.6.1 via Homebrew, the pg_ctl start command didn't work.
The error was something like "database files are incompatible with server".
Database files have to be updated before starting the server, here are the steps that had to be followed:
# need to have both 9.6.1 and latest 9.5.x installed, and keep 9.6.1 as default
brew unlink postgresql
brew install postgresql95
brew unlink postgresql95
brew link postgresql
@kevinschaich
kevinschaich / vocabulary.py
Created April 22, 2016 23:05
Reading Vocabulary Lists by Grade Level
# Source: http://www.hpcsd.org/district.cfm?subpage=29208
grade1 = "annoy attention calm comfortable consequences curious curve decide directions discover disappointed embarrassed enormous exhausted explore fair fascinating feast focus gigantic grumpy huge ignore instead investigate invite important jealous leader list lovely frustrated leader listen measuring miserable mumble negative nervous nibbled note notice observing opposite ordinary positive precious prefer problem protect proud question reminds repeat report rhyme respect rhyme searching special spotless squirm stomped suddenly suggestion surprise uncomfortable warning wonder worried"
grade2 = "Amaze Amusing Analyze Annoy Arranged Avoid Cause Classify Community Conclusion Connection Continue Cooperation Curious Cycle Data Describe Detail Diagram Difference Different Discover Drowsy Edit Effect Energy Enormous Escape Estimate Exercise Expect Famous Flock Friendly Frighten Frown Gasp Gather Gust Helpful Include Insist Investigate Label Leaned Living M
@engintekin
engintekin / CustomerIOAdapter.java
Created March 1, 2015 07:04
customer.io java adapter
public class CustomerIOAdapter
{
private static final String CUSTOMER_IO_SITE_ID = "site-id";
private static final String CUSTOMER_IO_API_KEY = "api-key";
public void sendEvent(String id, String eventName, Map<String, Object> map) throws IOException
{
HttpPost request = new HttpPost("/api/v1/customers/" + id + "/events");
@denji
denji / README.md
Last active April 26, 2024 18:09 — forked from istepanov/gist:3950977
Remove/Backup – settings & cli for macOS (OS X) – DataGrip, AppCode, CLion, Gogland, IntelliJ, PhpStorm, PyCharm, Rider, RubyMine, WebStorm
@kevin-smets
kevin-smets / iterm2-solarized.md
Last active June 29, 2024 03:40
iTerm2 + Oh My Zsh + Solarized color scheme + Source Code Pro Powerline + Font Awesome + [Powerlevel10k] - (macOS)

Default

Default

Powerlevel10k

Powerlevel10k

@engintekin
engintekin / Application.java
Created October 26, 2011 20:02
Gzip your response in Play framework
@With(Compress.class)
public class Application extends Controller {
public static void index() {
render();//response will be gzipped
}
}