Skip to content

Instantly share code, notes, and snippets.

Avatar
🏴

Donovan Keme digitalextremist

🏴
View GitHub Profile
View dismantler.cr
module Clarity
alias Value = Nil | String | Bool |
Int64 |
Int32 |
Float64 |
Array(Value) |
Hash(String, Value)
def self.dismantler(a)
View multi.rb
# Acts like an array and receives futures. Will yield them as
# they become ready.
class HackedMultiplexer
include Celluloid
include Enumerable
def initialize
@not_ready = []
end
@digitalextremist
digitalextremist / 0_reuse_code.js
Created May 26, 2016
Here are some things you can do with Gists in GistBox.
View 0_reuse_code.js
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console
@digitalextremist
digitalextremist / mocker.rb
Last active Aug 29, 2015
Mock Actor::System to simulate the arrival of running actors, for the Unlocker GSoC project.
View mocker.rb
require 'celluloid/current'
class Mocker
include Celluloid
MAX_INTERVAL = 20
MAX_WORK = 30
MAX_ID = 1000
attr_reader :id
def initialize(id)
@id = id
View cpu_count.rb
module System
extend self
def cpu_count
return Java::Java.lang.Runtime.getRuntime.availableProcessors if defined? Java::Java
return File.read('/proc/cpuinfo').scan(/^processor\s*:/).size if File.exist? '/proc/cpuinfo'
require 'win32ole'
WIN32OLE.connect("winmgmts://").ExecQuery("select * from Win32_ComputerSystem").NumberOfProcessors
rescue LoadError
Integer `sysctl -n hw.ncpu 2>/dev/null` rescue 1
end
@digitalextremist
digitalextremist / xorg.conf
Created May 24, 2015
Quatro Xorg configuration.
View xorg.conf
Section "ServerLayout"
Identifier "Quatro"
Screen 0 "Center" 1080 1080
Screen 1 "Left" 0 536
Screen 2 "Right" 3000 536
Screen 3 "Top" Above "Center"
InputDevice "Keyboard0" "CoreKeyboard"
InputDevice "Mouse0" "CorePointer"
Option "Xinerama" "1"
EndSection
View keybase.md

Keybase proof

I hereby claim:

  • I am digitalextremist on github.
  • I am digitalextremist (https://keybase.io/digitalextremist) on keybase.
  • I have a public key whose fingerprint is 1B6D 4015 1739 5A0B 42D8 5F58 DF18 5FF4 9474 35ED

To claim this, I am signing this object:

View hs_err_pid22136.log
#
# A fatal error has been detected by the Java Runtime Environment:
#
# SIGSEGV (0xb) at pc=0x00007fa0bfbc14c1, pid=22136, tid=140327325411072
#
# JRE version: Java(TM) SE Runtime Environment (8.0_25-b17) (build 1.8.0_25-b17)
# Java VM: Java HotSpot(TM) 64-Bit Server VM (25.25-b02 mixed mode linux-amd64 compressed oops)
# Problematic frame:
# V [libjvm.so+0x3e94c1] CallGenerator::for_method_handle_inline(JVMState*, ciMethod*, ciMethod*, bool&)+0x591
#
View hs_err_pid16804.log
#
# A fatal error has been detected by the Java Runtime Environment:
#
# SIGSEGV (0xb) at pc=0x00007f49cbaac4c1, pid=16804, tid=139954030249728
#
# JRE version: Java(TM) SE Runtime Environment (8.0_25-b17) (build 1.8.0_25-b17)
# Java VM: Java HotSpot(TM) 64-Bit Server VM (25.25-b02 mixed mode linux-amd64 compressed oops)
# Problematic frame:
# V [libjvm.so+0x3e94c1] CallGenerator::for_method_handle_inline(JVMState*, ciMethod*, ciMethod*, bool&)+0x591
#
View hs_err_pid19966.log
#
# A fatal error has been detected by the Java Runtime Environment:
#
# SIGSEGV (0xb) at pc=0x00007f425049b4c1, pid=19966, tid=139922265310976
#
# JRE version: Java(TM) SE Runtime Environment (8.0_25-b17) (build 1.8.0_25-b17)
# Java VM: Java HotSpot(TM) 64-Bit Server VM (25.25-b02 mixed mode linux-amd64 compressed oops)
# Problematic frame:
# V [libjvm.so+0x3e94c1] CallGenerator::for_method_handle_inline(JVMState*, ciMethod*, ciMethod*, bool&)+0x591
#