Skip to content

Instantly share code, notes, and snippets.

View hangingman's full-sized avatar
🌶️

hangedman hangingman

🌶️
  • Kanagawa, Japan
  • 23:28 (UTC +09:00)
View GitHub Profile
@selman
selman / heroku.rb
Created September 7, 2010 23:08
Padrino heroku template
RAKEFILE = <<-RAKEFILE
require File.dirname(__FILE__) + '/config/boot.rb'
require 'thor'
require 'padrino-core/cli/rake'
PadrinoTasks.init
RAKEFILE
PV = Padrino.version
GEMFILE = <<-GEMFILE
@seyan
seyan / P327Test.java
Created April 12, 2011 06:41
ソルトを用いたパスワードのハッシュ化:レインボークラックなどへの対策
import static org.junit.Assert.assertFalse;
import java.io.UnsupportedEncodingException;
import java.security.MessageDigest;
import java.security.NoSuchAlgorithmException;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.junit.Test;
@544
544 / patchSqlTemplate.sql
Created April 29, 2011 08:22
データパッチを当てるときのSQLのテンプレート
SET ECHO ON
SET TIMING ON
SET PAGESIZE 2000
SET LINE 9999
SPOOL PATCHNAME_01_YYYYMMDD.LOG
/*---------------------------------------------------
|| 処理開始時刻
---------------------------------------------------*/
SELECT TO_CHAR (SYSDATE,'YYYY/MM/DD HH24:MI:SS') AS 開始時刻 FROM DUAL;
@nijikokun
nijikokun / yaml.syntax.js
Created August 8, 2011 02:14
SyntaxHighlighter for YAML
/**
* SyntaxHighlighter
* http://alexgorbatchev.com/
*
* SyntaxHighlighter is donationware. If you are using it, please donate.
* http://alexgorbatchev.com/wiki/SyntaxHighlighter:Donate
*
* @version
* 2.0.320 (July 26 2009)
*
@lbaehren
lbaehren / IdentifyOS.cmake
Created April 18, 2012 12:47
Identification of operating system @ CMake
if (UNIX)
if (APPLE)
set (CMAKE_OS_NAME "OSX" CACHE STRING "Operating system name" FORCE)
else (APPLE)
## Check for Debian GNU/Linux ________________
@hatak
hatak / carton-setup.sh
Created May 23, 2012 15:22
install perlbrew + cpanm + carton
#!/bin/bash
PERL_STABLE="5.16.1"
echo '%< --- installing perlbrew ---'
echo
curl -kL http://install.perlbrew.pl | bash
source ~/perl5/perlbrew/etc/bashrc
perlbrew install --notest perl-${PERL_STABLE}
@x-cray
x-cray / build-report.groovy
Created May 29, 2012 13:17
Jenkins email-ext plugin groovy template. Generates build report. Based on http://techkriti.wordpress.com/2008/08/30/using-groovy-with-hudson-to-send-rich-text-email/
<!DOCTYPE html>
<head>
<title>Build report</title>
<style type="text/css">
body
{
margin: 0px;
padding: 15px;
}
@tkqubo
tkqubo / html5TagSyntax.bnf
Last active April 23, 2024 01:49
EBNF notation for HTML5 tag syntax
tag-open := '<' tag-name ws* attr-list? ws* '>'
tag-empty := '<' tag-name ws* attr-list? ws* '/>'
tag-close := '</' tag-name ws* '>'
attr-list := (ws+ attr)*
attr := attr-empty | attr-unquoted | attr-single-quoted | attr-double-quoted
attr-empty := attr-name
attr-unquoted := attr-name ws* = ws* attr-unquoted-value
@yosemitebandit
yosemitebandit / send_pdf_with_boto_ses.py
Created June 6, 2012 17:56
send PDF attachment with boto and SES
''' quick example showing how to attach a pdf to multipart messages
and then send them from SES via boto
'''
from email.mime.text import MIMEText
from email.mime.application import MIMEApplication
from email.mime.multipart import MIMEMultipart
import boto
@ctyo
ctyo / Install.pm
Created July 13, 2012 17:31
FreeStyleWiki上でMarkdown記法での記入を可能にするプラグイン
############################################################
#
# FreeStyleWiki上でMarkdown記法での記入を可能にします。
#
############################################################
package plugin::markdown::Install;
use strict;
sub install {
my $wiki = shift;