Account Options

  1. Sign in
The old Google Groups will be going away soon, but your browser is incompatible with the new version.
Google Groups Home
« Groups Home
erlyweb:compile small patch proposal
There are currently too many topics in this group that display first. To make this topic appear first, remove this option from another topic.
There was an error processing your request. Please try again.
flag
  4 messages - Collapse all  -  Translate all to Translated (View all originals)
The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
 
From:
To:
Cc:
Followup To:
Add Cc | Add Followup-to | Edit Subject
Subject:
Validation:
For verification purposes please type the characters you see in the picture below or the numbers you hear by clicking the accessibility icon. Listen and type the numbers you hear
 
shaman  
View profile  
 More options Mar 13 2009, 3:33 pm
From: shaman <buricc...@gmail.com>
Date: Fri, 13 Mar 2009 12:33:54 -0700 (PDT)
Local: Fri, Mar 13 2009 3:33 pm
Subject: erlyweb:compile small patch proposal
First of all, I must say, that erlyweb is best web development
framework.

Simple patch proposed. It's a little correction to generate correct
path for AppDir and IncludePaths (current version generates incorrect
include path on Windows due to neglect of disk letter), something like
that:

compile(AppDir, Options) ->
 -   AppDir1 = case lists:reverse(AppDir) of
-                 [$/ | _] -> AppDir;
-                 Other -> lists:reverse([$/ | Other])
-             end,
+  AppDir1 = filename:absname(AppDir)

    IncludePaths =
+ [ filename:join(AppDir,X) || {i, X} <- Options],
-       lists:foldl(
-         fun({i, [$/ | _] = Path}, Acc) ->
-                 [Path | Acc];
-            ({i, Path}, Acc) ->
-                 [AppDir1 ++ "src/" ++ Path | Acc];
-            (_Opt, Acc) ->
-                 Acc
-         end, [AppDir1 ++ "src"], Options),


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
shaman  
View profile  
 More options Mar 13 2009, 6:53 pm
From: shaman <buricc...@gmail.com>
Date: Fri, 13 Mar 2009 15:53:42 -0700 (PDT)
Local: Fri, Mar 13 2009 6:53 pm
Subject: Re: erlyweb:compile small patch proposal
or rather:
[ filename:join(filename:join(AppDir, "src") ,X) || {i, X} <-
Options],

 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Buggaboo  
View profile  
 More options Mar 31 2009, 11:36 am
From: Buggaboo <buggas...@gmail.com>
Date: Tue, 31 Mar 2009 08:36:54 -0700 (PDT)
Local: Tues, Mar 31 2009 11:36 am
Subject: Re: erlyweb:compile small patch proposal
I tried installing on windows 6 months ago, but didn't get manage to
set it up right. I gave up because I'm a linux guy anyways.

Good job.

On Mar 14, 12:53 am, shaman <buricc...@gmail.com> wrote:


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
shaman  
View profile  
 More options Apr 4 2009, 2:32 pm
From: shaman <buricc...@gmail.com>
Date: Sat, 4 Apr 2009 11:32:39 -0700 (PDT)
Local: Sat, Apr 4 2009 2:32 pm
Subject: Re: erlyweb:compile small patch proposal
On Windows, it requires to correct/add yaws include dir in
make_erlyweb.erl and Emakefile and it works.

The problem arise when some one need something like that:
erlyweb:compile("./myapp", [{i,"d:/some/include"}])

erlyweb_compile:compile will seak directory "./myapp/src/d:/some/
include" instead of "d:/some/include".

The above code works on any OS, for absolute and relative paths as
well.

-module(erlyweb_compile).
...
compile(AppDir, Options) ->
 AppDir1 = filename:absname(AppDir)
 IncludePaths = [ filename:join(filename:join(AppDir, "src") ,X) ||
{i, X} <-Options],
...


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
End of messages
« Back to Discussions « Newer topic     Older topic »