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
Message from discussion HTTP Web Server configuration

Received: by 10.58.125.106 with SMTP id mp10mr3792082veb.33.1347159500139;
        Sat, 08 Sep 2012 19:58:20 -0700 (PDT)
X-BeenThere: tincr-for-chrome-devtools@googlegroups.com
Received: by 10.52.93.38 with SMTP id cr6ls574205vdb.8.gmail; Sat, 08 Sep 2012
 19:58:19 -0700 (PDT)
Received: by 10.52.33.34 with SMTP id o2mr1393611vdi.12.1347159499911;
        Sat, 08 Sep 2012 19:58:19 -0700 (PDT)
Date: Sat, 8 Sep 2012 19:58:19 -0700 (PDT)
From: Gabriel <gko...@gmail.com>
To: tincr-for-chrome-devtools@googlegroups.com
Message-Id: <ed6e2673-dc5a-4499-b6c5-5a0044bb55be@googlegroups.com>
In-Reply-To: <ad2480c3-d9b6-48c7-91a7-6c516b53971d@googlegroups.com>
References: <064b7171-b7df-4934-ab77-d8bd69525b39@googlegroups.com>
 <CAGOLXFu0zW4GoNY_pN+Fy16=cmpJfRQWiFq9fjqG-U_zwxzBqQ@mail.gmail.com>
 <183d9dac-5f9c-4d05-8038-2a1ff3875411@googlegroups.com>
 <2b9288d6-75c5-4022-a0d0-b3b42a5498e1@googlegroups.com>
 <ad2480c3-d9b6-48c7-91a7-6c516b53971d@googlegroups.com>
Subject: Re: HTTP Web Server configuration
MIME-Version: 1.0
Content-Type: multipart/mixed; 
	boundary="----=_Part_652_27346597.1347159499625"

------=_Part_652_27346597.1347159499625
Content-Type: multipart/alternative; 
	boundary="----=_Part_653_19213756.1347159499625"

------=_Part_653_19213756.1347159499625
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 7bit

OK. I see now that I was misreading your email. I'm not using this kind of 
project type. I've used "Configuration File" instead to have greater 
control. 
I've created a tincr.json file, put it in the root of my web directory and 
put the follow content:

{ 
"toFile" : [
{"from": 
"/my_virtual_root_directory_name/subdir1/subdir2/scripts/j(.+\\.js)",
 "to": "C:\\physical_dir\\subdir1\\subdir2\\scripts\\$1"}
],
"fromFile" : [
{"from": "C:\\\\physical_dir\\\\subdir1\\\\subdir2\\\\scripts\\\\(.+\\.js)",
 "to": "/my_virtual_root_directory_name/subdir1/subdir2/scripts/$1"}
] 
}

This works well when changing the file outside of chrome and having int 
propagating to the devtools. 
I still couldn't achieve the opposite - change and save in Chrome editor 
and have it propagate back to the local file system.

Maybe Ryan can chime in an give us a sample how to properly configure this 
on windows.

Cheers
-Gabe


