20 Commits
Author SHA1 Message Date
Kare Morstol 2de04312b5 Test using streams with ‘print’. 2015-10-07 20:09:13 +02:00
Kare Morstol 99df0ddf19 Enable ReadableStream to run commands using itself as stdin. 2015-10-07 18:42:19 +02:00
Kare Morstol 31508d338c Create ReadableStream and streams() . 2015-10-07 15:33:06 +02:00
Kare Morstol 8bec5cf499 Eviscerate pretty much everything.
Will be changing a lot of the API, and do not want to have to change all the unit test and the rest of the code for every single change.
2015-07-19 22:49:39 +02:00
Kare Morstol a9dbdcf629 Update to Swift 2.0 .
Wow, lots of changes in Swift 2.0! And all of them great, except for renaming println to print. What's up with that?
This is just to get it to compile, we will be trying and throwing errors in no time.
2015-06-28 00:52:40 +02:00
Kare Morstol a1e26bfcc8 Tidy up / nitpick. 2014-12-09 18:07:04 +01:00
Kare Morstol 4d2fca7b74 Add operator |>> for printing anything to a writable stream.
Replaced all uses of writeTo with the new operator in unit tests, test scripts and readme.
2014-12-04 20:05:15 +01:00
Kare Morstol 548e0740d4 Tidy up the code some more. 2014-10-30 00:28:20 +01:00
Kare Morstol 977888c03b Rename "write" functions to "writeTo".
Because it makes more sense.
2014-10-25 19:17:07 +02:00
Kare Morstol 9136d17843 Use "|> write(standardoutput)" instead of " |> standardoutput". And support writing of sequences of strings.
Avoids the special case of "|> WriteableStreamType".
2014-10-15 23:03:42 +02:00
Kare Morstol d09aa63f3e Add test testChainWithSequenceOfStreamsPrintedToStream. 2014-10-13 22:00:53 +02:00
Kare Morstol c6734b8825 Add testSequenceOfStreamsToStream. 2014-09-24 21:03:09 +02:00
Kare Morstol 36e217c0c3 Make piping one stream to another lazy. 2014-09-12 01:12:50 +02:00
Kare Morstol 1d3d876f22 Move "streams" function to the module.
Returns a writable stream and a readable stream. What you write to the 1st one can be read from the 2nd one.
Make sure to call closeStream() on the writable stream before you call read() on the readable one.
2014-09-10 20:08:39 +02:00
Kare Morstol 6240e739f9 Enabling printing something Printable, like a String, to a writable stream. 2014-09-10 00:39:39 +02:00
Kare Morstol 96ab5a2070 Enable "func run (shellcommand: String) -> ReadableStreamType" to also be run by itself on a single line.
A thorough explanation is forthcoming.
2014-09-02 15:23:22 +02:00
Kare Morstol 85579f6b37 Print one stream to another: readablestream |> writablestream 2014-08-28 00:21:13 +02:00
Kare Morstol ed34a689ec ReadableStreamType inherits from Streamable.
Also tried out and commented stuff that does not work in beta 6.
2014-08-23 21:02:08 +02:00
Kare Morstol 660b2f9d00 Radically simplified stream(String) and stream(array/sequence). 2014-08-22 01:46:27 +02:00
Kare Morstol 8c6f0a7171 Moved stream factory functions from unit test to stream.swift.
A new stream factory function which takes a closure which returns a closure which returns a string.
2014-08-21 23:38:50 +02:00