Re: BUG REPORT: ClojureScript : Portable Path Support

2011-07-22 Thread Mark Derricutt
Oh don't say that!  That was going to be my weekend project - looking at adding 
ClojureScript support to clojure-maven-plugin.

I made a coffee-maven-plugin for our web guys the other week and now we've got 
a chance to sway them over to clojure ( well, I don't think that'll happen 
easily tho ).


On 21/07/2011, at 4:40 PM, Sean Corfield wrote:

 Even better would be ClojureScript with maven support
 
 Didn't Rich say he hopes Maven doesn't come anywhere near ClojureScript? :)



smime.p7s
Description: S/MIME cryptographic signature


Re: BUG REPORT: ClojureScript : Portable Path Support

2011-07-22 Thread Troy Clevenger
This patch here fixes the path issues on windows for me.  I haven't
tested it on a non-windows system though. Thought I'd post it here in
case it helps anyone.

http://content.wuala.com/contents/Daedalus/DropBox/Fixed-unoptimized-compile-in-windows.diff?dl=1

Regards,

Troy

On Jul 20, 10:12 pm, pmbauer paul.michael.ba...@gmail.com wrote:
 Per instructions from redinger and jgehtland (patch addressing one issue
 attached).

 Three separate issues so far re: path support on windows

 * compiler path regex is not portable, cljs/compiler.clj:1096 (see attached
 patch, thanks amalloy for the assist)

 * generated JS has path problems on windows
 goog.addDependency(*
 ..\..\..\..\..\..\..\/C:/tmp/clojurescript/samples/twitterbuzz/out/cljs/co 
 re.js
 *, ['cljs.core'], ['goog.string', 'goog.string.StringBuffer', 'goog.object',
 'goog.array']);

 * helper launch scripts on windows (under cygwin), more a feature than bug

  portable-path-regex.diff
  1KViewDownload

-- 
You received this message because you are subscribed to the Google
Groups Clojure group.
To post to this group, send email to clojure@googlegroups.com
Note that posts from new members are moderated - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en


Re: BUG REPORT: ClojureScript : Portable Path Support

2011-07-21 Thread pmbauer
I know.
But the sorts of (presently non-portable) scripts in scripts (see 
bootstrap, repl) ad-hoc test strategy, etc in ClojureScript are begging for 
dependency management and a build tool.

-- 
You received this message because you are subscribed to the Google
Groups Clojure group.
To post to this group, send email to clojure@googlegroups.com
Note that posts from new members are moderated - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

Re: BUG REPORT: ClojureScript : Portable Path Support

2011-07-21 Thread pmbauer
If ClojureScript isn't mavenified, how else do you easily make it a 
dependency in a web application?

-- 
You received this message because you are subscribed to the Google
Groups Clojure group.
To post to this group, send email to clojure@googlegroups.com
Note that posts from new members are moderated - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

Re: BUG REPORT: ClojureScript : Portable Path Support

2011-07-21 Thread Stuart Halloway
 If ClojureScript isn't mavenified, how else do you easily make it a 
 dependency in a web application?

Maven doesn't any problems that we have, and would add complexity to the 
development process and slow us down. Also, we don't want to unthinkingly drag 
Java presumptions into ClojureScript.

Let's wait and collect feedback from the community before pouring any cement on 
deployment approaches.

Stu


Stuart Halloway
Clojure/core
http://clojure.com

-- 
You received this message because you are subscribed to the Google
Groups Clojure group.
To post to this group, send email to clojure@googlegroups.com
Note that posts from new members are moderated - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

Re: BUG REPORT: ClojureScript : Portable Path Support

2011-07-21 Thread Brenton
 generated JS has path problems on windows

Until this gets fixed you can work around this particular problem by
using one of the available optimizations.

cljsc src {:optimizations :simple}  twitterbuzz.js

You may also use :whitespace or :advanced in place of :simple above.

This will produce one JavaScript file with no goog.addDependency
calls.

In the index.html file, remove all of the script tags except for the
one that pulls in twitterbuzz.js

On Jul 20, 10:12 pm, pmbauer paul.michael.ba...@gmail.com wrote:
 Per instructions from redinger and jgehtland (patch addressing one issue
 attached).

 Three separate issues so far re: path support on windows

 * compiler path regex is not portable, cljs/compiler.clj:1096 (see attached
 patch, thanks amalloy for the assist)

 * generated JS has path problems on windows
 goog.addDependency(*
 ..\..\..\..\..\..\..\/C:/tmp/clojurescript/samples/twitterbuzz/out/cljs/core.js
 *, ['cljs.core'], ['goog.string', 'goog.string.StringBuffer', 'goog.object',
 'goog.array']);

 * helper launch scripts on windows (under cygwin), more a feature than bug

  portable-path-regex.diff
  1KViewDownload

-- 
You received this message because you are subscribed to the Google
Groups Clojure group.
To post to this group, send email to clojure@googlegroups.com
Note that posts from new members are moderated - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en


