Skip to content

Instantly share code, notes, and snippets.

View kuwabarahiroshi's full-sized avatar

Hiroshi Kuwabara kuwabarahiroshi

View GitHub Profile
@kuwabarahiroshi
kuwabarahiroshi / Makefile
Created October 22, 2013 09:13
iOSアプリのbuild -> TestFlightアップを自動化するMakefile
.PHONY: flight build
DATETIME = $(shell date '+%Y-%m-%d_%H%M%S')
PROVISIONNING_PROFILE = AAAAAAAA-AAAA-AAAA-AAAA-AAAAAAAAAAAA
BUILD = staging
default:
xcodebuild -sdk iphoneos -target appname -configuration Production -scheme appname-production build
update-bundle-version:
/usr/libexec/PlistBuddy -c "Set :CFBundleVersion `git rev-list HEAD | wc -l`" appname/appname-Info.plist
// Invoke annonymous function on domready event.
$(function(){
// Declare page index to get via ajax request.
// This value will be incremented later.
var page = 2;
// Base URL to request.
// such as:
// http://www.kobedenshi.ac.jp/?tag=update&page=2
@kuwabarahiroshi
kuwabarahiroshi / Gemfile
Last active December 23, 2015 06:29
最近使ってるGemfileです。
#
# Please keep gems in alphabetical order in each block.
# Gemはアルファベット順に記述をお願い致します。
#
source 'https://rubygems.org'
ruby '2.0.0'
gem 'awesome_print'
gem 'aws-sdk'
gem 'aws_cf_signer'
#
# Be sure to run `pod spec lint cocos2d-iphone-extensions.podspec' to ensure this is a
# valid spec and remove all comments before submitting the spec.
#
# To learn more about the attributes see http://docs.cocoapods.org/specification.html
#
Pod::Spec.new do |s|
s.name = "CCScrollLayer"
s.version = "0.2.3"
s.summary = "CCScrollLayer by 3rd party extensions for cocos2d-iphone"
#
# Be sure to run `pod spec lint CCBReader.podspec' to ensure this is a
# valid spec and remove all comments before submitting the spec.
#
# To learn more about the attributes see http://docs.cocoapods.org/specification.html
#
Pod::Spec.new do |s|
s.name = "NSDictionary+XPath"
s.version = "0.0.2"
s.summary = "Get value from NSDictionary by XPath."
#
# Be sure to run `pod spec lint CCBReader.podspec' to ensure this is a
# valid spec and remove all comments before submitting the spec.
#
# To learn more about the attributes see http://docs.cocoapods.org/specification.html
#
Pod::Spec.new do |s|
s.name = "CCBReader"
s.version = "0.0.5"
s.summary = "CCBReader for CocosBuilder."
#
# Be sure to run `pod spec lint EBPurchase.podspec' to ensure this is a
# valid spec and remove all comments before submitting the spec.
#
# To learn more about the attributes see http://docs.cocoapods.org/specification.html
#
Pod::Spec.new do |s|
s.name = "EBPurchase"
s.version = "0.0.3"
s.summary = "Simple In-App Purchase for iOS."
@kuwabarahiroshi
kuwabarahiroshi / gist:4266118
Created December 12, 2012 08:33
Solr1.4系、Solr3.x系におけるPivot Facet検索について下記によい記事があったのでその抄訳です。 http://loose-bits.com/2011/09/20/pivot-facets-solr.html

Pivot Faceting (Decision Trees) in Solr 1.4.

http://loose-bits.com/2011/09/20/pivot-facets-solr.html

Solrのピボットファセット

Solrのファセット機能は、ある単語や語句、フィールドの値に対する検索結果をさらに細分化して、それらの集計数を返してくれます。 ファセットはそれ自身強力な集計ツールであると同時に、検索結果をもう一段深く絞り込む際のプレビューのように機能します。

Solr4.0より前は、ファセット機能は1階層の検索条件に対してのみ有効でした。つまり、あるクエリのもとに「'foo'フィールドについての集計」のようなことしかできなかったのです。 Solr4.0からピボットファセットという(決定木とも呼ばれる)機能が導入されました。これにより、「'bar'フィールドの値それぞれに対して、'foo'フィールドの値を集計する」といったことができるようになりました。独立した複数のSolrフィールドにまたがった多階層ファセットのことです。

<?php
class DefaultController extends Controller
{
/**
* Dashboard page.
* @Permissions(perm="dashboard_view")
* @Route("/", name="ITEDashboardBundle_index")
* @Template()
* @return array