|
|
|
![]() |
|
|||||||
|
||||||||
![]() |
| Thread Tools |
Rating:
|
Display Modes |
|
#16
|
|||
|
|||
|
Re: C and LabView version control with Git
Quote:
Additionally, if when "merging" it is actually only taking one version (%A) and discarding/ignoring the conflicting version (%B) and the common base (%O), that would indicate it isn't actually merging anything, since Git expects the merged result to be written to the local copy with changes (the %A). I could just be getting the argument order mixed up, but I don't think so. |
|
#17
|
||||
|
||||
|
Re: C and LabView version control with Git
Quote:
Quote:
-Tanner |
|
#18
|
||||
|
||||
|
Re: C and LabView version control with Git
For some reason, I don't have a LVCompare.
Had to change the binary line to this for it to execute: Code:
git config --system merge.labview.recursive binary If I have this in my .gitconfig for the diff, Code:
[diff "labview"] command = "C:/Program Files/meta-diff suite/lvdiff.exe" #command = 'C:/Users/Tanner/Desktop/FIRST 2010 Beta/lvcompare.sh' Still get the same thing for merging. The little error dialog does spend some time being open, but I can't find anything else open. When I did it, it didn't seem to merge anything, just use the last commit out of the two branches I merged. -Tanner |
|
#19
|
|||
|
|||
|
Re: C and LabView version control with Git
Quote:
Try prepending "echo" to the driver too, to see exactly what it is calling. It should be giving LVMerge a set of three temporary files to evaluate then write back. Maybe you want to try it by hand too, check the NI documents I linked to. Google suggests that no one has ever tried using Git and LabView together before, or, everyone else has just gotten it right the first time. In any event it doesn't appear to be a heavily used feature of LabVIEW.Maybe it is also the case that you have to use \\ or / instead of a single \ (though it looks like you have tried that). |
|
#20
|
||||
|
||||
|
Re: C and LabView version control with Git
Quote:
Quote:
Echo'ing the merge, does have 4 files, though their names aren't really specific (.merge_file_a03232). Quote:
In the absence, of LVCompare, I've almost got lvdiff working, though the LabVIEW vi they use is currently yelling at me for missing some file (though it is very vague on that as well). Looking a Perforce, seems you can get a free 2-user copy. Exciting. *sigh* Guess it just wasn't meant to be? -Tanner |
|
#21
|
|||
|
|||
|
Re: C and LabView version control with Git
Quote:
For merge, you could try it by hand, see if it writes a new file. If you make one change to a base file, save as A, and then a different one to the base file, save as B, then merge base, A, and B out to C. It could also be that the merge tool doesn't overwrite existing files, in that case you need a shell script that can rename the %A file to something else, perhaps like "mv %A %A.old; LVMerge $O $B %A.old %A; rm %A.old" or something like that (I don't know if that would work the way I think it would, especially on Windows). |
|
#22
|
||||
|
||||
|
Re: C and LabView version control with Git
Quote:
Quote:
Quote:
I wonder if any of the LabVIEW devs know anything about using Git and all the such. -Tanner |
|
#23
|
|||
|
|||
|
Re: C and LabView version control with Git
Quote:
It sounds like you are having issues getting the LV diff and merge tools to integrate into Git. I was actually going to look at it from the opposite direction, and use the command line interface to Git so that it could be invoked for check out, in, etc. I won't get to look at it until next weekend at the earliest. Greg McKaskle |
|
#24
|
||||
|
||||
|
Re: C and LabView version control with Git
Quote:
Quote:
Thanks -Tanner |
|
#25
|
|||
|
|||
|
Re: C and LabView version control with Git
As Greg McKaskle pointed out earlier you can implement "providers" that let you (if I understand correctly) run simple commands like commit, checkout a revision/file, etc, many IDEs have something similar. I didn't bring it up because I can't find much documentation on it... but that would be another great thing to tackle after merging gets working. It looks like it would be under Tools, Source Control, Configure Source Control. There are a few quirks that might not be anticipated, like Git's index if you are trying to commit files (whereas other version control systems use "add" to introduce new files only and "commit" to scan for changes in already added files then commit everything they find, "git add" is used for both new content and changed content, it adds those changes to an "index", and "git commit" simply turns that index/stage into a new commit, making the process very flexible and fast). In general it seems like there is no problem using something like LabView with a distributed version control system, any more than any other problem that a graphical language presents.
|
|
#26
|
||||
|
||||
|
Re: C and LabView version control with Git
I posted on a few LabVIEW forums and it seems that Git isn't widely used. SVN seems to be the free tool of choice, which kinda stinks for having a distributed system.
-Tanner |
|
#27
|
|||
|
|||
|
Re: C and LabView version control with Git
I got LVDiff and LVMerge to work with Mercurial, which isn't too different from Git. I am in the process of writing a white paper on the matter. For now you might want to try my modified version of LVDiff (That's the beauty of GPL), available here. It takes only two arguments, the paths to the VIs to be diffed.
|
|
#28
|
||||
|
||||
|
Re: C and LabView version control with Git
Quote:
-Tanner |
|
#29
|
|||
|
|||
|
Re: C and LabView version control with Git
I can't get it to even write a file. The dialog shows "Error 7" (meaning File does not exist) unless I supply the absolute file path, when I do that it shows success, but still fails to write a file anyways. When I use the UI front end it works as expected and generates an unsaved file which you have to save by hand. I would step through the program to see why it isn't writing the file supplied on the command line, but the source is encrypted, so I'm at a loss.
It looks like writing a source control provider involves more work than just supplying commands to run, so that's out of the question for the short term. In other news I updated the document with pretty graphs illustrating various workflows that would be useful for a team, as well as adding a section on Java/NetBeans, and expanding the section for WindRiver Workbench (which is just Eclipse, which in turn was written as a Java IDE, I don't see why they don't just use Eclipse, but that's another question for another thread). |
|
#30
|
|||
|
|||
|
Re: C and LabView version control with Git
I have LVmerge working with tortisegit after following this tutorial for tortisesvn
Link Can someone explain to me what lvdiff is needed for? Does lvmerge include lvdiff? |
![]() |
| Thread Tools | |
| Display Modes | Rate This Thread |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| 2009 Control System LabVIEW Tips and Pitfalls | Travis Hoffman | NI LabVIEW | 3 | 22-12-2008 11:25 |
| LabVIEW Training and new control system demonstration 10/17-10/19 in Frazier Park, CA | Joe Ross | NI LabVIEW | 0 | 25-09-2008 13:25 |
| First problems with FTC and Labview | PhilBot | National Instruments LabVIEW and Data Acquisition | 0 | 10-09-2008 20:21 |
| Labview and communication with peripheral device help | jaijaidin | LabView and Data Acquisition | 3 | 26-01-2007 19:17 |
| version control and linux | shtylman | Programming | 2 | 01-05-2006 17:44 |