On Saturday, September 8, 2012 10:14:25 PM UTC-4, Christopher Froehlich 
wrote:
>
> Wacky, I just replied with a screenshot and attachments, but that reply 
> now appears as "This message has been deleted.". So here goes again:
>
> Gabe,
>
>
> <https://lh3.googleusercontent.com/-PVJIsUELgGQ/UEv7HrlZd2I/AAAAAAAA8es/W_oYnYAzKdA/s1600/localhost-test.html.png>
> I've attached my two test files, and I'm attaching the screenshot of my 
> config. I don't have an actual config file (tincr.config), because I'm 
> using the HTTP Web Server config option (assuming that none of the 
> predefined configs require additional config files).
>
> -Christopher
>
> On Saturday, September 8, 2012 8:52:46 PM UTC-4, Gabriel wrote:
>>
>> Chris, 
>>
>> Could you post the config file you had used with your tincr?
>>
>> Thanks
>> -Gabe
>>
>> On Saturday, September 8, 2012 8:46:17 PM UTC-4, Christopher Froehlich 
>> wrote:
>>>
>>> Right. To clarify, I'm updating the JS using an external editor 
>>> (Sublime). If I make and save the edit in Sublime (using the HTTP Web 
>>> Server config), the change is not replicated in either the Sources or the 
>>> Resources panel of Inspector. Likewise, if I edit the file inside Chrome in 
>>> Sources, the change is not replicated to Sublime (unless I use the "Save 
>>> As" option to explicitly map the file).
>>>
>>> I always run with cache disabled when testing, but I double checked--it 
>>> is disabled.
>>>
>>> Live reload works perfectly when using the "file:///C:/test/test.html" 
>>> as the URL. Of course, I'd rather not have to refactor my actual app to 
>>> handle cross-domain ajax requests (and remap the pathing for requests) from 
>>> file:// to http://localhost--so getting the HTTP Web Server config to 
>>> work would be ideal.
>>>
>>> On Saturday, September 8, 2012 6:30:41 PM UTC-4, Ryan Ackley wrote:
>>>>
>>>> So live reload isn't working? When you update the file in the 
>>>> filesystem, it's not changing in devtools or is it vice-versa? 
>>>>
>>>> The error message means that Tincr is matching up the file and url 
>>>> correctly but the contents are different. Is it possible that test.js 
>>>> is being cached? Can you try going into devtools settings and tick the 
>>>> Disable Cache checkbox. You can access the devtools settings by 
>>>> opening the devtools and clicking the gear icon in the lower left 
>>>> corner. 
>>>>
>>>> On Sun, Sep 9, 2012 at 4:17 AM, Christopher Froehlich 
>>>> <c...@the-shades.net> wrote: 
>>>> > I've pulled the latest source from bitbucket and loaded Tincr as an 
>>>> unpacked 
>>>> > extension (I've also tried using the latest version in the Chrome 
>>>> store). I 
>>>> > have a very thin HTML page with a single JS include. The HTML page 
>>>> has a 
>>>> > button. The JS fetches the button from the DOM and binds a click 
>>>> event which 
>>>> > issues an alert('a mutating string'). 
>>>> > 
>>>> > When I load the HTML page from the file system, I see changes to the 
>>>> JS file 
>>>> > in the Sources tab in real time--and my click event is changing 
>>>> dynamically 
>>>> > (without a page refresh) as I change the file. All expected. 
>>>> > 
>>>> > However, when I try to use HTTP Web Server config option, I get this 
>>>> error 
>>>> > in the console: 
>>>> > 
>>>> > Content for url http://localhost/test.js matches local file 
>>>> C:\test\test.js 
>>>> > 
>>>> > Content for url http://localhost/test.js doesn't match local file 
>>>> > C:\test\test.js 
>>>> > 
>>>> > (anonymous function) 
>>>> > InjectedScript._evaluateOn 
>>>> > InjectedScript._evaluateAndWrap 
>>>> > InjectedScript.evaluate 
>>>> > 
>>>> > 
>>>> > My content is no longer updating. Initially, I had my test.html and 
>>>> test.js 
>>>> > content hosted at "localhost/test/test.html" (physically located at 
>>>> > c:\test); however, I noticed (by inspecting Tincr and debugging) that 
>>>> the 
>>>> > URL parameter passed in was simply "localhost" which could not 
>>>> resolve 
>>>> > "test.html". So I moved my test files to the root of my web site, now 
>>>> just 
>>>> > "localhost/test.html", but I get the same behavior. 
>>>> > 
>>>> > I see this thread started at the original group, but it doesn't 
>>>> resolve the 
>>>> > issue. 
>>>> > 
>>>> > Any thoughts? I'm on Windows 7x64 using IIS for my webserver and 
>>>> testing in 
>>>> > Chrome Canary and Chrome Dev. 
>>>> > 
>>>> > -- 
>>>> > 
>>>> > 
>>>>
>>>
------=_Part_653_19213756.1347159499625
Content-Type: text/html; charset=utf-8
Content-Transfer-Encoding: quoted-printable

OK. I see now that I was misreading your email. I'm not using this kind of =
project type. I've used "Configuration File" instead to have greater contro=
l.&nbsp;<div>I've created a tincr.json file, put it in the root of my web d=
irectory and put the follow content:</div><div><br></div><div><div><font fa=
ce=3D"verdana, sans-serif">{&nbsp;</font></div><div><font face=3D"verdana, =
sans-serif"><span class=3D"Apple-tab-span" style=3D"white-space:pre">=09</s=
pan>"toFile" : [</font></div><div><font face=3D"verdana, sans-serif"><span =
class=3D"Apple-tab-span" style=3D"white-space:pre">=09=09</span>{"from": "/=
my_virtual_root_directory_name/subdir1/subdir2/scripts/j(.+\\.js)",</font><=
/div><div><font face=3D"verdana, sans-serif"><span class=3D"Apple-tab-span"=
 style=3D"white-space:pre">=09=09</span> "to": "C:\\physical_dir\\subdir1\\=
subdir2\\scripts\\$1"}</font></div><div><font face=3D"verdana, sans-serif">=
<span class=3D"Apple-tab-span" style=3D"white-space:pre">=09</span>],</font=
></div><div><font face=3D"verdana, sans-serif"><span class=3D"Apple-tab-spa=
n" style=3D"white-space:pre">=09</span>"fromFile" : [</font></div><div><fon=
t face=3D"verdana, sans-serif"><span class=3D"Apple-tab-span" style=3D"whit=
e-space:pre">=09=09</span>{"from": "C:\\\\</font><span style=3D"font-family=
: verdana, sans-serif;">physical_dir</span><font face=3D"verdana, sans-seri=
f">\\\\subdir1\\\\subdir2\\\\scripts\\\\(.+\\.js)",</font></div><div><font =
face=3D"verdana, sans-serif"><span class=3D"Apple-tab-span" style=3D"white-=
space:pre">=09=09</span> "to": "/</font><span style=3D"font-family: verdana=
, sans-serif;">my_virtual_root_directory_name</span><font face=3D"verdana, =
sans-serif">/subdir1/subdir2/scripts/$1"}</font></div><div><font face=3D"ve=
rdana, sans-serif"><span class=3D"Apple-tab-span" style=3D"white-space:pre"=
>=09</span>] <span class=3D"Apple-tab-span" style=3D"white-space:pre">=09</=
span></font></div><div><font face=3D"verdana, sans-serif">}</font></div><di=
v><font face=3D"verdana, sans-serif"><br></font></div><div><font face=3D"ve=
rdana, sans-serif">This works well when changing the file outside of chrome=
 and having int propagating to the devtools.&nbsp;</font></div><div><font f=
