<div class="gmail_quote">You are both right, the hooks are already in any clone, and I would use origin. If you leave the VTK submodule pointing at our servers, then how do you handle git submodule update for ParaView? If you are not handling that, then I would assume VTK is on a (no branch) and not pulling master, nor being actively developed?</div>
<div class="gmail_quote"><br></div><div class="gmail_quote">VTK is aware of its inclusion in a ParaView build, and so some special handling could be put in place. I think we could actually instruct it to use the ParaView hooks by going up another directory. Alternatively you could set the flag to disable hooks checks in VTK, but not ParaView. To permanently disable the hooks check in a clone you could also touch .git/hooks/.git/config, this would make the test pass in that particular clone.</div>
<div class="gmail_quote"><br></div><div class="gmail_quote">Marcus</div><div class="gmail_quote"><br></div><div class="gmail_quote">On Thu, Jul 1, 2010 at 9:46 AM, Stephane PLOIX <span dir="ltr"><<a href="mailto:stephane.ploix@edf.fr">stephane.ploix@edf.fr</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
<br><font size="2" face="sans-serif">True if the solution proposed by Marcus
is to use the "origin" from git to get the hooks. This is not
the case for the submodules for instance : by default, they point to kitware's
native repos, and have to be reconfigured to point to the internals clones
with commands like </font>
<br><font size="2" face="sans-serif">>>>git config submodule.VTK.url
git://my-internal-VTK-clone<br>
It would be nice if we could simply clone the main paraview repo and get
a fully functionnal mirror with everything self-contained : submodules,
hooks, etc... instead of having to have special commands for each and every
new git functionnality.</font>
<br>
<br><div><div class="h5"><font class="Apple-style-span" face="sans-serif"><br></font>
<br><font size="2" face="Calibri">This whole “safe” area business should
be a nonissue. If you have cloned the main repository from Kitware,
you get a copy of the hooks branch in your local repository along with
the other branches. Since the data is taken from your local repository,
no network access should be necessary and the instructions should not change
for a safe area, right?<br>
<br>
-Ken<br>
<br>
<br>
On 7/1/10 1:46 AM, "Stephane PLOIX" <</font><a href="http://stephane.ploix@edf.fr" target="_blank"><font size="2" color="blue" face="Calibri"><u>stephane.ploix@edf.fr</u></font></a><font size="2" face="Calibri">>
wrote:<br>
</font>
<br><font size="2" face="Calibri"><br>
I am exactly in the case described by Berk, but I would like to push the
point further. Inside the "safe area", we have replicated all
the testing/dashboard mechanism, and it would be nice if the proposed mechanism
could be configured so that the instructions and redirection to download
the hooks can be modified, instead of only having a solution to turn it
off. This way, any developer inside the safe area will have to use the
hooks as they should, without having to go out of the safe area. <br>
<br>
Stephane<br>
<br>
<br>
</font><img src="cid:_1_09A0709009A06AA0004B95DAC1257753"><font size="2" face="Calibri"> </font><font size="2" color="#ff8100" face="Arial"><b><br>
Stephane PLOIX<br>
Pilote Opérationnel - Visualisation scientifique</b></font><font size="2" color="#0062e1" face="Arial"><br>
EDF - R&D<br>
SINETICS<br>
1, Av du Général de Gaulle<br>
92140 Clamart</font><font size="2" color="#0062e1" face="Calibri"><br>
</font><font size="2" color="blue" face="Arial"><b><u><br>
</u></b></font><a href="http://stephane.ploix@edf.fr" target="_blank"><font size="2" color="blue" face="Arial"><b><u>stephane.ploix@edf.fr</u></b></font></a><font size="2" face="Calibri">
</font><font size="2" color="#0062e1" face="Arial"><br>
Tél. : +33 (0) 1 47 65 51 10</font><font size="2" face="Calibri"> <br>
</font><img src="cid:_1_09A076EC09A06AA0004B95DAC1257753"><font size="2" color="#0062e1" face="Arial">Un
geste simple pour l'environnement, n'imprimez ce message que si vous en
avez l'utilité.</font><font size="2" face="Calibri"> <br>
<br>
<br>
</font><font size="2" color="blue" face="Calibri"><b><u><br>
</u></b></font><a href="http://marcus.hanwell@kitware.com" target="_blank"><font size="2" color="blue" face="Calibri"><b><u>marcus.hanwell@kitware.com</u></b></font></a><font size="2" face="Calibri">
</font><font size="2" face="Calibri"><br>
Envoyé par : </font><a href="http://vtk-developers-bounces@vtk.org" target="_blank"><font size="2" color="blue" face="Calibri"><u>vtk-developers-bounces@vtk.org</u></font></a><font size="2" face="Calibri">
</font><font size="2" face="Calibri">30/06/2010 20:13</font><font size="2" face="Calibri">
</font>
<div align="right">
<p><font size="2" face="Calibri">A </font></p></div>
</div></div><p></p><div><div></div><div class="h5"><a href="http://berk.geveci@kitware.com" target="_blank"><font size="2" color="blue" face="Calibri"><u>berk.geveci@kitware.com</u></font></a><font size="2" face="Calibri">
</font>
<div align="right">
<p><font size="2" face="Calibri">cc </font></p></div>
</div></div><p></p><div><div></div><div class="h5"><a href="http://vtk-developers@vtk.org" target="_blank"><font size="2" color="blue" face="Calibri"><u>vtk-developers@vtk.org</u></font></a><font size="2" face="Calibri">,
</font><a href="http://kmorel@sandia.gov" target="_blank"><font size="2" color="blue" face="Calibri"><u>kmorel@sandia.gov</u></font></a><font size="2" face="Calibri">
</font>
<div align="right">
<p><font size="2" face="Calibri">Objet </font></p></div>
</div></div><p></p><div><div></div><div class="h5"><font size="2" face="Calibri">Re: [vtk-developers] Auto install git hooks</font><font size="2" face="Calibri">
<br>
<br>
<br>
<br>
</font><font size="4" face="Calibri"><br>
On Wed, Jun 30, 2010 at 2:06 PM, Berk Geveci <</font><a href="http://berk.geveci@kitware.com" target="_blank"><font size="4" color="blue" face="Calibri"><u>berk.geveci@kitware.com</u></font></a><font size="2" face="Calibri">
<</font><a href="mailto:berk.geveci@kitware.com" target="_blank"><font size="2" color="blue" face="Calibri"><u>mailto:berk.geveci@kitware.com</u></font></a><font size="2" face="Calibri">>
</font><font size="4" face="Calibri">> wrote:</font><font size="2" face="Calibri">
</font><font size="4" face="Calibri"><br>
I am joining this argument a bit late so I apologize if I misunderstand.</font><font size="2" face="Calibri">
<br>
</font><font size="4" face="Calibri"><br>
The solution that Marcus et al. are proposing will have no effect if someone
is building from a source that does not contain a .git directory, correct?
If not, it should be. Those have no interest in developing VTK/ParaView/ITK/CMake
whatever should not clone the git repository. Instead, they should download
a tarball/zip. Keep in mind that github/gitorious etc. all have the ability
of generating an archive of the repository at any point in time. We should
encourage users to use it rather than clone the git repo (which requires
installing git and all). Similarly, if a developer is to send a user a
snapshot, that developer should not include the .git directory in that
snapshot. </font><font size="2" face="Calibri"><br>
</font><font size="4" face="Calibri"><br>
If it is not a clone, then no checks are performed. So if the user downloads
a tarball (or otherwise removes the .git/config in the root source directory),
then they will never see the error. </font><font size="2" face="Calibri"><br>
</font><font size="4" face="Calibri"><br>
My biggest concern is for developers that clone a repo and then take it
to a safe area to build. At that point, they will not have access to network.
So we should have a way to bypass anything that requires network access.</font><font size="2" face="Calibri">
<br>
</font><font size="4" face="Calibri"><br>
There is an option, the can be set in the CMake cache to skip the check.
In Titan it is called Titan_IGNORE_HOOKS, defaults to off but if set to
on bypasses the hooks check.</font><font size="2" face="Calibri"> <br>
</font><font size="4" face="Calibri"><br>
Marcus</font><font size="2" face="Calibri"> <br>
</font><font size="4" face="Calibri"><br>
On Wed, Jun 30, 2010 at 12:40 PM, Wes Turner <</font><a href="http://wes.turner@kitware.com" target="_blank"><font size="4" color="blue" face="Calibri"><u>wes.turner@kitware.com</u></font></a><font size="2" face="Calibri">
<</font><a href="mailto:wes.turner@kitware.com" target="_blank"><font size="2" color="blue" face="Calibri"><u>mailto:wes.turner@kitware.com</u></font></a><font size="2" face="Calibri">>
</font><font size="4" face="Calibri">> wrote:</font><font size="2" face="Calibri">
</font><font size="4" face="Calibri"><br>
I will continue to respectfully disagree. Not every user has the
ability to be a developer. Intentionally breaking the build process
for exactly those people who will never make a checkin and who are most
likely to drop use of the toolkit when they it gets too complex or they
get annoyed seems like a bad idea. </font><font size="2" face="Calibri"><br>
</font><font size="4" face="Calibri"><br>
That said, I had my say and will follow the madding crowd. :-)</font><font size="2" face="Calibri">
<br>
</font><font size="4" color="#8f8f8f" face="Calibri"><br>
- Wes</font><font size="2" face="Calibri"> </font><font size="4" face="Calibri"><br>
</font><font size="2" face="Calibri"><br>
</font><font size="4" face="Calibri"><br>
On Wed, Jun 30, 2010 at 11:15 AM, Moreland, Kenneth <</font><a href="http://kmorel@sandia.gov" target="_blank"><font size="4" color="blue" face="Calibri"><u>kmorel@sandia.gov</u></font></a><font size="2" face="Calibri">
<</font><a href="mailto:kmorel@sandia.gov" target="_blank"><font size="2" color="blue" face="Calibri"><u>mailto:kmorel@sandia.gov</u></font></a><font size="2" face="Calibri">>
</font><font size="4" face="Calibri">> wrote:</font><font size="2" face="Calibri">
<br>
If I may, I’ll repeat David’s sentiments a bit more gently.<br>
<br>
You would get around this problem if you sent to your customer an archive
instead of a git url. Instructing your customer (as you describe
him/her) to fetch the latest snapshot from the archive is a bad idea all
around. First, it adds further complication to the build process
(get git and learn it well enough to clone a repo), which you said yourself
is already too onerous. Second, it invites the inevitable problem
that your customer will get a version of VTK that is different than yours
and with something committed that breaks your software.<br>
<br>
Will this unnecessarily effect someone somewhere? I will concede
that it probably will, but it will be a small percentage of all VTK users
and, amortized amongst us all, will save much more time than will be lost.<br>
<br>
-Ken <br>
<br>
<br>
<br>
On 6/30/10 8:49 AM, "David Cole" <</font><a href="http://david.cole@kitware.com" target="_blank"><font size="2" color="blue" face="Calibri"><u>david.cole@kitware.com</u></font></a><font size="2" face="Calibri">
<</font><a href="http://david.cole@kitware.com/" target="_blank"><font size="2" color="blue" face="Calibri"><u>http://david.cole@kitware.com/</u></font></a><font size="2" face="Calibri">>
> wrote:<br>
<br>
The point here is:<br>
- anybody using the VTK git repository should have the hooks installed
locally, so that commits they make have a snowball's chance of being merge-able
into the main repo<br>
- if they don't have the hooks installed, then when they run cmake on VTK's
CMakeLists.txt file, it should:<br>
-- automatically install the hooks for you if possible<br>
or<br>
-- be a fatal configure time error with instructions on how to install
the hooks<br>
<br>
Period. If I were doing this, there wouldn't even be an option to turn
it off. Marcus is being more than generous here even providing that level
of control.<br>
<br>
If they can't handle that, they shouldn't be using VTK via git. They should
stick to releases / tarballs that do not have a .git repo in the tree.<br>
<br>
There's no such thing as a "user" of a library. They're developers.
They can handle installing hooks.<br>
<br>
<br>
Just my opinion,<br>
David C.<br>
<br>
<br>
On Wed, Jun 30, 2010 at 8:57 AM, Wes Turner <</font><a href="http://wes.turner@kitware.com" target="_blank"><font size="2" color="blue" face="Calibri"><u>wes.turner@kitware.com</u></font></a><font size="2" face="Calibri">
<</font><a href="http://wes.turner@kitware.com/" target="_blank"><font size="2" color="blue" face="Calibri"><u>http://wes.turner@kitware.com/</u></font></a><font size="2" face="Calibri">>
> wrote: <br>
How much more complicated does this make the initial build process for
a naive user who checked out VTK and just wants to compile/run it? Every
time I send code to a customer, I invariably end up on a t-con where
I need to walk them through the process of building the toolkits. This
holds even for otherwise technologically savvy people. The frustration
level on their end can be quite high, even when we prime them for this
possibility. Similarly, we got blasted on this in a paper submission where
the reviewer just wasn't willing to try out the Lesion Sizing Toolkit because
the install/build procedures for ITK/LSTK were too high. If the intent
here is to make anyone who downloads VTK via git jump through another set
of hoops to get up and running, then I think it is a bad idea. I
am happy explaining away warnings, however, so making it a warning would
be fine. I would also be fine with adding something in for people
who claim up front that they want to upload back to the repository.<br>
<br>
- Wes<br>
<br>
On Tue, Jun 29, 2010 at 6:19 PM, Moreland, Kenneth <</font><a href="http://kmorel@sandia.gov" target="_blank"><font size="2" color="blue" face="Calibri"><u>kmorel@sandia.gov</u></font></a><font size="2" face="Calibri">
<</font><a href="http://kmorel@sandia.gov/" target="_blank"><font size="2" color="blue" face="Calibri"><u>http://kmorel@sandia.gov/</u></font></a><font size="2" face="Calibri">>
> wrote: <br>
That sounds pretty good to me.<br>
<br>
-Ken<br>
<br>
<br>
<br>
On 6/29/10 2:27 PM, "Marcus D. Hanwell" <</font><a href="http://marcus.hanwell@kitware.com" target="_blank"><font size="2" color="blue" face="Calibri"><u>marcus.hanwell@kitware.com</u></font></a><font size="2" face="Calibri">
<</font><a href="http://marcus.hanwell@kitware.com/" target="_blank"><font size="2" color="blue" face="Calibri"><u>http://marcus.hanwell@kitware.com/</u></font></a><font size="2" face="Calibri">>
<</font><a href="http://marcus.hanwell@kitware.com/" target="_blank"><font size="2" color="blue" face="Calibri"><u>http://marcus.hanwell@kitware.com</u></font></a><font size="2" face="Calibri">
<</font><a href="http://marcus.hanwell@kitware.com/" target="_blank"><font size="2" color="blue" face="Calibri"><u>http://marcus.hanwell@kitware.com/</u></font></a><font size="2" face="Calibri">>
> > wrote:<br>
<br>
So, I was thinking about this over the weekend, and talked to Brad King.
There is an environment variable that is set by CTest when it drives the
build. I can check if that variable is defined, and know that CTest is
driving the build.<br>
<br>
If I did that then when a user first configures VTK CMake will print an
error with copy/paste instructions to check out the local hooks (along
with a link to the wiki). They can set a CMake cache variable to ignore
the hooks to get past it if they wish. If you are not in a git checkout
the whole process is skipped.<br>
<br>
If CTest invoked the configure then the environment variable is set, and
so the error is not raised - negating the need to set a cache variable
on all of the dashboard machines. The only assumption is that CTest is
driving the build, which I think is reasonable. I tested the logic out
in Titan and it looks good.<br>
<br>
Does this cover all of your requirements reasonably? I will be checking
this code into Titan as I think it is an improvement on what we had there
too. I would be happy to check the relevant portion into VTK.<br>
<br>
Marcus<br>
<br>
On Thu, Jun 17, 2010 at 6:33 PM, Moreland, Kenneth <</font><a href="http://kmorel@sandia.gov" target="_blank"><font size="2" color="blue" face="Calibri"><u>kmorel@sandia.gov</u></font></a><font size="2" face="Calibri">
<</font><a href="http://kmorel@sandia.gov/" target="_blank"><font size="2" color="blue" face="Calibri"><u>http://kmorel@sandia.gov/</u></font></a><font size="2" face="Calibri">>
<</font><a href="http://kmorel@sandia.gov/" target="_blank"><font size="2" color="blue" face="Calibri"><u>http://kmorel@sandia.gov</u></font></a><font size="2" face="Calibri">
<</font><a href="http://kmorel@sandia.gov/" target="_blank"><font size="2" color="blue" face="Calibri"><u>http://kmorel@sandia.gov/</u></font></a><font size="2" face="Calibri">>
> > wrote: <br>
<br>
In short, a pushurl is not a good indication of whether commits will be
made or whether those commits will eventually be pushed to the main repository.<br>
<br>
-Ken<br>
<br>
<br>
<br>
On 6/17/10 2:46 PM, "Marcus D. Hanwell" <</font><a href="http://marcus.hanwell@kitware.com" target="_blank"><font size="2" color="blue" face="Calibri"><u>marcus.hanwell@kitware.com</u></font></a><font size="2" face="Calibri">
<</font><a href="http://marcus.hanwell@kitware.com/" target="_blank"><font size="2" color="blue" face="Calibri"><u>http://marcus.hanwell@kitware.com/</u></font></a><font size="2" face="Calibri">>
<</font><a href="http://marcus.hanwell@kitware.com/" target="_blank"><font size="2" color="blue" face="Calibri"><u>http://marcus.hanwell@kitware.com</u></font></a><font size="2" face="Calibri">
<</font><a href="http://marcus.hanwell@kitware.com/" target="_blank"><font size="2" color="blue" face="Calibri"><u>http://marcus.hanwell@kitware.com/</u></font></a><font size="2" face="Calibri">>
> <</font><a href="http://marcus.hanwell@kitware.com/" target="_blank"><font size="2" color="blue" face="Calibri"><u>http://marcus.hanwell@kitware.com</u></font></a><font size="2" face="Calibri">
<</font><a href="http://marcus.hanwell@kitware.com/" target="_blank"><font size="2" color="blue" face="Calibri"><u>http://marcus.hanwell@kitware.com/</u></font></a><font size="2" face="Calibri">>
> > wrote:<br>
<br>
On Thu, Jun 17, 2010 at 4:40 PM, Clinton Stimpson <</font><a href="http://clinton@elemtech.com" target="_blank"><font size="2" color="blue" face="Calibri"><u>clinton@elemtech.com</u></font></a><font size="2" face="Calibri">
<</font><a href="http://clinton@elemtech.com/" target="_blank"><font size="2" color="blue" face="Calibri"><u>http://clinton@elemtech.com/</u></font></a><font size="2" face="Calibri">>
<</font><a href="http://clinton@elemtech.com/" target="_blank"><font size="2" color="blue" face="Calibri"><u>http://clinton@elemtech.com</u></font></a><font size="2" face="Calibri">
<</font><a href="http://clinton@elemtech.com/" target="_blank"><font size="2" color="blue" face="Calibri"><u>http://clinton@elemtech.com/</u></font></a><font size="2" face="Calibri">>
> <</font><a href="http://clinton@elemtech.com/" target="_blank"><font size="2" color="blue" face="Calibri"><u>http://clinton@elemtech.com</u></font></a><font size="2" face="Calibri">
<</font><a href="http://clinton@elemtech.com/" target="_blank"><font size="2" color="blue" face="Calibri"><u>http://clinton@elemtech.com/</u></font></a><font size="2" face="Calibri">>
> > wrote: <br>
<br>
Can you key off the existence of a pushurl?<br>
But I also wonder how this would keep the hooks updated? <br>
<br>
We could possibly be clever and do a little regex to check for the git@
form of the url/pushurl. I hadn't considered being that sneaky, but it
sound like a viable approach and would ease the dashboard pain.<br>
<br>
Marcus <br>
<br>
On Thursday, June 17, 2010 02:13:37 pm Marcus D. Hanwell wrote:<br>
> On Thu, Jun 17, 2010 at 4:06 PM, Moreland, Kenneth <</font><a><font size="2" color="blue" face="Calibri"><u>kmorel@sandia.gov>wrote</u></font></a><font size="2" face="Calibri">:<br>
> > That’s a good point about CMake modifying the source tree,
but I think<br>
> ><br>
> > this is one of those cases we should let the rule slide. In
this case we<br>
> > are installing what, IMHO, git should be pulling for us. Although
the<br>
> > Wiki says its optional, it really should be enforced for anyone
who<br>
> > makes any commit to any repository.<br>
><br>
> We came to a similar conclusion in Titan, but I am not sure about
letting<br>
> the rule slide. This is new territory though, and it is just my take<br>
><br>
> > I’m less thrilled about the “error if not installed” option
because it<br>
> > still pushes the responsibility back on every developer. It
could also<br>
> > wreck havoc on the dashboards as there will be a delay in getting
someone<br>
> > to fix the warning. But if that is the general consensus,
it’s way<br>
> > better than what we have now, which is nothing. If that
is the path we<br>
> > choose to<br>
> ><br>
> > follow, then I would hope that the following could be be features:<br>
> > - CMake be very insistent about installing the hooks.
It should not<br>
> > be easy to miss or ignore the error.<br>
> > - The error should give clear instructions on how
to install the<br>
> > hooks.<br>
> ><br>
> > It’s annoying to have to find it in the Wiki every
time.<br>
> ><br>
> > - The check should also look for any updates to
the hooks in addition<br>
> > to just seeing if they are installed. One
of the problems I run into<br>
> > is that even though I try to be diligent about installing
hooks, I<br>
> > miss changes pushed to the repository.<br>
> > - The check should turn itself off if not run in
a git repository. A<br>
> > user who downloaded the source from the web would
never be able to<br>
> > satisfy the requirement.<br>
><br>
> The checks in Titan have all but the third feature. That would be
a<br>
> valuable general addition though, and I think there is some code floating<br>
> around that could help us to accomplish this. It would be good to
hear how<br>
> others feel about this, but we should certainly be making these things
as<br>
> easy as possible for our developers. I will see what our software
process<br>
> type people think - Brad, Dave, Bill?<br>
><br>
> Marcus<br>
> --<br>
> Marcus D. Hanwell, Ph.D.<br>
> R&D Engineer, Kitware Inc.<br>
> (518) 881-4937 <br>
<font class="Apple-style-span" face="arial"><font class="Apple-style-span" face="Calibri"><br></font></font></font></div></div></blockquote></div>