Jumpin' Jehoshaphat!
John - your "with-directory" suggestion *does* work, with a full path to
the pdf, no need to copy/move the files -

IN: scratchpad
"/Users/cwalston/factor/mine/scans/herbal_scans_to_files/14_substances_that_calm_the_spirit/1_substances_that_settle_and_calm_the_spirit/1_long_gu/"
[ "docsplit text --no-clean -l eng long_gu004.pdf" run-detached . ]
with-directory
T{ process
    { command "docsplit text --no-clean -l eng long_gu004.pdf" }
    { environment H{ } }
    { environment-mode +append-environment+ }
    { group +same-group+ }
    { handle 5420 }
}

Now, I'm cookin' with gas. Thanks again!
~cw


On Tue, Feb 11, 2014 at 6:20 PM, CW Alston <cwalsto...@gmail.com> wrote:

> Gotcha - I'll check that
>
>
> On Tue, Feb 11, 2014 at 5:31 PM, John Benediktsson <mrj...@gmail.com>wrote:
>
>> I'm sorry, I meant with-directory in io.directories vocabulary:
>>
>> IN: scratchpad "/path/to/dir" [ "docsplit file.pdf" ] with-directory
>>
>>
>>
>> On Tue, Feb 11, 2014 at 5:12 PM, CW Alston <cwalsto...@gmail.com> wrote:
>>
>>> 1) docsplit still sleeps on this, even in terminal:
>>>
>>> IN: scratchpad "docsplit text --no-clean -l chi_sim
>>> /Users/cwalston/factor/mine/scans/herbal_scans_to_files/14_substances_that_calm_the_spirit/1_substances_that_settle_and_calm_the_spirit/1_long_gu/long_gu001.pdf"
>>> run-detached .
>>> T{ process
>>>     { command
>>>         "docsplit text --no-clean -l chi_sim
>>> /Users/cwalston/factor/mine/scans/herbal_scans_to_files/14_substances_that_calm_the_spirit/1_substances_that_settle_and_calm_the_spirit/1_long_gu/long_gu001.pdf"
>>>      }
>>>     { environment H{ } }
>>>     { environment-mode +append-environment+ }
>>>     { group +same-group+ }
>>>     { handle 5058 }
>>> }
>>>
>>> 2) I don't find with-current-directory. Maybe I can cobble something
>>> together  with io.directories
>>>
>>>
>>> On Tue, Feb 11, 2014 at 4:45 PM, CW Alston <cwalsto...@gmail.com> wrote:
>>>
>>>> Hmm.. I see where you're going. I'll give both a try. Thanks.
>>>>
>>>>
>>>> On Tue, Feb 11, 2014 at 4:41 PM, John Benediktsson <mrj...@gmail.com>wrote:
>>>>
>>>>> Have you tried either:
>>>>>
>>>>> 1) specifying "docsplit /full/path/to/the/file.pdf"
>>>>>
>>>>> 2) IN: scratchpad "/full/path/to/the" [ "docsplit file.pdf" ]
>>>>> with-current-directory
>>>>>
>>>>>
>>>>> On Tue, Feb 11, 2014 at 4:34 PM, CW Alston <cwalsto...@gmail.com>wrote:
>>>>>
>>>>>> A curiosity & a breakthrough -
>>>>>> I discover that simply calling the Factor executable in the terminal
>>>>>> (on my system)
>>>>>> provokes the "just leaking" warnings, but after that, Factor seems to
>>>>>> run just fine -
>>>>>>
>>>>>> ➜  ~ git:(master) ✗ factor
>>>>>> 2014-02-11 15:25:49.753 factor[3468:903] *** __NSAutoreleaseNoPool():
>>>>>> Object 0x10a4a0 of class NSPathStore2 autoreleased with no pool in place 
>>>>>> -
>>>>>> just leaking
>>>>>> ...
>>>>>> 2014-02-11 15:25:49.764 factor[3468:903] *** __NSAutoreleaseNoPool():
>>>>>> Object 0x10db30 of class NSCFData autoreleased with no pool in place - 
>>>>>> just
>>>>>> leaking
>>>>>> IN: scratchpad
>>>>>>
>>>>>> Once there, I can USE: code normally. As a bonus, if I copy the pdfs
>>>>>> I need to my home directory,
>>>>>> calls to docsplit succeed, returning extracted .txt files there
>>>>>> (HOME) as well -
>>>>>>
>>>>>> IN: scratchpad "docsplit text --no-clean -l eng long_gu004.pdf"
>>>>>> run-detached .
>>>>>> T{ process
>>>>>>     { command "docsplit text --no-clean -l eng long_gu004.pdf" }
>>>>>>     { environment H{ } }
>>>>>>     { environment-mode +append-environment+ }
>>>>>>     { group +same-group+ }
>>>>>>     { handle 3518 }
>>>>>> }
>>>>>>
>>>>>> So basically I have to start Factor in the terminal, ignore the
>>>>>> warnings, copy the pdfs I need to $HOME,
>>>>>> and get the extraction work done from there. Copying the files over &
>>>>>> starting Factor from the Finder doesn't
>>>>>> work. At the cost of a little indirection, cracking this docsplit
>>>>>> puzzle saves me a ton of time. Happy now!
>>>>>>
>>>>>> I'll keep a watch on the memory issue (probably my aged system), but
>>>>>> it doesn't seem to cause problems so far.
>>>>>> Thanks to all; a collage of the tips you offered has got me over the
>>>>>> hump.
>>>>>>
>>>>>> Cheers!
>>>>>> ~cw
>>>>>>
>>>>>>
>>>>>> On Tue, Feb 11, 2014 at 1:32 PM, CW Alston <cwalsto...@gmail.com>wrote:
>>>>>>
>>>>>>> I'm running 10.6.8 (Snow Leopard) on a vintage 32-bit MacBook Pro.
>>>>>>>
>>>>>>>
>>>>>>> On Tue, Feb 11, 2014 at 8:25 AM, John Benediktsson <mrj...@gmail.com
>>>>>>> > wrote:
>>>>>>>
>>>>>>>> I don't get those warnings on 10.9.1, which Mac OS X version are
>>>>>>>> you running?
>>>>>>>>
>>>>>>>>
>>>>>>>> On Tue, Feb 11, 2014 at 2:17 AM, CW Alston <cwalsto...@gmail.com>wrote:
>>>>>>>>
>>>>>>>>> Hi-
>>>>>>>>> I'm experimenting with writing/running executable Factor scripts.
>>>>>>>>>  A simple script in a file titled "hello" -
>>>>>>>>>
>>>>>>>>> #! /Applications/factor/factor -script
>>>>>>>>> USING: io ;
>>>>>>>>> "hello world" print
>>>>>>>>>
>>>>>>>>> -does its thing in the terminal, but on the way echos "just
>>>>>>>>> leaking", thus:
>>>>>>>>>
>>>>>>>>> ➜  ~ git:(master) ✗ factor "/Users/cwalston/factor/hello"
>>>>>>>>> run-script
>>>>>>>>> 2014-02-11 00:09:08.391 factor[7273:903] ***
>>>>>>>>> __NSAutoreleaseNoPool(): Object 0x10a500 of class NSPathStore2 
>>>>>>>>> autoreleased
>>>>>>>>> with no pool in place - just leaking
>>>>>>>>> ...(lots more of the same)
>>>>>>>>> 2014-02-11 00:09:08.439 factor[7273:903] ***
>>>>>>>>> __NSAutoreleaseNoPool(): Object 0x108690 of class NSCFData 
>>>>>>>>> autoreleased
>>>>>>>>> with no pool in place - just leaking
>>>>>>>>> hello world
>>>>>>>>> ➜  ~ git:(master) ✗
>>>>>>>>>
>>>>>>>>> I'm on a Mac. Seems to be expecting an NSAutoReleasePool, so I
>>>>>>>>> amend the
>>>>>>>>> script:
>>>>>>>>>
>>>>>>>>> #! /Applications/factor/factor -script
>>>>>>>>> USING: io cocoa cocoa.application cocoa.classes ;
>>>>>>>>>
>>>>>>>>> IMPORT: NSAutoreleasePool
>>>>>>>>> [ "hello world" print ] with-autorelease-pool
>>>>>>>>>
>>>>>>>>> But I get the same warning.
>>>>>>>>> Can anyone enlighten me as to what's called for here, as far as
>>>>>>>>> Factor
>>>>>>>>> code is concerned? Do I have to enable OS garbage collection? If
>>>>>>>>> so, how
>>>>>>>>> would I do that?
>>>>>>>>>
>>>>>>>>> Thanks kindly,
>>>>>>>>> ~cw
>>>>>>>>>
>>>>>>>>> --
>>>>>>>>> *~ Memento Amori*
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> ------------------------------------------------------------------------------
>>>>>>>>> Android apps run on BlackBerry 10
>>>>>>>>> Introducing the new BlackBerry 10.2.1 Runtime for Android apps.
>>>>>>>>> Now with support for Jelly Bean, Bluetooth, Mapview and more.
>>>>>>>>> Get your Android app in front of a whole new audience.  Start now.
>>>>>>>>>
>>>>>>>>> http://pubads.g.doubleclick.net/gampad/clk?id=124407151&iu=/4140/ostg.clktrk
>>>>>>>>> _______________________________________________
>>>>>>>>> Factor-talk mailing list
>>>>>>>>> Factor-talk@lists.sourceforge.net
>>>>>>>>> https://lists.sourceforge.net/lists/listinfo/factor-talk
>>>>>>>>>
>>>>>>>>>
>>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> --
>>>>>>> *~ Memento Amori*
>>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>> --
>>>>>> *~ Memento Amori*
>>>>>>
>>>>>
>>>>>
>>>>
>>>>
>>>> --
>>>> *~ Memento Amori*
>>>>
>>>
>>>
>>>
>>> --
>>> *~ Memento Amori*
>>>
>>
>>
>
>
> --
> *~ Memento Amori*
>



-- 
*~ Memento Amori*
------------------------------------------------------------------------------
Android apps run on BlackBerry 10
Introducing the new BlackBerry 10.2.1 Runtime for Android apps.
Now with support for Jelly Bean, Bluetooth, Mapview and more.
Get your Android app in front of a whole new audience.  Start now.
http://pubads.g.doubleclick.net/gampad/clk?id=124407151&iu=/4140/ostg.clktrk
_______________________________________________
Factor-talk mailing list
Factor-talk@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/factor-talk

Reply via email to