Skip to content

Instantly share code, notes, and snippets.

View meganemura's full-sized avatar
👓
Edit status

meganemura meganemura

👓
Edit status
View GitHub Profile
@dergachev
dergachev / GIF-Screencast-OSX.md
Last active May 2, 2024 05:55
OS X Screencast to animated GIF

OS X Screencast to animated GIF

This gist shows how to create a GIF screencast using only free OS X tools: QuickTime, ffmpeg, and gifsicle.

Screencapture GIF

Instructions

To capture the video (filesize: 19MB), using the free "QuickTime Player" application:

@kule
kule / mini_rspec.rb
Created September 11, 2018 09:37
Simplified example of how rspec works
require 'bundler/inline'
gemfile do
source 'https://rubygems.org'
gem 'colorize'
end
class MatcherInterface
def initialize(some_object)
@some_object = some_object
@chetan
chetan / yardoc_cheatsheet.md
Last active April 16, 2024 23:49
YARD cheatsheet
# config/routes.rb
resources :documents do
scope module: 'documents' do
resources :versions do
post :restore, on: :member
end
resource :lock
end
end
@davatron5000
davatron5000 / gist:2254924
Created March 30, 2012 20:57
Static Site Generators

Backstory: I decided to crowdsource static site generator recommendations, so the following are actual real world suggested-to-me results. I then took those and sorted them by language/server and, just for a decent relative metric, their Github Watcher count. If you want a heap of other projects (including other languages like Haskell and Python) Nanoc has the mother of all site generator lists. If you recommend another one, by all means add a comment.

Ruby

@DanHerbert
DanHerbert / fix-homebrew-npm.md
Last active February 12, 2024 17:18
Instructions on how to fix npm if you've installed Node through Homebrew on Mac OS X or Linuxbrew

OBSOLETE

This entire guide is based on an old version of Homebrew/Node and no longer applies. It was only ever intended to fix a specific error message which has since been fixed. I've kept it here for historical purposes, but it should no longer be used. Homebrew maintainers have fixed things and the options mentioned don't exist and won't work.

I still believe it is better to manually install npm separately since having a generic package manager maintain another package manager is a bad idea, but the instructions below don't explain how to do that.

Fixing npm On Mac OS X for Homebrew Users

Installing node through Homebrew can cause problems with npm for globally installed packages. To fix it quickly, use the solution below. An explanation is also included at the end of this document.

@sorah
sorah / a.sh
Created October 17, 2014 05:20
Homebrew relink if necessary
#!/bin/bash
for keg in /usr/local/Library/LinkedKegs/*; do
kegname="$(basename $keg)"
dir="$(find $keg/ -maxdepth 1 -type d | grep '\/\(sbin\|bin\|etc\|var\|lib\|include\|libexec\|share\)$' | head -n1)"
[ -z "${dir}" ] && continue
testee="$(find $dir -type f | head -n1 | sed -e "s|${keg}||")"
[ -f /usr/local/$testee ] || (echo $keg && brew unlink $kegname; brew link --force $kegname)
done
@stepney141
stepney141 / BookmarkAPI_en.md
Last active April 4, 2023 01:45
(DEPRECATED) Twitter Undocumented Endpoints for Bookmark
@rummelonp
rummelonp / zsh_completion.md
Last active February 22, 2023 15:06
zsh の補完関数の自作導入編

zsh の補完関数の自作導入編

あまり深く理解してないので識者のツッコミ大歓迎

補完を有効にする

取り敢えず最低限だけ

# 補完を有効にする
@everpeace
everpeace / Why People Want Microservices.md
Last active November 8, 2022 10:37
マイクロサービス化が進む背景について考えてみた

マイクロサービス化が進む背景について考えてみた

最近マイクロサービスって流行ってますよね。バズってると言ってもいいくらい。

個人的には、「マイクロサービスって結局何なの?」とか、「SOAと何が違うわけ?」とかいう議論は苦手です。

でも「なんでみんなマイクロサービスで作りたいのか?なんでマイクロサービスで作られるサービスが多いのか?」にはすごく興味があるんです。

僕は今、シリコンバレーにある日系SIerの小さな子会社で駐在員をやっていますが、このエリアに居ると、とにかく最近、

「サービス全体が、独立した小さなサービスの集合で構成されるようになってきている」