Skip to content

Instantly share code, notes, and snippets.

View tdkn's full-sized avatar
😎
Power 💪

Shun Tedokon tdkn

😎
Power 💪
View GitHub Profile
@tdkn
tdkn / gist:5811757
Last active December 18, 2015 16:29
Ubuntu 12.04 LTS setting
# Home directory language setting : Japanese -> English
LANG=C; xdg-user-dirs-gtk-update
# useful app installation
sudo apt-get install aptitude
sudo aptitude install zsh vim-gnome ibus-mozc git
# git config
git config --global http.proxy proxy.addr.example:8080
@tdkn
tdkn / geo.html
Created August 20, 2013 03:04
Google Maps JavaScript API v3 Geocoding
<!DOCTYPE html>
<html>
<head>
<!--
(API KEYを取得して?key=YOUR_API_KEYの部分を書き換える)
API取得先: https://code.google.com/apis/console
参考文献: http://www.ajaxtower.jp/googlemaps/charset/index1.html
ドキュメント: https://developers.google.com/maps/documentation/javascript/geocoding?hl=ja
-->
/*
* clang-exam1203.cpp
*/
#include "stdafx.h"
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <ctype.h>
#include <limits.h>
@tdkn
tdkn / .vimrc
Last active April 10, 2016 16:18
bin/neoinstall 使用時の エラー(not found in 'runtimepath': "autoload/vimproc.vim")について
" https://github.com/tdkn/dotfiles/blob/master/.vimrc
"------------------------------------------------------
"---------------
" Bundler
"---------------
if has('vim_starting')
set nocompatible " Be iMproved
set runtimepath+=~/.vim/bundle/neobundle.vim/
endif
@tdkn
tdkn / apminstall.sh
Last active January 18, 2016 16:41
Install Atom Packages
#!/bin/sh
PACKAGES=(
minimap
minimap-autohide
minimap-git-diff
file-icons
emmet
vim-mode
@tdkn
tdkn / webpack.config.js
Last active September 19, 2016 18:51
Animation製作時のWebpackのconfig
import webpack from 'webpack';
import path from 'path'
module.exports = {
entry: {
'main': `${__dirname}/_dev/js/main`,
'vendor': [
'three',
'gsap',
'pixi.js',
@tdkn
tdkn / ViewController.swift
Created November 20, 2016 13:39
Sample of NSLayoutConstraint
label.translatesAutoresizingMaskIntoConstraints = false
view.addSubview(label)
view.addConstraints([
NSLayoutConstraint(
item: label,
attribute: .width,
relatedBy: .equal,
toItem: nil,
attribute: .width,
multiplier: 1.0,
@tdkn
tdkn / ViewController.swift
Last active November 20, 2016 13:51
Sample of SnapKit
view.addSubview(label)
label.snp.makeConstraints { (make) in
make.size.equalTo(100)
make.center.equalToSuperview()
}
@tdkn
tdkn / fetch-pref.js
Last active August 23, 2017 08:57
潮位表掲載地点一覧表(2018年)
require('es6-promise').polyfill()
require('isomorphic-fetch')
const fetchAsync = async () => {
const url =
'https://rawgit.com/tdkn/87ea58d6bd9b9f0a12f6ff176a6ca76f/raw/56910dd51cb5451d33699c02b3f7ca3ae28b0749/tide-area.json'
const response = await fetch(url)
const points = await response.json()
const symbols = {}
@tdkn
tdkn / brew
Created October 20, 2017 03:05
my brew
brew install carthage coreutils fzf git-extras htop ranger reattach-to-user-namespace swiftlint tig tmux tree wget yarn zsh zsh-completions
brew install mongodb
brew install mysql