Skip to content

Instantly share code, notes, and snippets.

View kohsuke's full-sized avatar
🏠
WFH

Kohsuke Kawaguchi kohsuke

🏠
WFH
View GitHub Profile
@kohsuke
kohsuke / nohup.c
Created November 7, 2014 23:21
nohup.c
/* nohup -- run a command immune to hangups, with output to a non-tty
Copyright (C) 2003-2005, 2007-2011 Free Software Foundation, Inc.
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
@kohsuke
kohsuke / git-children-of
Created November 21, 2013 21:44
Given a commit, find immediate children of that commit.
#!/bin/bash -e
# given a commit, find immediate children of that commit.
for arg in "$@"; do
for commit in $(git rev-parse $arg^0); do
for child in $(git log --format='%H %P' --all | grep -F " $commit" | cut -f1 -d' '); do
git describe $child
done
done
done
@kohsuke
kohsuke / 2nd smartctl
Created September 11, 2012 18:19
smartmontools
kohsuke@cabbage:~$ date; sudo smartctl -a /dev/sda
Tue Sep 11 18:23:11 UTC 2012
smartctl version 5.38 [i686-pc-linux-gnu] Copyright (C) 2002-8 Bruce Allen
Home page is http://smartmontools.sourceforge.net/
Device: ADAPTEC RAID-5 Version: 3B05
Device type: disk
Transport protocol: Parallel SCSI (SPI-4)
Local Time is: Tue Sep 11 18:23:11 2012 UTC
Device supports SMART and is Enabled
#include <OWL.h>
#include <Dialog.h>
#include <Button.h>
#define HAIWIDTH (24) //牌の幅(Local)
#define HAIHEIGHT (30) //牌の高さ(Local)
#define STANDARDWIDTH (10*HAIWIDTH+64+192+16) //画面の幅
#define STANDARDHEIGHT (HAIHEIGHT*13+GetSystemMetrics(SM_CYMENU) \
+GetSystemMetrics(SM_CYCAPTION)+GetSystemMetrics(SM_CYBORDER)*2+32)
//画面の高さ
<?xml version="1.0" encoding="UTF-8"?>
<testsuite name="foo.FooTest" time="0" tests="3" errors="0" skipped="0" failures="1">
<properties>
<property name="java.runtime.name" value="Java(TM) SE Runtime Environment"/>
<property name="sun.boot.library.path" value="/usr/local/jdk1.8.0_144/jre/lib/amd64"/>
<property name="java.vm.version" value="25.144-b01"/>
<property name="java.vm.vendor" value="Oracle Corporation"/>
<property name="maven.multiModuleProjectDirectory" value="/home/kohsuke/ws/launchable/test"/>
<property name="java.vendor.url" value="http://java.oracle.com/"/>
<property name="path.separator" value=":"/>
hello
[2019-11-20T20:24:13.550Z] + groovy -Dgrape.config=./grapeConfig.xml ./lib/runner.groovy jdk.groovy
[2019-11-20T20:24:16.390Z] loading dependencies...done
[2019-11-20T20:24:18.920Z] Nov 20, 2019 8:14:59 PM com.gargoylesoftware.htmlunit.html.HtmlScript isExecutionNeeded
[2019-11-20T20:24:18.920Z] WARNING: Script is not JavaScript (type: text/xml, language: ). Skipping execution.
[2019-11-20T20:24:19.179Z] Nov 20, 2019 8:14:59 PM com.gargoylesoftware.htmlunit.javascript.host.Document jsxFunction_createElement
[2019-11-20T20:24:19.179Z] SEVERE: Unexpected exception occurred while parsing HTML snippet
[2019-11-20T20:24:19.179Z] Nov 20, 2019 8:14:59 PM com.gargoylesoftware.htmlunit.javascript.StrictErrorReporter runtimeError
[2019-11-20T20:24:19.179Z] SEVERE: runtimeError: message=[Unexpected exception occurred while parsing HTML snippet: input name="x"] sourceName=[https://www.oracle.com/us/assets/prototype-1.7.2.0.js] line=[2092] lineSource=[null] lineOffset=[0]
[2019-11-20T20:24:19.438Z] Nov 20, 2019 8:14:59 PM
@kohsuke
kohsuke / stuck.log
Last active August 6, 2019 15:35
With surefire 2.20.1
[WARNING]
[WARNING] Some problems were encountered while building the effective settings
[WARNING] 'servers.server.id' must be unique but found duplicate server with id jenkinsci-cert-snapshot @ /home/kohsuke/.m2/settings.xml
[WARNING]
[WARNING]
[WARNING] Some problems were encountered while building the effective settings
[WARNING] 'servers.server.id' must be unique but found duplicate server with id jenkinsci-cert-snapshot @ /home/kohsuke/.m2/settings.xml
[WARNING]
[INFO] Scanning for projects...
[INFO]
@kohsuke
kohsuke / release.log
Created August 6, 2019 04:51
2.188 stuck
% mvn test -Dtest=jenkins.triggers.TriggerTest
[WARNING]
[WARNING] Some problems were encountered while building the effective settings
[WARNING] 'servers.server.id' must be unique but found duplicate server with id jenkinsci-cert-snapshot @ /home/kohsuke/.m2/settings.xml
[WARNING]
[WARNING]
[WARNING] Some problems were encountered while building the effective settings
[WARNING] 'servers.server.id' must be unique but found duplicate server with id jenkinsci-cert-snapshot @ /home/kohsuke/.m2/settings.xml
[WARNING]
[INFO] Scanning for projects...
@kohsuke
kohsuke / diff.patch
Last active September 17, 2018 22:40
diff --git a/distribution/client/package-lock.json b/distribution/client/package-lock.json
index d6222a0..d45aeee 100644
--- a/distribution/client/package-lock.json
+++ b/distribution/client/package-lock.json
@@ -6756,27 +6756,11 @@
}
},
"original": {
- "version": "1.0.0",
- "resolved": "https://registry.npmjs.org/original/-/original-1.0.0.tgz",