This is a simple program that watches stdin and echos to stdout. When it finds input like bleep it echos preemptive bloop.
go build
cat input.txt | ./bleep
Sample output:
| using System; | |
| using System.ServiceModel; | |
| using System.ServiceModel.Web; | |
| using Nancy; | |
| using Nancy.Hosting.Wcf; | |
| using Nancy.Responses; | |
| namespace NancyMaxJsonLengthSandbox | |
| { |
| public T Inflate<T>() where T : class | |
| { | |
| var attr = typeof(T) | |
| .GetCustomAttributes(true) | |
| .OfType<XmlRootAttribute>() | |
| .SingleOrDefault(); | |
| string root; | |
| // Use ElementName if it's provided, otherwise use name of the type |
| HTTP/1.1 500 Internal Server Error | |
| Content-Type: text/html | |
| Server: Microsoft-IIS/7.0 | |
| X-Powered-By: ASP.NET | |
| Date: Wed, 18 Jan 2012 20:21:08 GMT | |
| Connection: close | |
| Content-Length: 1208 | |
| <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> | |
| <html xmlns="http://www.w3.org/1999/xhtml"> |
| var fs = require("fs"), | |
| path = require("path"), | |
| cp = require("child_process"); | |
| var conventionalTestDirectories = [".\\test", ".\\tests"], | |
| conventionChain = function() {}; | |
| function checkForDirectoryExists(directoryPath, nextDirectory, executeTests) { | |
| console.log("Checking for tests in " + directoryPath); | |
| path.exists(directoryPath, function(exists) { |
| using System; | |
| using System.Collections.Generic; | |
| using System.Linq; | |
| using YourMvcApp.Core.Bundlers; | |
| using Microsoft.Web.Optimization; | |
| namespace YourMvcApp.Core.Resources | |
| { | |
| public class BundleRegistration | |
| { |
| using System; | |
| using System.Linq; | |
| namespace Funzies | |
| { | |
| public class PassphraseGenerator | |
| { | |
| private Random _random = new Random(DateTime.Now.Millisecond); | |
| public string Generate(int wordsInPhrase) |
| using System; | |
| using Microsoft.VisualStudio.TestTools.UnitTesting; | |
| namespace AreMySeamsShowing | |
| { | |
| [TestClass] | |
| public class WidgetTests | |
| { | |
| private FooA fooA; |
| using System; | |
| using System.Collections.Generic; | |
| using System.Linq; | |
| namespace ConsoleApplication1 | |
| { | |
| public class Program | |
| { | |
| public static void Main() | |
| { |
| public class StaticViewEngine : VirtualPathProviderViewEngine | |
| { | |
| public StaticViewEngine() | |
| { | |
| MasterLocationFormats = new string[] { | |
| }; | |
| ViewLocationFormats = new[] { | |
| "~/build/templates/{1}/{0}.html", | |
| "~/build/templates/{0}.html", | |
| "~/build/{1}/{0}.html", |
This is a simple program that watches stdin and echos to stdout. When it finds input like bleep it echos preemptive bloop.
go build
cat input.txt | ./bleep
Sample output: