I hereby claim:
- I am grunka on github.
- I am grunka (https://keybase.io/grunka) on keybase.
- I have a public key whose fingerprint is 86C3 6799 927F 72C6 6CFC A7C8 5C87 DE42 CDE5 C52C
To claim this, I am signing this object:
I hereby claim:
To claim this, I am signing this object:
#!/usr/bin/env bash | |
submitted_jobs="" | |
submit() { | |
echo "> ${*}" > /tmp/job_XXX.log | |
eval "${*}" >> /tmp/job_XXX.log 2>&1 & | |
local id="${!}" | |
mv /tmp/job_XXX.log /tmp/job_${id}.log | |
if [[ -z "${submitted_jobs}" ]]; then |
#!/usr/bin/env bash | |
path_in_old_repo=some/sub/directory | |
old_repo=git@github.com:user/old_repo.git | |
new_repo=git@github.com:user/new_repo.git | |
new_directory=$(echo ${new_repo} | sed 's|^.*/\(.*\)\.git$|\1|g') | |
git clone ${old_repo} ${new_directory} | |
cd ${new_directory} | |
git remote set-url origin ${new_repo} | |
git filter-branch --subdirectory-filter ${path_in_old_repo} -- --all |
#!/usr/bin/env bash | |
set -euo pipefail | |
IFS=$'\n\t' |
from mitmproxy import http | |
def request(flow: http.HTTPFlow) -> None: | |
if "example.com/path/file.html" in flow.request.pretty_url: | |
with open('replacement.html', 'r') as myfile: | |
html = myfile.read().replace('\n', '') | |
flow.response = http.HTTPResponse.make( | |
200, # status code | |
html, # content | |
{"Content-Type": "text/html"} |
@ServerEndpoint("/socket-endpoint") | |
public class WebSocketImplementation { | |
@OnOpen | |
public void onOpen(Session session) throws IOException { | |
session.getBasicRemote().sendText("Hello World"); | |
} | |
@OnMessage | |
public void onMessage(Session session, String message) throws IOException { |
.PHONY: all clean run jar | |
JAR_NAME=Main.jar | |
MAIN_CLASS=Main | |
BIN_PATH=bin | |
LIB_PATH=lib | |
NOTHING= | |
SPACE=$(NOTHING) $(NOTHING) |
function check-cert-dates -d "Gets the start and end date for a SSL certificate on a domain" | |
echo "" | openssl s_client -servername $argv -connect $argv:443 2>/dev/null | openssl x509 -noout -dates | |
end |