[erlang-questions] Can the CouchDB install of Mochiweb be used alone?

Tuncer Ayaz tuncer.ayaz@REDACTED
Fri May 1 18:12:40 CEST 2009


On Fri, May 1, 2009 at 5:59 PM, Carl McDade <carlmcdade@REDACTED> wrote:
> Everything seems to be fine on the path front. I have tried both werl and
> erl
>
> 7> pwd().
> c:/erlang_stuff/mochi_test
> ok
> 8> for %i in (src/*.erl) do erlc -o ebin src/%i;.

This was meant to be executed in the Windows cmd.exe shell
and not within the Erlang repl (interactive erl.exe, werl.exe).

> 8> for %i in (src/*.erl) do erlc -o ebin src/%i;
> 8> for %i in (src/*.erl) do erlc -o ebin src/%i.
> 8> pwd().
> * 2: syntax error before: for
> 8> for %i in (src/*.erl) -> do erlc -o ebin src/%i.
> 8> pwd().
> * 2: syntax error before: pwd
> 8> for %i in (src/*.erl) -> do erlc -o ebin src/%i;.
> 8> pwd().
> * 2: syntax error before: pwd
> 8> for %i in (src/*.erl) do erlc -o ebin src/%i
> 8> pwd().
> * 2: syntax error before: pwd
> 8> pwd().
> c:/erlang_stuff/mochi_test
> ok
> 9> for %i in (src/*.erl) do erlc -o ebin src/%i.erl.
> 9> erlc -o ebin src/mochiweb_app.erl.
> * 2: syntax error before: erlc
> 9> erlc -o ebin src/mochiweb_app.erl.
> * 1: syntax error before: ebin
> 9> erlc -o ebin src/mochiweb_app.erl.
> * 1: syntax error before: ebin
> 9>
>
> My path looks like this.
>
> C:\yaws\bin;%SystemRoot%\system32;%SystemRoot%;%SystemRoot%\System32\Wbem;E:\Program
> Files\jEdit;E:\PROGRA~1\DISKEE~1\DISKEE~1\;C:\erlang\bin;E:\Program
> Files\doxygen\bin
>
>
>
> On Fri, May 1, 2009 at 5:53 PM, Robert Raschke <rtrlists@REDACTED>
> wrote:
>>
>> On Fri, May 1, 2009 at 3:28 PM, Carl McDade <carlmcdade@REDACTED> wrote:
>>>
>>> Well the command prompt in both werl and erl just hang on this:
>>>
>>> for %i in (src/*.erl) do erlc -o ebin src/%i.
>>>
>>> No error no response. Ideas on where to problem lies?
>>
>>
>> It's a regular windows shell command. Is the erl bin directory on your
>> path?
>>
>> You could make yourself a wee batch file build.bat in the mochiweb root
>> folder with these contents:
>>
>> setlocal
>> set PATH=%PATH%;"C:\Program Files\erl6.5.6\bin"
>> for %%i in (src/*.erl) do erlc -o ebin src/%%i
>> copy src\mochiweb.app ebin
>> endlocal
>>
>> The '%i's need to be written '%%i' inside a batch script. Also, you may
>> need to set the PATH to your erl correctly.
>>
>> Robby



More information about the erlang-questions mailing list