Skip to content

Instantly share code, notes, and snippets.

View tushortz's full-sized avatar
❤️
One Love

Taiwo Kareem tushortz

❤️
One Love
View GitHub Profile
{
".3g2": "video/3gpp2",
".3gp": "video/3gpp",
".7z": "application/x-7z-compressed",
".aac": "audio/aac",
".abw": "application/x-abiword",
".afm": "application/x-font-type1",
".ai": "application/postscript",
".aiff": "audio/x-aiff",
".arc": "application/x-freearc",
@tushortz
tushortz / uk-text-scam-phone-numbers.txt
Last active November 1, 2022 01:05
A list of several UK phone numbers text scammers use to lure people
+44 7394 154795
+44 7521 216234
+44 7521 234316
+44 7521 243292
+44 7542 340061
+44 7542 344849
+44 7543 537016
+44 7568 457865
+44 7593 263277
+44 7725 416161
@tushortz
tushortz / countries_codes_and_coordinates.csv
Created April 21, 2021 06:32 — forked from tadast/countries_codes_and_coordinates.csv
Countries with their (ISO 3166-1) Alpha-2 code, Alpha-3 code, UN M49, average latitude and longitude coordinates
Country Alpha-2 code Alpha-3 code Numeric code Latitude (average) Longitude (average)
Afghanistan AF AFG 4 33 65
Albania AL ALB 8 41 20
Algeria DZ DZA 12 28 3
American Samoa AS ASM 16 -14.3333 -170
Andorra AD AND 20 42.5 1.6
Angola AO AGO 24 -12.5 18.5
Anguilla AI AIA 660 18.25 -63.1667
Antarctica AQ ATA 10 -90 0
Antigua and Barbuda AG ATG 28 17.05 -61.8
@tushortz
tushortz / parse_json_data_by_string.py
Created September 14, 2020 16:54
An attempt to parse json or python dict using just normal strings
# Author: Taiwo Kareem
# Attempt to parse dict by using string path
def str_data(paths, obj):
paths = paths.split(".")
for path in paths:
if path.isnumeric():
path = int(path)
obj = obj[path]
@tushortz
tushortz / git_shortcuts.sh
Last active September 13, 2019 11:07
useful git shortcuts
git config --global alias.aa "add --all"
git config --global alias.ai "add --interactive"
git config --global alias.b "branch --column"
git config --global alias.ba "branch -a"
git config --global alias.bd '!sh -c "git branch -D $@"'
git config --global alias.c "commit"
git config --global alias.ca "commit --amend"
git config --global alias.cf '!sh -c "git commit --fixup $@"'
git config --global alias.cm '!sh -c "git commit -m \"$@\""'
git config --global alias.co "checkout"
@tushortz
tushortz / font_installer.py
Created December 25, 2018 21:55
Python script to install multiple fonts at once on the Windows OS.
import os
import shutil
import ctypes
from ctypes import wintypes
import sys
import ntpath
try:
import winreg
except ImportError:
import _winreg as winreg
@tushortz
tushortz / python_members.py
Created December 9, 2018 05:58
Get all module members including signature
import inspect
import re
import importlib
def get_module_members(module, package=''):
imported = importlib.import_module(module)
module = str(module)
if package:
@tushortz
tushortz / mpeg_to_mp3_convert.ps1
Last active September 9, 2018 06:32
Powershell batch script to convert mpeg file to mp3
##############################
# Author: Taiwo Kareem
# 09/09/2018
# Script to convert between different audio file formats assuming ffmpeg exe is in Path environment variables
#########################
# HOW TO USE
# Create a new folder with the name of the old extension
# Place the new folder on your Desktop
# Change this next two lines for your preferred from and to format:
@tushortz
tushortz / install_windows_font.ps1
Last active March 21, 2019 22:01
This installs all the fonts placed in the "Desktop/fonts" directory of any windows pc
$FONTS = 0x14;
$CurrentWorkingDirectory = Get-Location;
Write-Output "Getting fonts from path: '$CurrentWorkingDirectory'";
$ObjShell = New-Object -ComObject Shell.Application;
$ObjFolder = $ObjShell.Namespace($FONTS);
$CopyOptions = 4 + 16;
@tushortz
tushortz / xsl.json
Last active July 6, 2018 12:48
visual studio code xslt snippet
{
// Place your snippets for xsl here. Each snippet is defined under a snippet name and has a prefix, body and
// description. The prefix is what is used to trigger the snippet and the body will be expanded and inserted. Possible variables are:
// $1, $2 for tab stops, $0 for the final cursor position, and ${1:label}, ${2:another} for placeholders. Placeholders with the
// same ids are connected.
// Example:
"xsl:apply-imports": {
"prefix": "xsl:apply-imports",
"body": [
"<xsl:apply-imports$1>"