Skip to content

Instantly share code, notes, and snippets.

i continue to work. the city sleeps.

Erin Moon barzamin

i continue to work. the city sleeps.
Block or report user

Report or block barzamin

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
use regex::{Regex, RegexBuilder};
static CTRL_CHARS: &str = r"\x00-\x1F\x7F";
static INVALID_CHARS: &str = "\u{FFFE}\u{FEFF}\u{FFFF}\u{202A}-\u{202E}";
static UNICODE_SPACES: &str = "\u{09}-\u{0D}\u{20}\u{85}\u{A0}\u{1680}\u{180E}\u{2000}-\u{200A}\u{2028}\u{2029}\u{202F}\u{205F}\u{3000}";
static LATIN_ACCENTS: &str = "\u{00C0}-\u{00D6}\u{00D8}-\u{00F6}\u{00F8}-\u{00FF}\u{0100}-\u{024F}\u{0253}-\u{0254}\
static PUNCTUATION: &str = r##"-_!"#$%&'()*+,./:;<=>?@\[\]^`{|}~"##;

Keybase proof

I hereby claim:

  • I am barzamin on github.
  • I am er1n ( on keybase.
  • I have a public key ASBGM6pIaiBnGcv7QvY5gqnhIf9cqGJm7oJUKx8ug82D5wo

To claim this, I am signing this object:

View dev.js
/// thanks to
webpackJsonp([0],[function(n,b,d){mArr=d.m,mCac=d.c,mCar=[],Object.keys(mCac).forEach(function(n){mCar[n]=mCac[n]}),findFunc=function(n){if(results=[],"string"==typeof n)mArr.forEach(function(r,t){-1!==r.toString().indexOf(n)&&results.push(mCac[t])});else{if("function"!=typeof n)throw new TypeError("findFunc can only find via string and function, "+typeof n+" was passed");modArray.forEach(function(r,e){n(r)&&results.push(t.c[e])})}return results},findCache=function(n){if(results=[],"function"==typeof n)mCar.forEach(function(r,t){n(r)&&results.push(r)});else{if("string"!=typeof n)throw new TypeError("findCache can only find via function or string, "+typeof n+" was passed");mCar.forEach(function(r,t){if("object"==typeof r.exports)for(p in r.exports)if(p==n&&results.push(r),"default"==p&&"object"==typeof r.exports["default"])for(p in r.exports["default"])p==n&&results.push(r)})}return results},window.wc={get:d,modArr:mArr,modCache:mCac,modCArr:mCar,findFunc:findFunc,find
View gist:9a819a393911e78612d2ee4236361456
vec4 viridis(float x) {
const float e0 = 0.0;
const vec4 v0 = vec4(0.26666666666666666,0.00392156862745098,0.32941176470588235,1);
const float e1 = 0.13;
const vec4 v1 = vec4(0.2784313725490196,0.17254901960784313,0.47843137254901963,1);
const float e2 = 0.25;
const vec4 v2 = vec4(0.23137254901960785,0.3176470588235294,0.5450980392156862,1);
const float e3 = 0.38;
const vec4 v3 = vec4(0.17254901960784313,0.44313725490196076,0.5568627450980392,1);
const float e4 = 0.5;
use arch::x86_64::ports::Port;
use core::fmt;
use spin::RwLock;
lazy_static! {
pub static ref COM1: RwLock<SerialPort> = RwLock::new(SerialPort::new(0x3f8));
pub struct SerialPort {
data_port: Port<u8>,
View colormaps.glsl
/// a collection of cool colormaps in glsl
/// most work on [0, 1].
/// Lovingly ripped off from:
/// * halcy
// WAHas Spectrum analyzer palette
// ripped off from
barzamin /
Created Jun 5, 2017
Discord auth blueprint for Flask
from requests_oauthlib import OAuth2Session
from flask import Blueprint, request, redirect, abort, flash, url_for, session
from flask_login import login_user, logout_user, login_required
from www import app, db, login_manager
from .models import User
from .utils import is_safe_redirect
import requests
import os
import sys
import random
import string

this is going to be a review of the current genesis demo build by erin/barzamin/The Refactor Godess/The Really Annoying Nitpicker

ok lets boot it up bluh

wine Genesis.exe

cool it runs ok under wine

let's do "good" graphics quality, and make it windowed

barzamin /
Last active Aug 15, 2016
Processinglang/Java computational geometry utils
import megamu.mesh.*;
static class GeomUtils {
static PVector centroid(MPolygon polygon) {
return centroid(toVectorArray(polygon.getCoords()));
static PVector centroid(PVector[] polygon) {
int l = polygon.length;
float a = signedArea(polygon);
You can’t perform that action at this time.