Skip to content

Instantly share code, notes, and snippets.

@duebbert
duebbert / README.md
Created May 30, 2020 06:17
ultradefrag on Debian Testing (x64)
@duebbert
duebbert / git.bat
Created July 12, 2017 08:27
git batch file for using with Bash on Ubuntu on Windows
@echo off
SETLOCAL enableextensions enabledelayedexpansion
:: Thanks:
:: - https://stackoverflow.com/questions/37000166/getting-pycharm-to-recognize-python-on-the-windows-linux-subsystem-bash-on-wind
:: ###################################################################################
:: Set up the current directory, so that we can change into it before calling git
:: ###################################################################################
@duebbert
duebbert / msysgit2unix-socket.py
Last active April 30, 2020 13:15 — forked from kevinvalk/msysgit2unix-socket.py
Updated to better survive crashes and other unexpected behavior.
#!/usr/bin/python3
"""
msysGit to Unix socket proxy
============================
This small script is intended to help use msysGit sockets with the new Windows Linux Subsystem (aka Bash for Windows).
It was specifically designed to pass SSH keys from the KeeAgent module of KeePass secret management application to the
ssh utility running in the WSL (it only works with Linux sockets). However, my guess is that it will have uses for other
@duebbert
duebbert / ssh_ubuntu_windows.md
Last active September 3, 2019 15:18
Configuring PyCharm, Bash on Ubuntu on Windows 10 & WinSCP to work with SSH keys in Keepass using the KeeAgent Plugin

Configuring PyCharm, Bash on Ubuntu on Windows 10 & WinSCP to work with SSH keys in Keepass using the KeeAgent Plugin

Description

This is a small guide on how to set up PyCharm, Bash on Ubuntu on Windows & WinSCP on Windows to use SSH keys which are saved in KeePass. This significantly improves the user experience while keeping the keys save. It also alleviates any issues with Cygwin which prompted me to set this all up (see setup with Babun before https://gist.github.com/duebbert/1cd30115cf8ade37aa5b619080154e85)

Installation

@duebbert
duebbert / pycharm_babun.md
Last active October 11, 2017 13:07
Configuring PyCharm & Babun to work with SSH keys in Keepass using the KeeAgent Plugin

Configuring PyCharm, Babun & WinSCP to work with SSH keys in Keepass using the KeeAgent Plugin

Description

This is a small guide on how to set up PyCharm, Babun & WinSCP on Windows to use SSH Keys which are saved in KeePass. This significantly improves the user experience while keeping the keys save.

Installation

@duebbert
duebbert / nginx.conf
Created November 16, 2015 08:21
NGINX config to first check a server, e.g. webpack-dev-server, if it's down then local files.
server {
[... normal configs]
# Try webpack server first, if error 502 then go try files
location ~ ^/.+/static/js/.+\.js$ {
proxy_pass http://127.0.0.1:8080;
proxy_set_header X-Forwarded-Host 127.0.0.1:8080;
error_page 502 = @localjs;
}