ace=3D"verdana, sans-serif">I still couldn't achieve the opposite - change =
and save in Chrome editor and have it propagate back to the local file syst=
em.</font></div><div><font face=3D"verdana, sans-serif"><br></font></div><d=
iv><font face=3D"verdana, sans-serif">Maybe Ryan can chime in an give us a =
sample how to properly configure this on windows.</font></div><div><font fa=
ce=3D"verdana, sans-serif"><br></font></div><div><font face=3D"verdana, san=
s-serif">Cheers</font></div><div><font face=3D"verdana, sans-serif">-Gabe</=
font></div><div><br></div><br>On Saturday, September 8, 2012 10:14:25 PM UT=
C-4, Christopher Froehlich wrote:<blockquote class=3D"gmail_quote" style=3D=
"margin: 0;margin-left: 0.8ex;border-left: 1px #ccc solid;padding-left: 1ex=
;">Wacky, I just replied with a screenshot and attachments, but that reply =
now appears as "<span style=3D"text-align:center;background-color:rgb(239,2=
39,239)">This message has been deleted.</span>". So here goes again:<div><b=
r></div><div>Gabe,<br><div><br></div><p style=3D"text-align:center;clear:bo=
th"><a href=3D"https://lh3.googleusercontent.com/-PVJIsUELgGQ/UEv7HrlZd2I/A=
AAAAAAA8es/W_oYnYAzKdA/s1600/localhost-test.html.png" style=3D"margin-left:=
1em;margin-right:1em" target=3D"_blank"><img border=3D"0" width=3D"320" hei=
ght=3D"176" origsrc=3D"https://lh3.googleusercontent.com/-PVJIsUELgGQ/UEv7H=
rlZd2I/AAAAAAAA8es/W_oYnYAzKdA/s320/localhost-test.html.png"></a></p><div>I=
've attached my two test files, and I'm attaching the screenshot of my conf=
ig. I don't have an actual config file (tincr.config),&nbsp;because&nbsp;I'=
m using the HTTP Web Server config option (assuming that none of the predef=
ined configs require additional config files).<br><br>-Christopher<br><br>O=
n Saturday, September 8, 2012 8:52:46 PM UTC-4, Gabriel wrote:<blockquote c=
lass=3D"gmail_quote" style=3D"margin:0;margin-left:0.8ex;border-left:1px #c=
cc solid;padding-left:1ex">Chris,&nbsp;<div><br></div><div>Could you post t=
he config file you had used with your tincr?</div><div><br></div><div>Thank=
s</div><div>-Gabe<br><br>On Saturday, September 8, 2012 8:46:17 PM UTC-4, C=
hristopher Froehlich wrote:<blockquote class=3D"gmail_quote" style=3D"margi=
n:0;margin-left:0.8ex;border-left:1px #ccc solid;padding-left:1ex">Right. T=
o clarify, I'm updating the JS using an external editor (Sublime). If I mak=
e and save the edit in Sublime (using the HTTP Web Server config), the chan=
ge is not replicated in either the Sources or the Resources panel of Inspec=
tor. Likewise, if I edit the file inside Chrome in Sources, the change is n=
ot replicated to Sublime (unless I use the "Save As" option to explicitly m=
ap the file).<div><br></div><div>I always run with cache disabled when test=
ing, but I double checked--it is disabled.</div><div><br></div><div>Live re=
load works perfectly when using the "file:///C:/test/test.html" as the URL.=
 Of course, I'd rather not have to refactor my actual app to handle cross-d=
