Skip to content

Instantly share code, notes, and snippets.

View azenla's full-sized avatar
🏳️‍⚧️
cabbit mode

Alex Zenla azenla

🏳️‍⚧️
cabbit mode
View GitHub Profile
@azenla
azenla / tests.dql
Last active February 3, 2016 19:26
invoke /downstream/System/execute with {
command: "ls /"
}
@azenla
azenla / powerball.txt
Created January 13, 2016 05:56
I generated 20k random powerballs using a script somebody posted for Dart. Will the winning one be in here?
(16) (17) (19) (33) (53) ((4))
(5) (16) (23) (54) (59) ((7))
(31) (42) (46) (50) (58) ((2))
(10) (41) (51) (64) (65) ((2))
(31) (43) (46) (51) (52) ((8))
(30) (42) (50) (57) (58) ((12))
(3) (31) (34) (56) (66) ((4))
(26) (43) (48) (61) (63) ((11))
(17) (24) (27) (49) (58) ((11))
(10) (16) (44) (49) (56) ((20))
library dslink.historian;
import "package:dslink/dslink.dart";
import "package:dslink/nodes.dart";
import "package:dslink/utils.dart";
import "dart:async";
import "dart:math";
const Map<dynamic, int> INTERVAL_TYPES = const {
"@type": group
Group:
"@type": group
width: 100%
height: 100%
clipContent: true
scaleContent: none
layout: absolute
creationPolicy: onDisplay
symbol: MovingCircle
import "dart:async";
import "dart:io";
import "dart:convert";
main(List<String> args) async {
if (args.isEmpty) {
args = ["--server"];
}
if (args[0] == "--server") {
import "dart:async";
import "dart:io";
import "dart:convert";
main(List<String> args) async {
if (args.isEmpty) {
args = ["--server"];
}
if (args[0] == "--server") {
type Socket {
property host: String
property port: Integer
emits @connected: Socket
emits @data: any
constructor(self.host, self.port)
function connect() -> void {
@connected <- self
let names = [
"Alex"
"Sam"
"Logan"
]
let ages = [
16
18
16
@azenla
azenla / Dockerfile
Last active December 8, 2015 02:52
FROM google/dart:latest
WORKDIR /app
RUN \
echo "deb http://ppa.launchpad.net/webupd8team/java/ubuntu trusty main" | tee /etc/apt/sources.list.d/webupd8team-java.list && \
echo "deb-src http://ppa.launchpad.net/webupd8team/java/ubuntu trusty main" | tee -a /etc/apt/sources.list.d/webupd8team-java.list && \
apt-key adv --keyserver keyserver.ubuntu.com --recv-keys EEA14886 && \
apt-get update && \
\
\
{
"$is": "channel",
"sendMessage": {
"$invokable": "write",
"$params": [
{
"name": "message",
"type": "string"
}
]