Skip to content

Instantly share code, notes, and snippets.

View maziCodes's full-sized avatar
:octocat:
Churning codes...

Emeka Nwachukwu maziCodes

:octocat:
Churning codes...
View GitHub Profile
@chrisidakwo
chrisidakwo / nigerian-states.json
Last active April 26, 2024 22:55
All 36 states in Nigeria, and their local government areas - including the Federal Capital Territory and its area councils
{
"Abia": [
"Aba North",
"Aba South",
"Arochukwu",
"Bende",
"Ikwuano",
"Isiala-Ngwa North",
"Isiala-Ngwa South",
"Isuikwato",
@gaquino
gaquino / gist:87bdf0e6e852e445c0489379d3e9732a
Last active April 15, 2024 06:52
MacOS (xcrun: error: invalid active developer path (/Library/Developer/CommandLineTools))
If you are facing an error like that on new MacOS version.
xcrun: error: invalid active developer path (/Library/Developer/CommandLineTools), missing xcrun at: /Library/Developer/CommandLineTools/usr/bin/xcrun
It means that you need to install XCode command line, open a Terminal and run this command:
$ xcode-select --install
Note:
If you want to download and install Command Line tools manually, it can be downloaded from: https://developer.apple.com/download/more/
@itsTeknas
itsTeknas / number-to-words.pipe.ts
Created November 12, 2017 06:44
An Angular 4 pipe to convert a number to an equivalent words representation for Indian Rupees.
import { Pipe, PipeTransform } from '@angular/core';
@Pipe({
name: 'numberToWords'
})
export class NumberToWordsPipe implements PipeTransform {
a = [
'',
'one ',
@mofesolapaul
mofesolapaul / nigeria-states-and-local-govts.json
Last active April 10, 2024 05:11
Json array containing objects of each Nigerian state, and their local governments
[
{
"state": "Abia",
"lgas": [
"Aba North",
"Aba South",
"Arochukwu",
"Bende",
"Ikawuno",
"Ikwuano",
@andipaetzold
andipaetzold / dataURLToBlob.js
Created February 19, 2015 14:39
Data URL to Blob in JavaScript
// source: https://github.com/ebidel/filer.js/blob/b7ab6f4cbb82a17565ff68227e5bc984a9934038/src/filer.js#L137-159
var dataURLToBlob = function(dataURL)
{
var BASE64_MARKER = ";base64,";
if (dataURL.indexOf(BASE64_MARKER) == -1)
{
var parts = dataURL.split(",");
var contentType = parts[0].split(":")[1];
var raw = decodeURIComponent(parts[1]);