omain ajax requests (and remap the pathing for requests) from file:// to <a=
 href=3D"http://localhost--so" target=3D"_blank">http://localhost--so</a> g=
etting the HTTP Web Server config to work would be ideal.<br><br>On Saturda=
y, September 8, 2012 6:30:41 PM UTC-4, Ryan Ackley wrote:<blockquote class=
=3D"gmail_quote" style=3D"margin:0;margin-left:0.8ex;border-left:1px #ccc s=
olid;padding-left:1ex">So live reload isn't working? When you update the fi=
le in the
<br>filesystem, it's not changing in devtools or is it vice-versa?
<br>
<br>The error message means that Tincr is matching up the file and url
<br>correctly but the contents are different. Is it possible that test.js
<br>is being cached? Can you try going into devtools settings and tick the
<br>Disable Cache checkbox. You can access the devtools settings by
<br>opening the devtools and clicking the gear icon in the lower left
<br>corner.
<br>
<br>On Sun, Sep 9, 2012 at 4:17 AM, Christopher Froehlich
<br>&lt;<a>c...@the-shades.net</a>&gt; wrote:
<br>&gt; I've pulled the latest source from bitbucket and loaded Tincr as a=
n unpacked
<br>&gt; extension (I've also tried using the latest version in the Chrome =
store). I
<br>&gt; have a very thin HTML page with a single JS include. The HTML page=
 has a
<br>&gt; button. The JS fetches the button from the DOM and binds a click e=
vent which
<br>&gt; issues an alert('a mutating string').
<br>&gt;
<br>&gt; When I load the HTML page from the file system, I see changes to t=
he JS file
<br>&gt; in the Sources tab in real time--and my click event is changing dy=
namically
<br>&gt; (without a page refresh) as I change the file. All expected.
<br>&gt;
<br>&gt; However, when I try to use HTTP Web Server config option, I get th=
is error
<br>&gt; in the console:
<br>&gt;
<br>&gt; Content for url <a href=3D"http://localhost/test.js" target=3D"_bl=
ank">http://localhost/test.js</a> matches local file C:\test\test.js
<br>&gt;
<br>&gt; Content for url <a href=3D"http://localhost/test.js" target=3D"_bl=
ank">http://localhost/test.js</a> doesn't match local file
<br>&gt; C:\test\test.js
<br>&gt;
<br>&gt; (anonymous function)
<br>&gt; InjectedScript._evaluateOn
<br>&gt; InjectedScript._<wbr>evaluateAndWrap
<br>&gt; InjectedScript.evaluate
<br>&gt;
<br>&gt;
<br>&gt; My content is no longer updating. Initially, I had my test.html an=
d test.js
<br>&gt; content hosted at "localhost/test/test.html" (physically located a=
t
<br>&gt; c:\test); however, I noticed (by inspecting Tincr and debugging) t=
hat the
<br>&gt; URL parameter passed in was simply "localhost" which could not res=
olve
<br>&gt; "test.html". So I moved my test files to the root of my web site, =
now just
<br>&gt; "localhost/test.html", but I get the same behavior.
<br>&gt;
<br>&gt; I see this thread started at the original group, but it doesn't re=
solve the
<br>&gt; issue.
<br>&gt;
<br>&gt; Any thoughts? I'm on Windows 7x64 using IIS for my webserver and t=
esting in
<br>&gt; Chrome Canary and Chrome Dev.
<br>&gt;
<br>&gt; --
<br>&gt;
<br>&gt;
<br></blockquote></div></blockquote></div></blockquote></div></div></blockq=
uote></div>
------=_Part_653_19213756.1347159499625--

------=_Part_652_27346597.1347159499625--