Skip to content

Instantly share code, notes, and snippets.

View lenaschoenburg's full-sized avatar

Lena Schönburg lenaschoenburg

View GitHub Profile
use bastion::prelude::*;
use futures_timer::Delay;
use std::{sync::Arc, time::Duration};
#[derive(Debug)]
struct Start(usize);
async fn run_producer(ctx: BastionContext) -> Result<(), ()> {
let runners = BroadcastTarget::Group("runners".into());
let mut i = 0;
DEBUG:rls::actions::post_build: reload analysis: "/Users/ok/Source/dignati/vips"
INFO:rls_analysis::raw: Considering Listing { kind: File(SystemTime { tv_sec: 1518630953, tv_nsec: 326278248 }), name: "libpeeking_take_while-95a4577d645e924c.json" }
INFO:rls_analysis::raw: reading "/Users/ok/Source/dignati/vips/target/rls/debug/deps/save-analysis/libpeeking_take_while-95a4577d645e924c.json" 0.000901099s
INFO:rls_analysis::raw: Considering Listing { kind: File(SystemTime { tv_sec: 1518630953, tv_nsec: 327935830 }), name: "libvoid-1c3e1cd9d083c4ad.json" }
INFO:rls_analysis::raw: reading "/Users/ok/Source/dignati/vips/target/rls/debug/deps/save-analysis/libvoid-1c3e1cd9d083c4ad.json" 0.000836162s
INFO:rls_analysis::raw: Considering Listing { kind: File(SystemTime { tv_sec: 1518630953, tv_nsec: 339670437 }), name: "libunicode_width-c7584cc23378018b.json" }
INFO:rls_analysis::raw: reading "/Users/ok/Source/dignati/vips/target/rls/debug/deps/save-analysis/libunicode_width-c7584cc23378018b.json" 0.000345206s
INFO:rls_
@lenaschoenburg
lenaschoenburg / Dockerfile
Last active February 13, 2018 15:25
Rust 0.1 Dockerfile
FROM debian:wheezy
RUN apt-get update
RUN apt-get install -y build-essential
RUN apt-get install -y git
RUN apt-get install -y curl
RUN apt-get install -y python
RUN git clone https://github.com/rust-lang/rust.git
WORKDIR rust
RUN git checkout tags/0.1
RUN sed -i -e "s,\http://dl.rust-lang.org,https://static.rust-lang.org," src/etc/snapshot.py
;;; Does not fail
(do (def conn (r/connect))
(Thread/sleep 4000)
(-> (r/db "test")
(r/config)
(r/run conn)))
;;; Fails
(do (def conn (r/connect))
(Thread/sleep 6000)
#![feature(lang_items, asm)]
#![crate_type = "staticlib"]
#![no_std]
const GPIO_BASE: u32 = 0x3F000000;
const GPIO_SET: u32 = 0x3F200020;
const GPIO_CLR: u32 = 0x3F20002C;
const GPIO47: u32 = 0x8000;
fn sleep(value: u32){
@lenaschoenburg
lenaschoenburg / interpreter.idr
Created March 15, 2015 12:34
Idris interpreter
module Interpreter
import Data.Vect
import Data.Fin
data Ty = TyInt | TyBool | TyFun Ty Ty
interpretTy : Ty -> Type
interpretTy TyInt = Int
interpretTy TyBool = Bool
interpretTy (TyFun A T) = interpretTy A -> interpretTy T

Keybase proof

I hereby claim:

  • I am dignati on github.
  • I am dignati (https://keybase.io/dignati) on keybase.
  • I have a public key ASBHhlj7E5Nu9-1JfvA3SSnnwm5hFYsZL_Zt6rI_66AliQo

To claim this, I am signing this object:

@lenaschoenburg
lenaschoenburg / README.md
Last active December 21, 2015 04:29 — forked from zpao/README.md

Install

  1. install homebrew
  2. place autoconf213.rb into Formula folder: /usr/local/Library/Formula/
  3. run brew install autoconf213
@lenaschoenburg
lenaschoenburg / bwt.clj
Created July 7, 2013 15:00
Burrows–Wheeler transformation.
(defn enhance [s]
(conj (into [\^] (vec s) )\|))
(defn rotate [c]
(vec (conj (drop-last c) (last c) )))
(defn pipe-and-save
"Given an item, it will recursivly apply fun n times. Gives back item plus each step in a coll"
([item n fun]
(pipe-and-save item n fun []))
@lenaschoenburg
lenaschoenburg / list.js
Created March 30, 2013 21:58
List out of Lambda, code from @stevelosh
// List
var empty_list = function(selector) {
return selector(undefined, undefined, true);
}
var is_empty = function(list){
return list(function (h, t, e) {
return e;
});
}
var prepend = function(el, list) {