Re: BUG REPORT: ClojureScript : Portable Path Support

2011-07-21 Thread pmbauer
Fair enough.

But, it would be nice to eventually have a ClojureScript jar available in a 
public maven repo someplace.
Not having one would needlessly complicate projects that already use a 
maven-based build tool (mvn, lein, cake) and want to depend on it as part of 
their build.

-- 
You received this message because you are subscribed to the Google
Groups Clojure group.
To post to this group, send email to clojure@googlegroups.com
Note that posts from new members are moderated - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

Re: BUG REPORT: ClojureScript : Portable Path Support

2011-07-21 Thread Chas Emerick

On Jul 21, 2011, at 12:40 AM, Sean Corfield wrote:

 On Wed, Jul 20, 2011 at 9:34 PM, pmbauer paul.michael.ba...@gmail.com wrote:
 Even better would be ClojureScript with maven support
 
 Didn't Rich say he hopes Maven doesn't come anywhere near ClojureScript? :)

 I know.
 But the sorts of (presently non-portable) scripts in scripts (see 
 bootstrap, repl) ad-hoc test strategy, etc in ClojureScript are begging for 
 dependency management and a build tool.

 If ClojureScript isn't mavenified, how else do you easily make it a 
 dependency in a web application?

ClojureScript should have scripts or other low level methods for doing 
everything it needs, so that, if one is so inclined, those methods can be 
applied by higher level tools.  It would be a disaster if the main entry 
point for a ClojureScript REPL or compilation process were via Maven.

That is all separate from the provide-ClojureScript-as-a-dependency issue 
(having a pom file off in the corner so that releases can be pushed out to 
central will resolve that).

- Chas

-- 
You received this message because you are subscribed to the Google
Groups Clojure group.
To post to this group, send email to clojure@googlegroups.com
Note that posts from new members are moderated - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en


Re: BUG REPORT: ClojureScript : Portable Path Support

2011-07-21 Thread pmbauer
Fair enough.  That addresses my concern.

-- 
You received this message because you are subscribed to the Google
Groups Clojure group.
To post to this group, send email to clojure@googlegroups.com
Note that posts from new members are moderated - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

BUG REPORT: ClojureScript : Portable Path Support

2011-07-20 Thread pmbauer
Per instructions from redinger and jgehtland (patch addressing one issue 
attached).

Three separate issues so far re: path support on windows

* compiler path regex is not portable, cljs/compiler.clj:1096 (see attached 
patch, thanks amalloy for the assist)

* generated JS has path problems on windows
goog.addDependency(*
..\..\..\..\..\..\..\/C:/tmp/clojurescript/samples/twitterbuzz/out/cljs/core.js
*, ['cljs.core'], ['goog.string', 'goog.string.StringBuffer', 'goog.object', 
'goog.array']);

* helper launch scripts on windows (under cygwin), more a feature than bug

-- 
You received this message because you are subscribed to the Google
Groups Clojure group.
To post to this group, send email to clojure@googlegroups.com
Note that posts from new members are moderated - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=enFrom 6b7b35504af661e16fc24487d309719cda974d31 Mon Sep 17 00:00:00 2001
From: unknown pba...@.corp.shutterfly.com
Date: Wed, 20 Jul 2011 18:56:19 -0700
Subject: [PATCH] Made path pattern portable.

---
 src/clj/cljs/compiler.clj |2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
 mode change 100644 = 100755 src/clj/cljs/compiler.clj

diff --git a/src/clj/cljs/compiler.clj b/src/clj/cljs/compiler.clj
old mode 100644
new mode 100755
index b1f2213..b7090b0
--- a/src/clj/cljs/compiler.clj
+++ b/src/clj/cljs/compiler.clj
@@ -1093,7 +1093,7 @@ goog.require = function(rule){Packages.clojure.lang.RT[\var\](\cljs.compiler\
 
 (defn path-seq
   [file-str]
-  (string/split file-str (re-pattern java.io.File/separator)))
+  (string/split file-str (re-pattern (java.util.regex.Pattern/quote (java.io.File/separator)
 
 (defn to-path
   [parts]
-- 
1.7.5.1



Re: BUG REPORT: ClojureScript : Portable Path Support

2011-07-20 Thread Sean Corfield
On Wed, Jul 20, 2011 at 9:34 PM, pmbauer paul.michael.ba...@gmail.com wrote:
 Even better would be ClojureScript with maven support

Didn't Rich say he hopes Maven doesn't come anywhere near ClojureScript? :)
-- 
Sean A Corfield -- (904) 302-SEAN
An Architect's View -- http://corfield.org/
World Singles, LLC. -- http://worldsingles.com/
Railo Technologies, Inc. -- http://www.getrailo.com/

Perfection is the enemy of the good.
-- Gustave Flaubert, French realist novelist (1821-1880)

-- 
You received this message because you are subscribed to the Google
Groups Clojure group.
To post to this group, send email to clojure@googlegroups.com
Note that posts from new members are moderated - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en