From 58d6e4c97d10e960bb8ee32b98cd83501070b0cb Mon Sep 17 00:00:00 2001 From: Doug Coleman Date: Mon, 3 Mar 2008 14:44:48 -0600 Subject: [PATCH] remove extra files --- .../io/files/temporary/backend/backend.factor | 5 --- extra/io/files/temporary/temporary.factor | 32 ------------------- 2 files changed, 37 deletions(-) delete mode 100644 extra/io/files/temporary/backend/backend.factor delete mode 100644 extra/io/files/temporary/temporary.factor diff --git a/extra/io/files/temporary/backend/backend.factor b/extra/io/files/temporary/backend/backend.factor deleted file mode 100644 index 5c6900b3d2..0000000000 --- a/extra/io/files/temporary/backend/backend.factor +++ /dev/null @@ -1,5 +0,0 @@ -USING: io.backend ; -IN: io.files.temporary.backend - -HOOK: (temporary-file) io-backend ( path -- stream path ) -HOOK: temporary-path io-backend ( -- path ) diff --git a/extra/io/files/temporary/temporary.factor b/extra/io/files/temporary/temporary.factor deleted file mode 100644 index c4b197cf5e..0000000000 --- a/extra/io/files/temporary/temporary.factor +++ /dev/null @@ -1,32 +0,0 @@ -USING: kernel math math.bitfields combinators.lib math.parser -random sequences sequences.lib continuations namespaces -io.files io.backend io.nonblocking io arrays -io.files.temporary.backend system combinators vocabs.loader ; -IN: io.files.temporary - -: random-letter ( -- ch ) 26 random { CHAR: a CHAR: A } random + ; - -: random-ch ( -- ch ) - { t f } random [ 10 random CHAR: 0 + ] [ random-letter ] if ; - -: random-name ( n -- string ) [ drop random-ch ] "" map-as ; - -: ( prefix suffix -- path duplex-stream ) - temporary-path -rot - [ 10 random-name swap 3append path+ dup (temporary-file) ] 3curry - 10 retry ; - -: with-temporary-file ( quot -- path ) - >r f f r> with-stream ; - -: temporary-directory ( -- path ) - [ temporary-path 10 random-name path+ dup make-directory ] 10 retry ; - -: with-temporary-directory ( quot -- ) - >r temporary-directory r> - [ with-directory ] 2keep drop delete-tree ; - -{ - { [ unix? ] [ "io.unix.files.unique" ] } - { [ windows? ] [ "io.windows.files.unique" ] } -} cond require