Skip to content

Instantly share code, notes, and snippets.

@kompiro
kompiro / build_job.sh
Created Dec 15, 2011
Jenkinsのジョブを実行して、notify-sendする
View build_job.sh
#!/bin/bash
JENKINS_CLI=jenkins-cli.jar
if [ "$1" = "" ]; then
echo "Usage: build_job.sh JOB_NAME"
exit 1
fi
if [ "$JENKINS_URL" = "" ]; then
@kompiro
kompiro / package.json
Created Nov 25, 2011
node-ninjaでcoffeescriptを使うの術
View package.json
{
"name": "Your App Name"
, "version": "0.0.1"
, "dependencies" : {
"coffee-script": ">= 1.1.2"
}
, "devDependencies" : {
"npm" : "latest"
}
, "scripts" : {
View NKF.nkfが内部で呼ばれるが、デコード途中で文字列が切れてしまうパターン
irb(main):001:0> source = "=?ISO-2022-JP?B?GyRCIXcbKEJJVBskQj83Q2VCLkpzGyhCIC0=?= =?ISO-2022-JP?B?IDIwMTAvOS8zGyRCISEbKEI=?= =?ISO-2022-JP?B?GyRCOkdNJUBoO3Y5YCRPIUhAZEJQJW0bKEI=?= =?ISO-2022-JP?B?GyRCITwlcyVBJDUkOyRrJDMkSCEqIUkbKEI=?="
=> "=?ISO-2022-JP?B?GyRCIXcbKEJJVBskQj83Q2VCLkpzGyhCIC0=?= =?ISO-2022-JP?B?IDIwMTAvOS8zGyRCISEbKEI=?= =?ISO-2022-JP?B?GyRCOkdNJUBoO3Y5YCRPIUhAZEJQJW0bKEI=?= =?ISO-2022-JP?B?GyRCITwlcyVBJDUkOyRrJDMkSCEqIUkbKEI=?="
irb(main):002:0> require 'kconv'
=> true
irb(main):003:0> source.toutf8()
error:
=> "@IT新着速報 -"
except:
View CSVExportWizardTest.java
package org.kompiro.jamcircle.kanban.ui.wizard;
import static org.hamcrest.CoreMatchers.is;
import static org.hamcrest.CoreMatchers.notNullValue;
import static org.junit.Assert.assertThat;
import static org.mockito.Matchers.any;
import static org.mockito.Mockito.mock;
import static org.mockito.Mockito.times;
import static org.mockito.Mockito.verify;
View WithWizard.java
package org.eclipse.swtbot.jface;
import java.lang.annotation.*;
import org.eclipse.jface.wizard.IWizard;
@Retention(RetentionPolicy.RUNTIME)
@Target(ElementType.TYPE)
@Inherited
public @interface WithWizard {
View WizardDialogTestRunner.java
package org.eclipse.swtbot.jface;
import java.lang.annotation.Annotation;
import java.lang.reflect.Field;
import org.eclipse.jface.wizard.IWizard;
import org.eclipse.jface.wizard.WizardDialog;
import org.eclipse.swt.widgets.Display;
import org.eclipse.swt.widgets.Shell;
import org.eclipse.swtbot.swt.finder.finders.UIThreadRunnable;
@kompiro
kompiro / gist:177392
Created Aug 29, 2009
CI on ubuntu using Hudson and Tomcat6 service for JAMCircle
View gist:177392
#!/bin/sh
#
# /etc/init.d/tomcat6 -- startup script for the Tomcat 6 servlet engine
#
# Written by Miquel van Smoorenburg <miquels@cistron.nl>.
# Modified for Debian GNU/Linux by Ian Murdock <imurdock@gnu.ai.mit.edu>.
# Modified for Tomcat by Stefan Gybas <sgybas@debian.org>.
# Modified for Tomcat6 by Thierry Carrez <thierry.carrez@ubuntu.com>.
#
### BEGIN INIT INFO
View plugin_customization.ini
# plugin_customization.ini
# sets default values for plug-in-specific preferences
# keys are qualified by plug-in id
# e.g., com.example.acmeplugin/myproperty=myvalue
# java.io.Properties file (ISO 8859-1 with "\" escapes)
# "%key" are externalized strings defined in plugin_customization.properties
# This file does not need to be translated.
# 私訳
# plug-inが特定されたpreferenceのデフォルト値を上書きします。