by Ossi Hanhinen, @ohanhi
with the support of Futurice 💚.
Licensed under CC BY 4.0.
// bind whatever keybind you want | |
[ | |
{ | |
"command": "multiCommand.runRgFAndFocusTerminal", | |
"key": "cmd+k" | |
} | |
] |
from contextlib import contextmanager | |
from curses.ascii import isalpha | |
from dataclasses import dataclass | |
from pathlib import Path | |
import ast | |
import re | |
from typing import Any, Optional, Sequence, Set | |
@dataclass |
import time | |
import requests | |
base = "https://visualfractions.com/calculator/divisible-by/is-{}-divisible-by-{}/" | |
for x in range(1, 20): | |
print("Checking {} for fizzybuzziness".format(x)) | |
by3 = False | |
by5 = False | |
r = requests.get(base.format(x, 3)) |
diff --git a/io.c b/io.c | |
index 3707a69344..93b91e1450 100644 | |
--- a/io.c | |
+++ b/io.c | |
@@ -20,6 +20,7 @@ | |
#include <ctype.h> | |
#include <errno.h> | |
#include "ruby_atomic.h" | |
+#include <time.h> | |
NOTE: Easier way is the X86 way, described on https://www.genymotion.com/help/desktop/faq/#google-play-services | |
Download the following ZIPs: | |
ARM Translation Installer v1.1 (http://www.mirrorcreator.com/files/0ZIO8PME/Genymotion-ARM-Translation_v1.1.zip_links) | |
Download the correct GApps for your Android version: | |
Google Apps for Android 6.0 (https://www.androidfilehost.com/?fid=24052804347835438 - benzo-gapps-M-20151011-signed-chroma-r3.zip) | |
Google Apps for Android 5.1 (https://www.androidfilehost.com/?fid=96042739161891406 - gapps-L-4-21-15.zip) | |
Google Apps for Android 5.0 (https://www.androidfilehost.com/?fid=95784891001614559 - gapps-lp-20141109-signed.zip) |
# alias to edit commit messages without using rebase interactive | |
# example: git reword commithash message | |
reword = "!f() {\n GIT_SEQUENCE_EDITOR=\"sed -i 1s/^pick/reword/\" GIT_EDITOR=\"printf \\\"%s\\n\\\" \\\"$2\\\" >\" git rebase -i \"$1^\";\n git push -f;\n}; f" | |
# aliases to change a git repo from private to public, and public to private using gh-cli | |
alias gitpublic="gh repo edit --accept-visibility-change-consequences --visibility public" | |
alias gitprivate="gh repo edit --accept-visibility-change-consequences --visibility private" | |
# delete all your repos using gh-cli (please do not run this unless you want to delete all your repos) | |
gh repo list --limit 300 --json url -q '.[].url' | xargs -n1 gh repo delete --yes |
$ rails r 'File.write("./viz.html", Rails.application.routes.router.visualizer)' | |
$ ruby -r webrick -e "s = WEBrick::HTTPServer.new(:Port => 8080, :DocumentRoot => Dir.pwd); trap('INT') { s.shutdown }; s.start" | |
$ open "http://localhost:8080/viz.html" |
using System.Collections; | |
using System.Collections.Generic; | |
public class GameEvent | |
{ | |
} | |
public class Events | |
{ | |
static Events instanceInternal = null; |
# SSL self signed localhost for rails start to finish, no red warnings. | |
# 1) Create your private key (any password will do, we remove it below) | |
$ openssl genrsa -des3 -out server.orig.key 2048 | |
# 2) Remove the password | |
$ openssl rsa -in server.orig.key -out server.key |