Skip to content

Instantly share code, notes, and snippets.

View daisy1754's full-sized avatar

Kazuki daisy1754

  • sardine.ai
  • San Francisco
View GitHub Profile
@caseywatts
caseywatts / Gemfile
Last active February 19, 2020 21:23
Sinatra on Cloud9
source 'https://rubygems.org'
gem 'sinatra'
gem 'sinatra-contrib'
@neiraza
neiraza / FormActivity.java
Created August 29, 2013 01:01
今日は僕の誕生日なので、誕生日を公開するSpinnerネタ
/**
* Created by togu on 2013/07/23.
*/
public class FormActivity extends Activity implements OnItemSelectedListener {
private Spinner birthdayPermission;
@Override
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
@komasaru
komasaru / rmagick_img_info.rb
Created August 10, 2013 03:16
Ruby script to get informations of a image file by RMagick.
require 'RMagick'
# アニメーション GIF が考慮されて画像は配列で読み込まれるので、
# 配列の先頭画像を取得する。
img = Magick::Image.read("img_1.jpg").first
# 以下のように取得してもよい。
#img = Magick::ImageList.new("img_1.jpg")
# 画像情報取得
puts "FILENAME : #{img.filename}" # ファイル名
@ChrisRisner
ChrisRisner / Countdown.java
Last active December 17, 2015 07:09
CountDownLatch Example
private class MyServiceFilter implements ServiceFilter {
@Override
public void handleRequest(final ServiceFilterRequest request, final NextServiceFilterCallback nextServiceFilterCallback,
final ServiceFilterResponseCallback responseCallback) {
nextServiceFilterCallback.onNext(request, new ServiceFilterResponseCallback() {
@Override
public void onResponse(ServiceFilterResponse response, Exception exception) {
StatusLine status = response.getStatus();
int statusCode = status.getStatusCode();
@oodavid
oodavid / README.md
Last active June 12, 2024 00:28 — forked from aronwoost/README.md
Deploy your site with git

Deploy your site with git

This gist assumes:

  • you have a local git repo
  • with an online remote repository (github / bitbucket etc)
  • and a cloud server (Rackspace cloud / Amazon EC2 etc)
    • your (PHP) scripts are served from /var/www/html/
    • your webpages are executed by apache
  • apache's home directory is /var/www/