Skip to content

Instantly share code, notes, and snippets.

View Perlmint's full-sized avatar
🤔

Gyusun Yeom Perlmint

🤔
View GitHub Profile
@Perlmint
Perlmint / breakpad_usage.cpp
Created December 15, 2020 02:18
Minimal breakpad example
#include <iostream>
#include <memory>
#if _WIN32
#pragma warning(push)
#pragma warning(disable : 4103)
#include "client/windows/handler/exception_handler.h"
#pragma warning(pop)
#elif __APPLE__
#include "client/mac/handler/exception_handler.h"
@Perlmint
Perlmint / .gitconfig
Created July 27, 2020 03:45
git alias for github
[alias]
fetch-pr = "!git fetch -fu ${2:-origin} refs/pull/$1/head:pr/$1;"
checkout-pr = "!git fetch-pr $1 ${2:-origin} && git checkout pr/$1; };"
clean-pr = "!git for-each-ref refs/heads/pr/* --format='%(refname)' | while read ref ; do branch=${ref#refs/heads/} ; git branch -D $branch ; done"
diff-pr = "!git fetch-pr $1 ${2:-orign} && git difftool --dir-diff $(git merge-base ${2:-origin}/master pr/$1) pr/$1;"
#define CHANGE_SCENE(update, init) {\
g_engine.next_update = &update;\
g_engine.next_init = &init;\
ReserveChangeScene(g_engine);\
}
CHANGE_SCENE(scene1_update, scene1_init);
@Perlmint
Perlmint / tslint-pre-commit-hook.sh
Last active June 28, 2017 07:15
tslint-pre-commit-hook.sh
#!/bin/bash
repo_root=$(git rev-parse --show-toplevel)
local_tslint=${repo_root}/node_modules/.bin/tslint
if [ -e $local_tslint ]; then
tslint_bin=$local_tslint
else
tslint_bin=tslint
fi
class IParam {
public:
virtual const std::string &url() = 0;
}
class UpdateStatusParam : public IParam {
public:
const std::string &url() {
static const std::string _url = "";
return _url;
장소 : 교604
예상소요시간 : 10분 이내
<이번주 수요일 - 23일>
15:30-15:50
<이번주 목요일 - 24일>
13:00-13:20 / 13:30-13:50 / 14:00-14:20 / 14:30-14:50 / 17:00-17:20 / 17:30-17:50
<이번주 금요일 - 25일>
13:00-13:20 / 13:30-13:50 / 14:00-14:20 / 14:30-14:50 / 15:00-15:20 / 15:30-15:50 /
16:00-16:20 / 16:30-16:50 / 17:00-17:20 / 17:30-17:50
@Perlmint
Perlmint / nginx_black_magic.conf
Created July 4, 2016 15:55
nginx black magic
server {
listen 80;
server_name ~^(?<port>\d+)\.dev\.my_domain$;
gzip_types text/plain text/css application/json application/x-javascript text/xml application/xml application/xml+rss text/javascript;
location / {
proxy_pass_header Server;
proxy_set_header Host $http_host;
proxy_set_header X-Real-IP $remote_addr;
@Perlmint
Perlmint / obj.cs
Created April 19, 2016 06:38
anonymous obj for test
var tests = new [] {
new { input = "hello", expected = "HELLO" },
new { input = "wtf", expected = "WTF"}
};
foreach (var testitem in tests)
{
assert(run_test(testitem.input) == testitem.expected);
}
@Perlmint
Perlmint / keybase.md
Last active March 3, 2016 06:54
keybase.md

Keybase proof

I hereby claim:

  • I am perlmint on github.
  • I am perlmint (https://keybase.io/perlmint) on keybase.
  • I have a public key whose fingerprint is BC7E FBBC 718F 5CAA F429 90A2 7DF3 F93E 1D07 52DD

To claim this, I am signing this object:

@Perlmint
Perlmint / suffix_update.py
Last active December 9, 2015 03:09
suffix_list
from sys import argv
from httplib import HTTPSConnection
contents = ''
if len(argv) < 3:
connection = HTTPSConnection('publicsuffix.org')
connection.request('GET', '/list/public_suffix_list.dat')
response = connection.getresponse()
contents = response.read().split('\n')
else: