From c1235f8876113ceb64ae452fcb5ee7dbcf558c46 Mon Sep 17 00:00:00 2001 From: Lowl3v3l Date: Mon, 24 Apr 2017 01:36:27 +0200 Subject: [PATCH] Added the script and a minimal readme --- README.md | 4 ++++ status-script.rkt | 7 +++++++ 2 files changed, 11 insertions(+) create mode 100755 status-script.rkt diff --git a/README.md b/README.md index c4bb93b..16f22e4 100644 --- a/README.md +++ b/README.md @@ -1,2 +1,6 @@ # status-script a simple script in racket that reports on the room status ( without using the api itself) + +reports #t if the space is open and #f otherwise based on the image on the website. +to start it, have racket installed and either run racket status-script.rkt or chmod it +and run ./status-script.rkt diff --git a/status-script.rkt b/status-script.rkt new file mode 100755 index 0000000..ee9cba3 --- /dev/null +++ b/status-script.rkt @@ -0,0 +1,7 @@ +#! /usr/bin/racket +#lang racket + +(require net/url) + +(regexp-match? #rx"krautspace_pixelicon_open.png" + (port->string (get-pure-port (string->url "https://kraut.space/start"))))