Skip to content

Instantly share code, notes, and snippets.

View ymkjp's full-sized avatar
:shipit:
while true

Kenta Long Yamamoto ymkjp

:shipit:
while true
View GitHub Profile
@ymkjp
ymkjp / flawfinder.py
Created September 11, 2017 13:30 — forked from boyter/flawfinder.py
Flawfinder
#!/usr/bin/env python
from __future__ import division
"""flawfinder: Find potential security flaws ("hits") in source code.
Usage:
flawfinder [options] [source_code_file]+
See the man page for a description of the options."""
@ymkjp
ymkjp / LENB.js
Created February 9, 2016 08:25 — forked from hyamamoto/LENB.js
Google Doc & Spreadsheets's LENB() function which is present in Microsoft Excel. LENB() returns a number of bytes, while LENH() returns a width of the given text. These functions are useful when you check if your translation resources can be fit inside original screens.
// To add these functions to your Google Doc documents,
// see https://developers.google.com/apps-script/guides/sheets/functions
/**
* @fileOverview Google Doc Apps Script: LENB() / LENH() functions for Spreadsheet.
* @author Hiroshi Yamamoto ([email protected])
* @license <a href="http://www.wtfpl.net/">WTFPL version 2.0</a>
* @version 0.2.0
*/
ja:
devise_token_auth:
sessions:
not_confirmed: "'%{email}' に確認用のメールを送信しました。メール内の説明を読み、アカウントの有効化をしてください。"
bad_credentials: "ログイン用の認証情報が正しくありません。再度お試しください。"
not_supported: "/sign_in に GET はサポートされていません。POST をお使いください。"
user_not_found: "ユーザーが見つからないか、ログインしていません。"
token_validations:
invalid: "ログイン用の認証情報が正しくありません。"
registrations:
@ymkjp
ymkjp / elb_update_cert.sh
Last active January 22, 2016 06:05 — forked from hidekuro/elb_update_cert.sh
Fetch certification from Let's Encrypt → Upload to IAM → Set it up to ELB
#!/bin/bash
# https://gist.github.com/ymkjp/4f54ecb3446fa42ff2a8
set -e
cd $(dirname $0)
# Current date YYYYMMDD_HHMMSS
DATE_CURRENT_YMD=$(date '+%Y%m%d_%H%M%S')
# AWS Profile
body {
font-family: Helvetica, arial, sans-serif;
font-size: 14px;
line-height: 1.6;
padding-top: 10px;
padding-bottom: 10px;
background-color: white;
padding: 30px; }
body > *:first-child {

更新日:2013/05/23

rbenv, ruby-buildを更新

$ cd ~/.rbenv
$ git pull origin master
$ cd ~/.rbenv/plugins/ruby-build
$ git pull origin master
@ymkjp
ymkjp / dotfiles.sh
Last active December 16, 2015 04:29 — forked from sonots/dotfiles.sh
#!/bin/sh
[[ -e ~/.dotfiles ]] || git clone [email protected]:ymkjp/.dotfiles.git ~/.dotfiles
pushd ~/.dotfiles
git submodule init
git submodule update
for i in `ls -a`
do
[ $i = "." ] && continue
@ymkjp
ymkjp / tenkaichi-git.md
Created November 22, 2012 14:59 — forked from teppeis/tenkaichi-git.md
天下一gitconfig大会

天下一gitconfig大会(サイボウズ社内git勉強会@2012/11/20)の@teppeisの資料です。

ぎっとぎとにしてやんよ

DojoCat

  • gistでmarkdown書いたらbookmarkletでプレゼンになるよ。
@ymkjp
ymkjp / generate_pdf.pl
Created October 24, 2012 12:54 — forked from stanaka/generate_pdf.pl
Generate pdf for analyzing kindle paperwhite resolution
#!/usr/bin/env perl
use strict;
use warnings;
use GD;
sub draw_page {
my ($width, $height) = @_;
return unless $width && $height;