Skip to content

Instantly share code, notes, and snippets.

@repeatedly
repeatedly / msgpack_issue_121.md
Last active November 30, 2021 02:09
MessagePackが文字列とバイナリをわけないのは問題?

MessagePackが文字列とバイナリをわけないのは問題?

msgpack/msgpack#121

Objective Cの実装使ってるとある問題にぶちあたった.なので,文字列をちゃんとバイナリ(Raw)と分けるべき,という提案

(*) 俺は熟読したわけではないので,中身が気になる人はちゃんと本スレを読みましょう

そもそもMessagePackとは

@mochiz
mochiz / gist:4736183
Last active April 16, 2023 03:56
rbenvとruby-buildでRuby環境を最新に保つ

rbenvとruby-buildでRuby環境を最新に保つ

更新日:2014/11/19

rbenv, ruby-buildを更新

$ cd ~/.rbenv
$ git pull origin master
$ cd ~/.rbenv/plugins/ruby-build
$ git pull origin master
@mala
mala / AutoCopyFasterfoxLite.txt
Last active December 11, 2015 03:29
AutoCopy / Fasterfox Liteに関するスパイウェア疑惑に関するメモ
http://mozilla-remix.seesaa.net/article/313529718.html
Fasterfox Liteで送信されているのは
- 起動時にUserAgentやユニークidを送る。
- 存在しないドメインにアクセスした場合に、そのドメイン名を送る(フルのURLではない)
「閲覧URLに関わる情報」で送られるのは、最大でもドメイン名まで。(ソースを参照)
Fasterfox Liteの過去バージョン(3.9.5-3.9.8) も調べてみたが、同様に閲覧URLを収集する機能は存在しないか、コメントアウトされていた。
ソース中
@marocchino
marocchino / rt.md
Created September 17, 2012 17:48
rubykaigi2012 timetable
@rosylilly
rosylilly / gist:3401612
Created August 20, 2012 06:40
先輩と覚える HTTP ステータスコード

先輩に学ぶ HTTP Status Code

超雑にまとめました。修正してください。

登場人物

  • アプリケーション先輩: いつも忙しい。横に広がるのが得意(デブじゃない)。
  • 後輩: 頼んでばっかしで役に立たない。
  • サーバー先輩: アプリケーション先輩と仲がいい。Unix Socket でつながるくらい仲良し。
  • プロクシ先輩: アプリケーション先輩とかサーバー先輩と後輩の間を取り持って代わりに伝えたりしてくれる。たまに勝手にレスポンスを書き換える。
@ukyo
ukyo / prototype.md
Last active October 6, 2015 11:57
About Javascript prototype

#プロトタイプと、あとクラス、継承、ミックスインと呼ばれている物の説明

この文書はなるべく正確な情報を書きたいのでちょくちょく更新されます。あと、ちょくちょくキャラが変わるのは気にしないでください。修正した部分に関する情報は コメント やリビジョンを参照してください。

プリミティブ型とオブジェクト型

Javascriptの変数にはプリミティブ型とオブジェクト型が存在する。

###プリミティブ型

@tmaeda
tmaeda / graph.rb
Created May 24, 2012 16:37
sprk2012 pull req graph
# sprk2012 pull req graph
require 'date'
require 'time'
require 'octokit'
client = Octokit::Client.new({:auto_traversal => true})
pulls = client.pulls("sprk2012/sprk2012-cfp")
days = (Date.new(2012,4,26)..Date.new(2012,5,25)).to_a.map{|d| [d.to_s, 0]}
require "open-uri"
[
"http://pastebin.com/raw.php?i=Kc9ng18h",
"http://pastebin.com/raw.php?i=vCMndK2L",
"http://pastebin.com/raw.php?i=JdQkuYwG",
"http://pastebin.com/raw.php?i=fw43srjY"
].each do |url|
open(url).each_line do |line|
name, password = line.chomp.split(/:/)
@irohiroki
irohiroki / rspec-syntax-cheat-sheet.rb
Created March 27, 2012 06:23 — forked from dnagir/rspec-syntax-cheat-sheet.rb
RSpec 2 syntax cheat sheet by example
# RSpec 2.0 syntax Cheet Sheet by http://ApproachE.com
# defining spec within a module will automatically pick Player::MovieList as a 'subject' (see below)
module Player
describe MovieList, "with optional description" do
it "is pending example, so that you can write ones quickly"
it "is already working example that we want to suspend from failing temporarily" do
pending("working on another feature that temporarily breaks this one")
@them0nk
them0nk / rspec_rails_cheetsheet.rb
Created March 23, 2012 03:39
Rspec Rails cheatsheet (include capybara matchers)
#Model
@user.should have(1).error_on(:username) # Checks whether there is an error in username
@user.errors[:username].should include("can't be blank") # check for the error message
#Rendering
response.should render_template(:index)
#Redirecting
response.should redirect_to(movies_path)