Skip to content

Instantly share code, notes, and snippets.

View ali's full-sized avatar

Ali Ukani ali

View GitHub Profile
@ali
ali / color-conversion-algorithms.js
Created August 16, 2018 13:39 — forked from mjackson/color-conversion-algorithms.js
RGB, HSV, and HSL color conversion algorithms in JavaScript
/**
* Converts an RGB color value to HSL. Conversion formula
* adapted from http://en.wikipedia.org/wiki/HSL_color_space.
* Assumes r, g, and b are contained in the set [0, 255] and
* returns h, s, and l in the set [0, 1].
*
* @param Number r The red color value
* @param Number g The green color value
* @param Number b The blue color value
* @return Array The HSL representation
@ali
ali / arch-linux-install
Created April 21, 2018 21:19 — forked from mattiaslundberg/arch-linux-install
Minimal instructions for installing arch linux on an UEFI system with full system encryption using dm-crypt and luks
# Install ARCH Linux with encrypted file-system and UEFI
# The official installation guide (https://wiki.archlinux.org/index.php/Installation_Guide) contains a more verbose description.
# Download the archiso image from https://www.archlinux.org/
# Copy to a usb-drive
dd if=archlinux.img of=/dev/sdX bs=16M && sync # on linux
# Boot from the usb. If the usb fails to boot, make sure that secure boot is disabled in the BIOS configuration.
# Set swedish keymap
@ali
ali / wut.coffee
Created December 18, 2012 03:25 — forked from anonymous/wut.coffee
Node.js demo app thing
###
# Learning some Node/Express/Coffeescript :>
###
http = require 'http'
nouns = [
'ali', 'pranav', 'wylie', 'spencer',
'dnb', 'cba', 'thang', 'DDS', 'leebot'
]