Skip to content

Instantly share code, notes, and snippets.

View tsuwatch's full-sized avatar

Tomohiro Suwa tsuwatch

View GitHub Profile
@kusano
kusano / circle.js
Created March 7, 2015 15:23
ガルーンの予定の参加者を円形に(回転版)
!function(){
function render(){
var t=performance.now()/1000;
document.querySelectorAll(".schedule_member_base_grn")[1].style.position="relative";
var p=document.querySelectorAll(".user-grn");
var n=p.length;
for(var i=0;i<n;i++){
var s=p[i].style;
s.position="absolute";
s.top=48*Math.sin(2*Math.PI*(i/n+t))+"px";
#!/usr/bin/ruby
require 'rss'
require 'open-uri'
require 'uri'
# 日本人っぽいのだけ欲しい場合'
URL = 'http://xpathfeed.com/feed?url=http%3A%2F%2Fjp.xvideos.com%2F&xpath_list=%2F%2F*%5B%40class%3D%22thumbBlock%22%5D%2Fdiv%2Fp%5B1%5D%2Fa'
RSS::Parser.parse(open(URL).read).channel.items.each{|x|
uri = URI.parse x.link
@ybenjo
ybenjo / README.md
Last active December 13, 2023 08:04 — forked from yagays/agqr.rb
save AGQR radio programs.

agqr.rb

これは何

AGQR の放送を保存するスクリプト.

fork 元との違いは

yagays / agqr.rb には

  • 31日まである月に翌日の指定が失敗する

というバグが存在する.

@moroya
moroya / nico_mylist_search.js
Created October 17, 2013 15:15
Niconico Mylist Search ブックマークレット(GINZA)
/***** Niconico Mylist Search ブックマークレット *****
ニコニコ動画のマイリストをインクリメンタルサーチします。
@auther : moroya http://moroya.hatenablog.jp/
@license: MIT License
*/
(function($){
if(location.href.indexOf('www.nicovideo.jp/my/mylist') === -1) {
if(window.confirm('このページはニコニコ動画の\nマイリストページではありません\nマイリストページへジャンプしますか?')) {
location.href="http://www.nicovideo.jp/my/mylist";

花火~ 最高な俺たちと糞コードの海

written by mizchi at 小物エンジニアの会.

最高の夏の花火について 花火

自己紹介

@Gab-km
Gab-km / github-flow.ja.md
Last active April 25, 2024 04:01 — forked from juno/github-flow.ja.md
GitHub Flow (Japanese translation)
@rosylilly
rosylilly / gist:3401612
Created August 20, 2012 06:40
先輩と覚える HTTP ステータスコード

先輩に学ぶ HTTP Status Code

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

登場人物

  • アプリケーション先輩: いつも忙しい。横に広がるのが得意(デブじゃない)。
  • 後輩: 頼んでばっかしで役に立たない。
  • サーバー先輩: アプリケーション先輩と仲がいい。Unix Socket でつながるくらい仲良し。
  • プロクシ先輩: アプリケーション先輩とかサーバー先輩と後輩の間を取り持って代わりに伝えたりしてくれる。たまに勝手にレスポンスを書き換える。
@paulmillr
paulmillr / active.md
Last active April 23, 2024 17:32
Most active GitHub users (by contributions). http://twitter.com/paulmillr

Most active GitHub users (git.io/top)

The count of contributions (summary of Pull Requests, opened issues and commits) to public repos at GitHub.com from Wed, 21 Sep 2022 till Thu, 21 Sep 2023.

Only first 1000 GitHub users according to the count of followers are taken. This is because of limitations of GitHub search. Sorting algo in pseudocode:

githubUsers
 .filter(user =&gt; user.followers &gt; 1000)
@tily
tily / scaling_isomorphic_javascript_code.ja.markdown
Last active May 1, 2023 09:03
サバクラ両方で動く JavaScript の大規模開発を行うために

サバクラ両方で動く JavaScript の大規模開発を行うために

原文:Scaling Isomorphic Javascript Code (This is just for study, please contact me at tily05 atmark gmail.com if any problem.)

考えてみれば Model-View-Controller とか MVC ってよく聞くよね。実際どんなものか知ってる? 抽象的に言うなら「オブジェクト情報の保持されるグラフィック・システム (つまり、ラスターではないグラフィック。ゲームとか) 上に構築された、表示系を中心としたアプリケーションにおいて、主要な機能どうしの関わりをうまく分離すること」とでも言おうか。もう少し深く考えを押し進めてみれば、これは当然、他のさまざまなアプリケーションにもあてはまる言葉 (bucket term ?) だ。

過去に多くの開発コミュニティが MVC による解決案を提供し、それによってよくあるユースケースにうまく対処し、地位を築くことができた。例をあげるなら、Ruby や Python コミュニティは Rails や Django を作り、MVC アーキテクチャを実現した。