Skip to content

Instantly share code, notes, and snippets.

View william-lohan's full-sized avatar

Mina Lohan william-lohan

View GitHub Profile
@william-lohan
william-lohan / out.xtx
Created August 31, 2023 17:57
blender core dump
PID: 1148 (blender)
UID: 1000 (mina)
GID: 1000 (mina)
Signal: 11 (SEGV)
Timestamp: Thu 2023-08-31 10:52:09 PDT (3min 55s ago)
Command Line: blender
Executable: /usr/bin/blender
Control Group: /user.slice/user-1000.slice/user@1000.service/app.slice/app-org.kde.konsole-39387e4f2484483b9ce154f44a2a00dd.scope
Unit: user@1000.service
User Unit: app-org.kde.konsole-39387e4f2484483b9ce154f44a2a00dd.scope
@william-lohan
william-lohan / index.js
Created November 16, 2022 23:44
Unholy abomination
const fs = require('fs');
const MOV_AH = 0xb4;
const MOV_BH = 0xb7;
const MOV_BL = 0xb3;
const MOV_AL = 0xb0;
const INT = 0xcd;
const JMP = 0xeb;
@william-lohan
william-lohan / observable-from-axios.js
Created April 26, 2021 06:23
wraps axios request in cancellable observable
import { Observable, from } from 'rxjs';
import { CancelToken, AxiosResponse } from "axios";
/**
* @callback AxiosFn
* @param {CancelToken} cancelToken
* @returns {Promise<AxiosResponse>}
*/
/**
const http = require('http');
const fs = require('fs');
const os = require('os');
const sourceUrl = 'http://pages.cs.wisc.edu/~ballard/bofh/excuses';
const dataFile = `${process.env.APPDATA}\\fun-data`;
function download() {
return new Promise((resolve, reject) => {
id first_name last_name email gender ip_address
1 Adah Varfalameev avarfalameev0@ning.com Female 12.129.233.17
2 Bartlett Rough brough1@icq.com Male 44.68.41.164
3 Dietrich Apperley dapperley2@omniture.com Male 251.58.153.18
4 Hope Lightbowne hlightbowne3@yellowbook.com Female 136.210.51.78
5 Leshia MacKenny lmackenny4@nationalgeographic.com Female 78.5.177.5
6 Smith Oakenfall soakenfall5@livejournal.com Male 234.74.183.153
7 Dana Melton dmelton6@dailymotion.com Female 118.71.240.41
8 Robby Caldroni rcaldroni7@huffingtonpost.com Female 145.151.222.194
9 Bryn Ludovico bludovico8@blogtalkradio.com Female 87.219.7.110
@william-lohan
william-lohan / tap-index.ts
Created August 19, 2019 23:27
tapIndex rxjs operator
class TapIndexSubscriber<T> extends Subscriber<T> {
private count: number = 0;
constructor(
protected destination: Subscriber<T>,
private nextEmit: (value: T, index: number) => void
) {
super(destination);
@william-lohan
william-lohan / .angular-cli.json
Last active December 6, 2017 00:58
platform-electron
{
"$schema": "./node_modules/@angular/cli/lib/config/schema.json",
"apps": [
{
"name": "electron",
"root": "src",
"outDir": "dist/electron/",
"assets": [
"assets",
"favicon.ico"
@william-lohan
william-lohan / dialog.js
Last active January 18, 2017 00:33
angularlink
CKEDITOR.dialog.add('routerLinkDialog', function (editor) {
return {
// Basic properties of the dialog window: title, minimum size.
title: 'Router Link Properties',
minWidth: 200,
minHeight: 100,
// Dialog window content definition.
contents: [
{
// Definition of the Basic Settings dialog tab (page).
import { Component, OnInit, ElementRef } from '@angular/core';
@Component({
template: `
<!-- native element reference -->
<div id="source0"
style="background-color: red; height: 20px;"
draggable="true">
</div>
@william-lohan
william-lohan / Rio.d.ts
Created October 4, 2016 16:40
PrimeNG Rio TypeScript definition
interface RioStatic {
init(): void;
bindEvents(): void;
isMobile(): boolean;
initRipple(): void;
}
/**
* PrimeNG Rio Layout