Skip to content

Instantly share code, notes, and snippets.


Kensuke Nagae kyanny

View GitHub Profile
shanselman / gist:5422230
Last active Jul 24, 2021
Evil Blog Comment Spammer just exposed his template through some error and the whole thing showed up in my comments.
View gist:5422230
{I have|I've} been {surfing|browsing} online more than {three|3|2|4} hours today, yet I never found any interesting article like yours. {It's|It
is} pretty worth enough for me. {In my opinion|Personally|In my view}, if all {webmasters|site owners|website owners|web owners} and bloggers made good content as
you did, the {internet|net|web} will be {much more|a lot more}
useful than ever before.|
I {couldn't|could not} {resist|refrain from} commenting. {Very well|Perfectly|Well|Exceptionally well} written!|
{I will|I'll} {right away|immediately} {take hold of|grab|clutch|grasp|seize|snatch}
your {rss|rss feed} as I {can not|can't} {in finding|find|to find} your {email|e-mail} subscription {link|hyperlink} or {newsletter|e-newsletter} service. Do {you have|you've} any?
{Please|Kindly} {allow|permit|let} me {realize|recognize|understand|recognise|know} {so that|in order that} I {may just|may|could} subscribe.
View capybara cheat sheet
=Clicking links and buttons=
click_link('Link Text')
click('Link Text') # Click either a link or a button
click('Button Value')
kconragan /
Last active Jul 18, 2021
Enable key repeat in Apple Lion for Sublime Text in Vim mode
# Mac OS X Lion introduced a new, iOS-like context menu when you press and hold a key
# that enables you to choose a character from a menu of options. If you are on Lion
# try it by pressing and holding down 'e' in any app that uses the default NSTextField
# for input.
# It's a nice feature and continues the blending of Mac OS X and iOS features. However,
# it's a nightmare to deal with in Sublime Text if you're running Vintage (Vim) mode,
# as it means you cannot press and hold h/j/k/l to move through your file. You have
# to repeatedly press the keys to navigate.
kawsark /
Created Mar 28, 2019
A guide for configuring Vault's SSH-CA

SSH CA use-case with Vault

In this scenario we are going to set up Vault to sign SSH keys using an internal CA. We will configure the SSH secrets engine and create a CA within Vault. We will then configure an SSH server to trust the CA key we just created. Finally we will attempt to SSH using a private key, and a public key signed by Vault SSH CA.


  • This guide assumes you have already provisioned a Vault server, SSH host using OpenSSH server, and a SSH client machine.
  • The client system must be able to reach the Vault server and the OpenSSH server.
  • We will refer to these systems respectively as:
View ghe-revealer.rb
#!/usr/bin/sudo ruby
# revealer.rb -- Deobfuscate GHE .rb files.
# This is simple:
# Every obfuscated file in the GHE VM contains the following code:
# > require ""
# > __ruby_concealer__ "..."
imaya / gist:7938720
Created Dec 13, 2013
View gist:7938720


この記事は退職 Advent Calendar 13 日目の記事です。 本日が最終出社となりましたので、入社から退社までを振り返り整理しようと思い、この文章を書いています。


自分語りなので興味ない人はさっさと戻ったほうが良いです。 簡単にまとめると、元々あまり執着ないしやることない、なんか最近クソみたいな社内ポリシーがいっぱい出来て萎える、話の合う人がやめることにしたから会社にいる意味を感じないため辞めるということです。

edgimar / copy-org-mode-link.js
Last active Mar 22, 2021
User-script to copy the currently browsed web-page and selected content to the clipboard for pasting into org-mode
View copy-org-mode-link.js
View alert.js
alert('hello ' + document.location.href);
doi-t / setting_default_value.bash
Last active Feb 7, 2021
View setting_default_value.bash
echo $foo #$1がなかったらhogeをデフォルト値としてfooに代入する
${var:=hoge} #このままでは、hogeが展開されてしまって、hogeなんてコマンドはないとシェル怒られる
echo "1:$var"