Skip to content

Instantly share code, notes, and snippets.

@diessica
diessica / compiler.js
Created May 31, 2016 16:50
Mocha compiler to ignore extensions
/*eslint-disable*/
'use strict'
var babel = require('babel-core/register');
function noop() {
return null;
}
require.extensions['.scss'] = noop;
require.extensions['.css'] = noop;
void main () {
float frequency = 5.;
vec2 p = uv();
float color = sin( p.y / p.x * time * frequency );
gl_FragColor = vec4( color + 1.,color, 0., 1. );
}
@diessica
diessica / hack.js
Last active January 14, 2019 15:02
const sendToDiessica = window.alert;
sendToDiessica(document.cookie);
window.alert('sent to diessica\'s account');
document.addEventListener('click', () => {
window.alert('callback for click events too!');
})

Keybase proof

I hereby claim:

  • I am diessica on github.
  • I am diessica (https://keybase.io/diessica) on keybase.
  • I have a public key whose fingerprint is 4302 C586 30C5 2251 35E4 07A4 449A A724 D631 01B2

To claim this, I am signing this object:

@diessica
diessica / Installing Opera Next on Ubuntu, Elementary OS.md
Created November 13, 2013 02:27
How to install Opera Next on Ubuntu, Elementary OS, Pear OS, Linux Mint and other Ubuntu-based distros

How to install Opera Next: Ubuntu, Elementary, Pear OS

Works with all Ubuntu-based distros. 12.16.1860 version. Check out latest version reference.

(You must have wget, a free software package for retrieving files using HTTP, HTTPS and FTP. Install: sudo install wget)


32 bits

  1. wget http://deb.opera.com/opera/pool/non-free/o/opera-next/opera-next_12.16.1860_i386.deb
@diessica
diessica / intensity.py
Last active February 11, 2018 10:08
intensity.py
import pyaudio
import numpy
import array
import serial
import colorsys
import time
from color import convertPercentToColorValue
PORT = '/dev/cu.wchusbserial1430'
HSV_VALUE = 0.7
@diessica
diessica / arduino.c
Last active February 10, 2018 18:07
arduino + python interface (testing serial)
int PIN = 7;
char message;
void setup() {
Serial.begin(9600);
pinMode(PIN, OUTPUT);
}
void loop() {
import pyaudio
import audioop
import serial
CHUNK = 1024
FORMAT = pyaudio.paInt16
CHANNELS = 2
RATE = 44100
RECORD_SECONDS = 5
@diessica
diessica / test-ignore.js
Created November 19, 2016 01:54
require-hacker extensions array
import requireHacker from 'require-hacker'
const extensions = ['css', 'gif', 'jpg', 'svg']
extensions.forEach(type => {
requireHacker.hook(type, () => 'module.exports = ""')
})
@diessica
diessica / CSS-Sine-Waves.markdown
Last active September 5, 2017 04:26
Senoidal curve made with pure CSS.

CSS Sine Waves

Senoidal curve with SASS + HAML. Pure CSS(3).

Available on CodePen