Skip to content

Instantly share code, notes, and snippets.

View jollyjoester's full-sized avatar

Hideyuki Nanashima jollyjoester

View GitHub Profile
@jollyjoester
jollyjoester / html5_template.html
Created September 26, 2013 02:49
minimum HTML5 template
<!DOCTYPE html>
<html lang="ja">
<head>
<meta charset="UTF-8">
<link rel="stylesheet" type="text/css" href="css/html5reset.css" />
<!--[if lt IE 9]>
<script src="http://html5shim.googlecode.com/svn/trunk/html5.js"></script>
<![endif]-->
<style type="text/css">
<!-- /*css*/
// メインのViewController
- (void)viewDidLoad
{
[self.navigationController setNavigationBarHidden:YES animated:NO];
}
// サブのViewController
-(void)viewWillAppear:(BOOL)animated{
[self.navigationController setNavigationBarHidden:NO animated:YES];
}
@jollyjoester
jollyjoester / show_hide_animation
Created April 8, 2014 07:47
Show/Hide animation
@property (weak, nonatomic) IBOutlet UIWebView *webView;
...
- (void)showWebView{
// アニメーションでWebViewを表示させる
void (^animations)(void) = ^{
self.webView.alpha = 1.0;
};
@jollyjoester
jollyjoester / swift_trial.swift
Last active August 29, 2015 14:03
swift trial
// Playground - noun: a place where people can play
import UIKit
var str = "Hello, playground"
var str2 = "Stinrg"
str2 = "Strign2"
let str3 = "String3"
@jollyjoester
jollyjoester / yum.sh
Created July 11, 2014 02:01
yum memo
#hogeをインストール
yum install [hoge]
#reposのクリーン
yum clean packages
#hogeをアップデート
yum update [hoge]
#hogeを削除
@jollyjoester
jollyjoester / setting_centos.sh
Last active August 29, 2015 14:03
Simple setting CentOS6.5 on Docker
#yum更新
yum -y update
#vim install
yum -y install vim-enhanced
#ssh install
yum -y install openssh-server
/etc/init.d/sshd start
@jollyjoester
jollyjoester / docker.sh
Last active August 29, 2015 14:03
Docker memo
#CentOSをpullしてrun
docker run centos /bin/echo "Hello World"
docker run -i -t centos /bin/bash
#Dockerの中でCentOS設定
#exitするとDockerから抜けられる
#-aをつけると既に終了した環境も含めて確認できる
docker ps -a
@jollyjoester
jollyjoester / gem.sh
Created July 11, 2014 06:16
gem memo
#バージョン
gem -v
#Gem自身をアップデート
gem update --system
#gemを探す
gem list [hoge] #頭からの文字列で
gem search [hoge] #正規表現で
@jollyjoester
jollyjoester / boot2docker.sh
Created July 11, 2014 09:41
boot2docker memo
#boot2dockerのVM作成
boot2docker init
#VMあげる
boot2docker up|start|boot
#VMにSSH
boot2docker ssh
#VMの状態
@jollyjoester
jollyjoester / setting_ror_on_docker_centos.sh
Created July 11, 2014 09:42
Setting Ruby on Rails on docker:centos
#Docker:centosでRuby on Rails環境作成
#以下rootもしくはsudoで
yum update
yum -y install tar
yum -y install gcc
#Dockerのcentos:latestでやる場合は通常のコマンドではエラーになる
#yum -y install openssl-devel ##エラー
yum -y install --enablerepo=centosplus openssl-devel
yum -y install sqlite-devel