I hereby claim:
- I am michaelneu on github.
- I am michaelneu (https://keybase.io/michaelneu) on keybase.
- I have a public key ASCCx7GrQCMSwOCudZ16kqcvRs3YXa_DYbBMSgFfTTk35Ao
To claim this, I am signing this object:
import javafx.application.Platform; | |
/** | |
* A simple replacement for the C# BackgroundWorker-class for JavaFX | |
* @author minedev | |
*/ | |
public abstract class BackgroundWorker { | |
private Thread thread; | |
private boolean workerStarted; | |
import { Observable } from "rxjs/Observable"; | |
import { Observer } from "rxjs/Observer"; | |
import "rxjs/add/operator/debounceTime"; | |
/** | |
* Class representing a debouncer to delay incoming events. | |
*/ | |
export default class Debouncer<T> { | |
private observer: Observer<T>; |
I hereby claim:
To claim this, I am signing this object:
// step 1: create your mail | |
final Mail mail = new Mail(); | |
// step 2: add your credentials | |
final User user = new User(); | |
user.setEmail("barb@gorillamail.space"); | |
user.setPassword("p4ssword!"); | |
// step 3: set your template | |
final Template template = new Template(); |
#!/usr/bin/env python2 | |
import sys | |
import os | |
def call_acpi(command): | |
with open('/proc/acpi/call', 'w') as acpi_call: | |
acpi_call.write(command) | |
# Response |
#!/usr/bin/python2 | |
def set_speed(pwm, speed): | |
speed = max(0, min(100, speed)) | |
speed = 2.55 * speed | |
speed = int(speed) | |
with open("/sys/class/hwmon/hwmon1/pwm" + str(pwm), "w") as f: | |
f.write(str(speed)) |
#!/usr/bin/env python3 | |
import urllib.request | |
import os | |
import re | |
import sys | |
from concurrent.futures import ProcessPoolExecutor as PoolExecutor, as_completed | |
from PIL import Image | |
image_page_link_pattern = re.compile(r"src=\"https:\/\/thumbs\.dreamstime\.com\/t\/([^\"]+)") |
import { useState } from "react"; | |
export const useDragAndDrop = <T extends HTMLElement>() => { | |
const [isDragging, setIsDragging] = useState(false); | |
const [innerOffsetX, setInnerOffsetX] = useState(0); | |
const [innerOffsetY, setInnerOffsetY] = useState(0); | |
const start = (event: React.MouseEvent<T, MouseEvent>) => { | |
const element = event.target as T; | |
const { left, top } = element.getBoundingClientRect(); |
stage('Build') { | |
node (label: 'linux') { | |
checkout scm | |
docker.image('node:alpine').inside { | |
sh 'yarn install' | |
sh 'yarn build' | |
} | |
} | |
} |