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: browser | |
# pipe html to a browser | |
# e.g. | |
# $ echo '<h1>hi mom!</h1>' | browser | |
# $ ron -5 man/rip.5.ron | browser | |
if [ -t 0 ]; then | |
if [ -n "$1" ]; then |
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
import org.sinatraLikeServlet.*; | |
public class MyApplication extends SinatraLikeHTTPServlet { | |
@get("/") | |
public void index(SinatraLikeHTTPServletRequest req | |
SinatraLikeHTTPServletResponse resp) { | |
MyResource[] resources = MyResource.findAll(); | |
req.setAttribute("resources", resources); | |
} |
NewerOlder