Skip to content

Instantly share code, notes, and snippets.

Seong-Kook Shin cinsk

Block or report user

Report or block cinsk

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@cinsk
cinsk / keybase.md
Last active Feb 21, 2019
keybase identity proof
View keybase.md

Keybase proof

I hereby claim:

  • I am cinsk on github.
  • I am cinsk (https://keybase.io/cinsk) on keybase.
  • I have a public key whose fingerprint is 8B44 C9AA 2A3B E9E8 3A13 97B7 6A2B 450D 5B52 C175

To claim this, I am signing this object:

@cinsk
cinsk / Emacs.app.sh
Created Feb 22, 2018
How to create Dock Emacs/Aquamacs Icon reading bash init scripts and more
View Emacs.app.sh
# See https://www.emacswiki.org/emacs/EmacsForMacOS
#
# Create an app that runs a shell script that runs Emacs.app, like this:
# 1. use Finder to navigate to /Applications and double-click Automator.app.
# 2. Select the document type “Application” and click “Choose”.
# 3. In the list on the left, select “Library”.
# 4. In the next list, find “Run Shell Script” and drag it into the workflow area on the right.
# 5. In the new shell script, delete the text and replace it with:
EMACS=/Applications/Aquamacs.app/Contents/MacOS/Aquamacs
@cinsk
cinsk / java-flamegraph.sh
Created Jan 25, 2018
Generate flame graphs of JVM, JAVA
View java-flamegraph.sh
#!/bin/bash
# SJK tool need to run as the same user of the target process.
USER=
PID=
INTERVAL=10ms
PROGRAM_NAME=$(basename $0)
error() {
@cinsk
cinsk / diffjson
Created Aug 28, 2016
diffjson: compare JSON documents for the differences
View diffjson
#!/bin/bash
CONV_JSON=/tmp/convjson.$$
SRC1=/tmp/diffjson.1.$$.json
SRC2=/tmp/diffjson.2.$$.json
SRC3=/tmp/diffjson.3.$$.json
PROGRAM_NAME=$(basename $0)
VERSION_STRING="0.1"
PYTHON=
@cinsk
cinsk / private.xml
Created Feb 27, 2016
Karabiner Setting (For UK mac keyboard, IntelliJ settings..)
View private.xml
<?xml version="1.0"?>
<root>
<appdef>
<appname>IntelliJ IDEA</appname>
<equal>com.parallels.desktop.console</equal>
<equal>com.jetbrains.intellij.ce</equal>
</appdef>
<deviceproductdef>
<productname>APPLE_INTERNAL_KEYBOARD_TRACKPAD_0x0273</productname>
@cinsk
cinsk / check-nfs.sh
Last active Jul 8, 2019
Check if NFS mounted directory is stale
View check-nfs.sh
#!/bin/bash
PATH=/bin:/usr/bin:/usr/local/bin
check-nfs () {
local TMPFILE=/tmp/checknfs.$$ RET=0 ORPHAN SUBSHELLPID
if [ "$#" -eq 0 ]; then
cat<<EOF
usage: check-nfs NFS-DIRECTORY...
@cinsk
cinsk / chkprocs.rb
Last active Aug 29, 2015
Check the status of the processes (# of processes, # of fds, memory usage, etc.) in Nagios format
View chkprocs.rb
#!/usr/bin/env ruby
require 'timeout'
require 'getoptlong'
RLIMIT_MAP = {
"Max cpu time" => Process::RLIMIT_CPU,
"Max file size" => Process::RLIMIT_FSIZE,
"Max data size" => Process::RLIMIT_DATA,
"Max stack size" => Process::RLIMIT_STACK,
@cinsk
cinsk / reboot-abnormal
Last active Aug 29, 2015
force soft reboot Scalr-managed server if abnormal reboot detected
View reboot-abnormal
#!/bin/bash
#
# reboot-abnormal Force soft-reboot when Scalr event was not received
#
# chkconfig: 2345 80 10
# description: Force soft reboot when Scalr event was not received
#
# pidfile: /var/run/reboot-abnormal.pid
. /etc/rc.d/init.d/functions
@cinsk
cinsk / programming-in-scala.rb
Created Nov 1, 2013
Generate E-book friendly html files from http://www.artima.com/pins1ed/ See the comment in the source.
View programming-in-scala.rb
#!/usr/bin/env ruby
require 'rubygems'
require 'fileutils'
#
# Generate HTMLs for e-book from HTML files of "Programming in Scala".
#
# Usage:
@cinsk
cinsk / pom.xml
Created Oct 24, 2013
Maven project to embed GIT commit information into the output (.jar or .war) file
View pom.xml
<project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<dependencies>
<dependency>
<groupId>pl.project13.maven</groupId>
<artifactId>git-commit-id-plugin</artifactId>
<version>2.1.5</version>
</dependency>
You can’t perform that action at this time.