Skip to content

Instantly share code, notes, and snippets.

View noorus's full-sized avatar
⚜️
One hundred percent

Noora noorus

⚜️
One hundred percent
View GitHub Profile
# If not running interactively, don't do anything
case $- in
*i*) ;;
*) return;;
esac
umask 022
export LC_ALL=en_US.UTF-8
# don't put duplicate lines or lines starting with space in the history.
@noorus
noorus / create_iso.cpp
Created July 28, 2022 00:32 — forked from daaximus/create_iso.cpp
create iso using imapi
#include <string>
#include <atlbase.h>
#include <imapi2fs.h>
void create_iso( std::wstring_view src, std::wstring_view iso_path )
{
HRESULT hr;
IFileSystemImage* fsimg;
IFsiDirectoryItem* fsdir;
IFileSystemImageResult* fsresult;
@noorus
noorus / parser.js
Created July 25, 2020 17:55
parser.js
'use strict'
const sprintf = require( 'sprintf-js' ).sprintf
const moment = require( 'moment' )
const unicode_generalCategory = require( 'unicode-13.0.0/General_Category' )
const charCategoryMultipliers = [
0, // none
1, // latin letters
@noorus
noorus / nm_vec4f.hpp
Last active September 24, 2018 10:49
AVX-256 vec4 (Haswell/Excavator or newer)
#pragma once
#include <cstdint>
#include <intrin.h>
#define nmath_avx_align __declspec(align(32))
namespace nmath {
using Real = double; // tmp
// for license see license.txt
/* Netcat 1.00 951010
A damn useful little "backend" utility begun 950915 or thereabouts,
as *Hobbit*'s first real stab at some sockets programming. Something that
should have and indeed may have existed ten years ago, but never became a
standard Unix utility. IMHO, "nc" could take its place right next to cat,
cp, rm, mv, dd, ls, and all those other cryptic and Unix-like things.
@noorus
noorus / techtree.json
Last active October 21, 2017 21:22
StarCraft II Legacy of the Void v3.19.1.58600 Multiplayer
{
"protoss" :
{
"Gateway" :
{
"builds" :
[
{
"ability" : "GatewayTrain",
"abilityCommand" : "Train1",
#!/bin/sh
sudo updatedb
locate "node_modules/babelcli"
locate "node_modules/cross-env.js"
locate "node_modules/crossenv"
locate "node_modules/d3.js"
locate "node_modules/fabric-js"
locate "node_modules/ffmepg"
locate "node_modules/gruntcli"
locate "node_modules/http-proxy.js"
@noorus
noorus / photoutil.js
Created June 4, 2016 00:51
old photoutils backup
var shelly = require( "shelly" );
var childProcess = require( "child_process" );
var typist = require( "typist" );
var moment = require( "moment" );
var gm = require( "gm" );
var Q = require( "q" );
var im = gm.subClass({ imageMagick: true });
module.exports = {
@noorus
noorus / fixperms.sh
Last active December 11, 2015 15:28
convert users on a linux system to use shared group "staff"
#!/bin/bash
sed -i 's/umask .*/umask 002/g' /etc/skel/.bashrc
for dir in /home/*
do
sed -i 's/umask .*/umask 002/g' ${dir}/.bashrc
usr=${dir##*/}
adduser $usr staff
usermod -g staff $usr
done
@noorus
noorus / .bashrc
Last active October 9, 2015 10:27
bashrc
umask 022
export LC_ALL=en_US.UTF-8
[ -z "$PS1" ] && return
HISTCONTROL=ignoreboth
shopt -s histappend
shopt -s checkwinsize
GIT_PS1_SHOWDIRTYSTATE=1