Skip to content

Instantly share code, notes, and snippets.

@rrmartins
rrmartins / elasticsearch-setup-apple-macbook-pro-m1.md
Created July 5, 2024 10:49 — forked from todgru/elasticsearch-setup-apple-macbook-pro-m1.md
Install Elasticsearch 7.x on Apple Macbook Pro M1 Ventura 13.2

Elasticsearch Setup Apple MacBook Pro M1

Apple MacBook Pro M1, 32 GB, Ventura 13.2

Documentation based on comments in this Github Elasticsearch issue.

Install Homebrew

version: '3.2'
services:
db:
image: postgres:latest
environment:
- POSTGRES_PASSWORD=password
ports:
- "5432:5432"
volumes:
- "dbdata:/var/lib/postgresql/data"
@rrmartins
rrmartins / rubyonrails.yml
Created June 30, 2024 16:51
with elasticsearch
name: "Ruby on Rails CI"
on: pull_request
env:
RAILS_ENV: test
DATABASE_URL: "postgres://rails:password@localhost:5432/rails_test"
jobs:
build:
runs-on: ubuntu-latest
# Ring the bell if any background window rang a bell
set -g bell-action any
# Default termtype. If the rcfile sets $TERM, that overrides this value.
set -g default-terminal screen-256color
# Keep your finger on ctrl, or don't
bind-key ^D detach-client
# Create splits and vertical splits
@rrmartins
rrmartins / tmux-cheatsheet.markdown
Created June 26, 2021 13:15 — forked from MohamedAlaa/tmux-cheatsheet.markdown
tmux shortcuts & cheatsheet

tmux shortcuts & cheatsheet

start new:

tmux

start new with session name:

tmux new -s myname
Process: ruby [15679]
Path: /Users/USER/*/ruby
Identifier: ruby
Version: 0
Code Type: ARM-64 (Native)
Parent Process: zsh [8634]
Responsible: iTerm2 [543]
User ID: 502
Date/Time: 2021-02-08 13:38:54.767 +0000
call plug#begin()
Plug 'terryma/vim-multiple-cursors'
Plug 'sheerun/vim-polyglot'
Plug 'junegunn/fzf', { 'dir': '~/.fzf', 'do': './install --all' }
Plug 'junegunn/fzf.vim'
Plug 'Numkil/ag.nvim'
Plug 'mileszs/ack.vim'
Plug 'cohama/lexima.vim'
Plug 'SirVer/ultisnips'
Plug 'honza/vim-snippets'
@rrmartins
rrmartins / init.vim
Created April 18, 2019 13:30 — forked from prkstaff/init.vim
My NeoVim config + Dracula theme + NerdTree
"*****************************************************************************
"" Vim-PLug core
"*****************************************************************************
if has('vim_starting')
set nocompatible " Be iMproved
endif
let vimplug_exists=expand('~/.config/nvim/autoload/plug.vim')
let g:vim_bootstrap_langs = "javascript,php,python,ruby"
@rrmartins
rrmartins / gist:2926aa3c78d96fc314a720b8aa4358b8
Created September 28, 2016 12:54 — forked from lttlrck/gist:9628955
rename git branch locally and remotely
git branch -m old_branch new_branch # Rename branch locally
git push origin :old_branch # Delete the old branch
git push --set-upstream origin new_branch # Push the new branch, set local branch to track the new remote
@rrmartins
rrmartins / Twelve_Go_Best_Practices.md
Created August 19, 2016 22:10 — forked from pzurek/Twelve_Go_Best_Practices.md
Twelve Go Best Practices