Skip to content

Instantly share code, notes, and snippets.

View gtrabanco's full-sized avatar
:octocat:

Gabriel Trabanco gtrabanco

:octocat:
  • Spain
View GitHub Profile
@simme
simme / Install_tmux
Created October 19, 2011 07:55
Install and configure tmux on Mac OS X
# First install tmux
brew install tmux
# For mouse support (for switching panes and windows)
# Only needed if you are using Terminal.app (iTerm has mouse support)
Install http://www.culater.net/software/SIMBL/SIMBL.php
Then install https://bitheap.org/mouseterm/
# More on mouse support http://floriancrouzat.net/2010/07/run-tmux-with-mouse-support-in-mac-os-x-terminal-app/
@v-yarotsky
v-yarotsky / .tmux.conf
Created March 22, 2012 11:57
Mac OS X tmux config
### INSTALLATION NOTES ###
# 1. Install Homebrew (https://github.com/mxcl/homebrew)
# 2. brew install zsh
# 3. Install OhMyZsh (https://github.com/robbyrussell/oh-my-zsh)
# 4. brew install reattach-to-user-namespace --wrap-pbcopy-pbpaste && brew link reattach-to-user-namespace
# 5. Install iTerm2
# 6. In iTerm2 preferences for your profile set:
# Character Encoding: Unicode (UTF-8)
# Report Terminal Type: xterm-256color
# 7. Put itunesartist and itunestrack into PATH
@foonicorn
foonicorn / gist:e6696fb8697668427ee0
Created July 20, 2014 07:05
Install Homebrew without sudo and wget/curl
#!/bin/bash
HOMEBREW_URL="https://github.com/Homebrew/homebrew/archive/master.zip"
HOMEBREW_DOWNLOAD=homebrew-master.zip
HOMWBREW_UNZIPED=homebrew-master
HOMEBREW_DIR="$HOME/Homebrew"
# Use Python to download homebrew because wget and curl may not be installed.
python -c "import urllib2; r=urllib2.urlopen('$HOMEBREW_URL'); f=open('$HOMEBREW_DOWNLOAD','w'); f.write(r.read()); f.close()"
@maxrimue
maxrimue / semver.sh
Created July 24, 2015 15:36
Compare semantic versions in pure bash
#!/bin/bash
# Assume we have two semantic versions that we want to compare:
version1=0.12.0
version2=1.15.5
# First, we replace the dots by blank spaces, like this:
version1=${version1//./ }
@Dufgui
Dufgui / gist:72debe81068bf3ecd7d8
Last active April 25, 2023 14:34 — forked from eduardocardoso/gist:82a629882ddb02ab3677
Script to delete exited containers and untagged/unused images from docker
#!/bin/bash
set -o errexit
echo "Removing exited docker containers..."
docker ps -a -f status=exited -q | xargs -r docker rm -v
echo "Removing dangling images..."
docker images --no-trunc -q -f dangling=true | xargs -r docker rmi
@aallan
aallan / mac-vendor.txt
Last active July 22, 2024 13:39
List of MAC addresses with vendors identities
000000 Officially Xerox
000001 SuperLAN-2U
000002 BBN (was internal usage only, no longer used)
000003 XEROX CORPORATION
000004 XEROX CORPORATION
000005 XEROX CORPORATION
000006 XEROX CORPORATION
000007 XEROX CORPORATION
000008 XEROX CORPORATION
000009 powerpipes?
@dvdsmpsn
dvdsmpsn / gist:5c98442e5af17b43858dc110ad424e0f
Last active August 19, 2023 17:56 — forked from alexis89x/broadcast-channel-es6.js
Broadcast Channel API polyfill
/**
@class BroadcastChannel
A simple BroadcastChannel polyfill that works with all major browsers.
Please refer to the official MDN documentation of the Broadcast Channel API.
======
@see <a href="https://developer.mozilla.org/en-US/docs/Web/API/Broadcast_Channel_API">Broadcast Channel API on MDN</a>
@author Alessandro Piana
@version 1.0.0
@szero
szero / curlbar
Last active October 17, 2023 15:08
cURL wrapper that makes saner upload/download progress bar
#!/usr/bin/env bash
#shellcheck disable=SC2155,SC1117
# Wraps curl with a custom-drawn progress bar. Use it just like curl:
#
# $ curlbar -O http://example.com/file.tar.gz
# $ curlbar http://example.com/file.tar.gz > file.tar.gz
#
# All arguments to the program are passed directly to curl. Define your
# custom progress bar in the `print_progress` function.
#
@ozanmuyes
ozanmuyes / install-open.sh
Last active October 21, 2021 14:26
Mac OSX 'open' equivalent for Debian
#!/bin/bash
# echoes '#!/bin/bash xdg-open "$1" &> $HOME/.xdg-open-error &' to /usr/sbin/open
echo -e "\043\041/bin/bash\n\nxdg-open \042\044\061\042 &> $HOME/.xdg-open-error &" > ozanmuyes-open
sudo mv ozanmuyes-open /usr/sbin/open
sudo chmod +x /usr/sbin/open
echo -e "\n# Mac OSX \047open\047 equivalent for Debian\nalias 'open'='/usr/sbin/open'" >> $HOME/.bashrc
. $HOME/.bashrc
@webframp
webframp / keybase.md
Created July 25, 2017 18:14
Signing git commits on github using keybase.io gpg key

Probably one of the easiest things you'll ever do with gpg

Install Keybase: https://keybase.io/download and Ensure the keybase cli is in your PATH

First get the public key

keybase pgp export | gpg --import

Next get the private key