Skip to content

Instantly share code, notes, and snippets.

View meganemura's full-sized avatar
👓
Edit status

meganemura meganemura

👓
Edit status
View GitHub Profile
@meganemura
meganemura / deps.rb
Last active March 23, 2018 00:35
List dependencies
# $ cat Gemfile.lock | ruby deps.rb
ds = false
STDIN.each do |line|
if line.match?(/^DEPENDENCIES/)
ds = true
next
end
next if !ds
if ds && line.chomp == ""
@meganemura
meganemura / linguist.html.haml
Last active November 30, 2016 14:35
Syntax Highlighting for HAML
/ HAML comment
- # ruby comment
string
= "string"
= "string" #comment
= "string #{not_comment}" # comment
-#
multi line comment
multi line comment
# encoding: utf-8
# frozen_string_literal: true
# good
a = [
1,
]
# good
b = [
@meganemura
meganemura / rebase-master.sh
Last active December 25, 2015 22:48
Update git branches
#!/bin/bash
set -e
# pull origin
echo -ne "* "
git checkout master
git pull origin master
echo ""
branches=$(git branch | grep -v master)