This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh -e | |
# Usage: bpipe [-h|--html] | |
# Pipe stuff to the browser | |
if [ -t 0 ]; then | |
echo "Usage: echo '<h1>some stuff</h1>' | bpipe" | |
else | |
opt=`getopt -o h --long html -n bpipe -- "$@"` | |
eval set -- "$opt" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/perl | |
# Usage: httpme | |
# Serve static files from current working directory | |
use Cwd; | |
use Plack::Runner; | |
use Plack::App::Directory; | |
my $runner = Plack::Runner -> new; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include "Demo.h" | |
#include <StringView.h> | |
#include <Window.h> | |
Demo::Demo(void) : BApplication("application/x-vnd.Demo") { | |
BRect rect(150, 150, 500, 500); | |
BWindow *win = new BWindow( | |
rect, "Demo", | |
B_TITLED_WINDOW, |
NewerOlder