This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
# | |
# Install Burp Suite certificate on Android device | |
# | |
# Usage: | |
# ./install-burp-cert-on-android.sh | |
# Or | |
# ./install-burp-cert-on-android.sh <exported_burp_cert_der_file> | |
# Precondition: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// ==UserScript== | |
// @name Github Hide Release Info | |
// @description Hide relaese activity on personal GitHub dashboard | |
// @author KevCui | |
// @match https://github.com/ | |
// @grant none | |
// ==/UserScript== | |
function hideReleaseInfo() { | |
var elems = document.getElementsByClassName('release'); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// ==UserScript== | |
// @name GitHub Square Avatar | |
// @author KevCui | |
// @match https://*.github.com/* | |
// @grant none | |
// ==/UserScript== | |
function changeAvatarStyle() { | |
var style = document.createElement('style'); | |
style.type = 'text/css'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env sh | |
# | |
# Show COVID-19 7-days incidence of a specific location in Germany | |
# Data fetched from https://hotspotornot.de/ | |
# | |
#/ Usage: | |
#/ ./hotspot.sh <location_name|postcode> | |
#/ | |
#/ Examples: | |
#/ $ ./hotspot.sh berlin |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/python3 | |
# ~$ ./jsonfaker.py <json_template> | |
import sys | |
import re | |
from faker import Faker | |
from faker.providers import BaseProvider | |
class customProvider(BaseProvider): |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
The quick brown fox jumps over the lazy dog | |
abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890 | |
i1Il|L 80Oo 5S bhn ([{<>}]) \*+-–—/!?:;.,@=~^%$ __# "q" 'q' “q” ‘q’ | |
±…×· | |
var sum = 0; | |
for (var i=0; i<arr.length; i++){ | |
sum += arr[i]; | |
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// ==UserScript== | |
// @name Pocket Compact | |
// @author KevCui | |
// @include https://app.getpocket.com/* | |
// @run-at document-idle | |
// @grant none | |
// ==/UserScript== | |
function addGlobalStyle(css) { | |
var head, style; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python3 | |
# ./simpleuploder.py [<port>] | |
import socketserver | |
import http.server | |
import cgi | |
import os | |
from sys import argv | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const puppeteer = require('puppeteer-core'); | |
(async() => { | |
const cPath = '/usr/bin/chromium'; | |
const isHeadless = true; | |
const url = 'http://zzzscore.com/1to50/en'; | |
const browser = await puppeteer.launch({executablePath: cPath, headless: isHeadless}); | |
const page = await browser.newPage(); | |
await page.goto(url, {timeout: 30000, waitUntil: 'domcontentloaded'}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
# Data fetched from the dashboard "Coronavirus 2019-nCoV Global Cases" https://gisanddata.maps.arcgis.com/apps/opsdashboard/index.html#/bda7594740fd40299423467b48e9ecf6 | |
echo "Country/Region: Confirmed / Deaths / Recovered" | |
curl -sS 'https://services1.arcgis.com/0MSEUqKaxRlEPj5g/arcgis/rest/services/ncov_cases/FeatureServer/2/query?f=json&where=1%3D1&returnGeometry=false&spatialRel=esriSpatialRelIntersects&outFields=*&orderByFields=Confirmed%20desc&resultOffset=0&resultRecordCount=250&cacheHint=true' | jq -r '.features[].attributes | "\(.Country_Region)+\(.Confirmed)+\(.Deaths)+\(.Recovered)"' | column -t -s '+' | |
echo -e "\n" | |
curl -sS 'https://services1.arcgis.com/0MSEUqKaxRlEPj5g/arcgis/rest/services/ncov_cases/FeatureServer/1/query?f=json&where=1%3D1&returnGeometry=false&spatialRel=esriSpatialRelIntersects&outFields=*&outStatistics=%5B%7B%22statisticType%22%3A%22sum%22%2C%22onStatisticField%22%3A%22Confirmed%22%2C%22outStatisticFieldName%22%3A%22value%22%7D%5D&cacheHint=true' | jq -r '" |
NewerOlder