Register a SA Forums Account here!
JOINING THE SA FORUMS WILL REMOVE THIS BIG AD, THE ANNOYING UNDERLINED ADS, AND STUPID INTERSTITIAL ADS!!!

You can: log in, read the tech support FAQ, or request your lost password. This dumb message (and those ads) will appear on every screen until you register! Get rid of this crap by registering your own SA Forums Account and joining roughly 150,000 Goons, for the one-time price of $9.95! We charge money because it costs us money per month for bills, and since we don't believe in showing ads to our users, we try to make the money back through forum registrations.
 
  • Post
  • Reply
Ciaphas
Nov 20, 2005

> BEWARE, COWARD :ovr:


New Yorp New Yorp posted:

That's reasonable. If you're not using it for anything other than source control and you want to move to Git anyway, just Git-TFS the repo and do a clean install of TFS 2017.2. But if you're not using any of the features beyond source control, there's really zero reason to use TFS in the first place.

Some of the team members are making inroads on build automation and alerting, but no one would die if everything but the current VS solution disappeared. We're all just programmers, none of us are proper administrators.

I'll bring up that maybe TFS can be dumped entirely. I believe at the time it was set up it was considered to be the best option for Windows-based version control. But I would like to be able to set up alerting and automatic builds on checkin to Main, at least, and I'm not sure Git on its own can support that.

Adbot
ADBOT LOVES YOU

Ciaphas
Nov 20, 2005

> BEWARE, COWARD :ovr:


New Yorp New Yorp posted:

That's a good reason to stick with it, then. But hold off on build automation until you're using TFS 2017. A modern build system that doesn't horribly suck was introduced in TFS 2015 and there is no forward compatibility with the TFS 2010 XAML build system.

Will do, thanks. Talked again with my team lead about it, demonstrated that it's difficult/impossible to trail merge changesets back to their constituent branch changesets, and he said (and I quote) "That's retarded, why didn't anyone notice this before?" (He's new to the post too--big old shakeup.) So hopefully soon the paperwork for an upgrade to TFS will be submitted and we can re-evaluate TFVC vs Git at that point.

He did ask, however, if it would be possible to somehow export the changesets and their comments--for what little they were worth, he admitted--out of TFVC 2010, uninstall 2010, install 2017, and re-import them into either TFVC or Git. Any thoughts?

Ciaphas fucked around with this message at 22:30 on Aug 25, 2017

Ciaphas
Nov 20, 2005

> BEWARE, COWARD :ovr:


New Yorp New Yorp posted:

Yeah, use Git-TFS. Git-TFS is two-way -- you can have it suck in TFVC changesets, turn them into a Git repo, then either use the Git repo as-is or point it to a different TFVC repo and have it turn the Git commits back into changesets.

[advertisement] If your company has a budget and wants some expert assistance, PM me. Otherwise, ask here and get it for free, I guess.

And Git-TFS can work on TFS 2010 one way and TFS 2017 the other way? That sounds too good to be true. (And thanks for the free advice :v:)

Ralith posted:

You should be able to set up git hooks to do whatever you want, with sufficient elbow grease. Or use one of the numerous off-the-shelf systems that have such features built in.

In my old group on a Linux server I had Git set up to send an email out on a push to master, but figuring out how to automatically perform a test build and detect failure was beyond me. :(

Ciaphas
Nov 20, 2005

> BEWARE, COWARD :ovr:


In Git parlance (or hell in other VC software) is a Pull Request anything other than a formal way of saying "here's the changes I wanna merge into master/dev/whatever, everyone cool with that"?

Ciaphas
Nov 20, 2005

> BEWARE, COWARD :ovr:


Am I crazy, or is there no way to fetch or push git tags through VS2015? You have to use the command line?

Ciaphas
Nov 20, 2005

> BEWARE, COWARD :ovr:


smackfu posted:

How bad is it to push a large unchanging binary into git? Like a 1 gb database image. I know it's not meant for it but it's our easiest way to share files.

It's not really bad per se, it's just not very efficiently compressed. But if it never changes it'll just make the first clone/pull/push/whatever take longer.

Ciaphas
Nov 20, 2005

> BEWARE, COWARD :ovr:


New Coke posted:

I'm pretty new at Git and I have a problem here I'm not really sure how to resolve. I've done a bunch of work in branch A. I then did a bunch more work in branch B, but because that work touched a bunch of the same files in A, I made B as a branch of A, rather than master.

Now, it turns out I need to merge B into master but omit the changes I made in A. Is there a recommended way of doing this? I've tried to create a patch with all of the commits in A, and apply it to master, but it didn't work very well; there were tons of errors and I spent a long time trying to cobble everything together with a merge tool without success.

As far as I know this is exactly the situation git rebase is meant to solve, maybe make a clone of your repo and go mess with rebases in that until you get it right?

Ciaphas
Nov 20, 2005

> BEWARE, COWARD :ovr:


I'm quietly going insane from CRLF/LF issues that are somehow appearing in an entirely windows shop running Git under TFS. Does anyone know what the correct settings to make this poo poo stop happening are, either in .gitattributes, git config, or VS or TFS themselves?

(ed) While I'm at it is there a way to make TFS2015+ count whitespace-only diffs in a pull request as not-diffs so they don't show up?

Ciaphas
Nov 20, 2005

> BEWARE, COWARD :ovr:


VS throws up a crlf dialog whenever a file is opened

Both team explorer in commits and TFS in pull request insist that tons of files changed but diff in VS/TFS shows either nothing or whitespace only. Git status is correct

Ciaphas fucked around with this message at 20:29 on Mar 22, 2018

Ciaphas
Nov 20, 2005

> BEWARE, COWARD :ovr:


boo_radley posted:

We had this pop up recently. I bet you're got someone issuing the git bash command line, and they chose to override eols.
You might try
git diff --ignore-space-at-eol

Or seeing when things go haywire and yelling with the committing dev.
I'll try this command when I go back upstairs, but the problem is git at the command line is already correct--it's VS and TFS that are misreporting.

And it's happening to everyone--we all get asked to convert by VS when we open files that we haven't modified in the current commit yet, and everyone's getting the same massive amount of fake changes according to Team Explorer.

Worse, I'm the only one on the team who's any good at the Git command line, which also probably means no one has hosed with their configs.

ChickenWing posted:

this is the solution


also for posterity make sure everyone is using the same autocrlf setting
Isn't core.autocrlf completely overridden by the * text=auto setting in .gitattributes?

Ciaphas
Nov 20, 2005

> BEWARE, COWARD :ovr:


The problem seems to be that, for the first commit in a new branch, Visual Studio thinks all of the files in the repo have changed, where the git shell does not. So what the devs are doing (including myself, previously) is committing a bunch of arbitrary whitespace changes of unknown nature introduced by Visual Studio, then when it comes time to do a pull request in TFS, it highlights those as diffs but marks them as whitespace only and provides no option to show the diff so I can see whether the whitespace is line endings or some other thing--and because git can't see it, I have no other way to see the differences.

So. VS Git integration sucks.

I need to learn how to tell VS two things:

1) Stop automatically including changes in a commit. Change it so that the developer has to stage files for commit manually, just like in normal Git. I don't know how to make it do this.
2) Stop making whatever damned changes you're making. I don't know how to do this, either.

Option 3 is telling the developers to stop using the VS integration and start using command line/gitk/git gui, but I can guarantee that will cause a lot of pushback and frankly I'd rather not do it anyway (rebasing is much easier in VS for example).

Ciaphas
Nov 20, 2005

> BEWARE, COWARD :ovr:


New Yorp New Yorp posted:

I'm assuming this is VS2015? VS2017 is better about a lot of this stuff, if for no other reason than they're transitioning everyone in the company to using Git and dogfooding all of this stuff, so if VS's Git client sucks, the VS team hears about it.

(but yes, VS's Git client has traditionally been awkward at best)

Yeah, this is 2015. We're getting the latest version of 2017 Soon® (pending security approval, airgapped network etc).

I think what I might do is tell everyone to just stop using the Team Explorer window in VS entirely and give a crash course tomorrow on git gui while walking around and fixing everyone's topic branches after I do whatever the gently caress I gotta do to fix the problem forevermore in master. At least there's only four of us, including me.

What would you recommend for settings in the future? Repos created via cloning in VS's team explorer window seem to always have core.autocrlf=true, which makes sense since it's a Windows product, but then what happens when you're doing edits in vim or whatever in the git bash mingw window? Do LFs sans CRs get reintroduced? Either way, perhaps the better option is to set * text=auto in .gitattributes, do a big Fix Everything commit in master, let Git internalize everything as LF and checkouts can be whatever the developer's system is, and be done with it?

Ciaphas fucked around with this message at 00:32 on Mar 23, 2018

Ciaphas
Nov 20, 2005

> BEWARE, COWARD :ovr:


ChickenWing posted:

Yeah this was what made it click for me too. Every time I did something with git and was all "wow this is actual real magic" my tech lead just replied "git is a graph and you are just doing things to the graph" and then one day I was like "oh right that makes sense" and now I am the office git guy :sun:

:same: re being the office git guy, which leads into my question for the day:

What do we like right now as far as on-premises web-based Git project hosting?

Only just got tasked with looking into this semi-officially but here's the bullet points I have so far
- must NOT require internet access in any form like for licensing or whatever (airgapped network)
- must allow access control/registration via LDAP
- must at least support branch locking/requiring peer review and pull requests
- preferably something with an easily-downloaded trial so I can do a quick evaluation on our online network then easily sneakernet it over
- free is nice and OSS is even better, but not required
- prefer to be something one guy can manage with maybe a half a day a week when things are working for administration tasks

(edit) We already have Team Foundation up and running for us with Git, and I suppose we could make that work company-wide, but the company isn't primarily a Windows shop by any stretch. How much poo poo would not work for teams hosting non-Windows software

Ciaphas fucked around with this message at 23:22 on May 17, 2018

Ciaphas
Nov 20, 2005

> BEWARE, COWARD :ovr:


Frankly I'm not even really sure what CI and CD are except they stand for continuous integration and deployment respectively?? But our deployment process is 100% unautomatable anyway :(

Ciaphas
Nov 20, 2005

> BEWARE, COWARD :ovr:


The Fool posted:

I bet you’re wrong about that


E: to answer your question, CI is the code side of things, VCS and automated testing, CD is the build and release/deploy side

seeing as sneakernet is involved virtually immediately after pressing F6 in VS, it really isn't :v: ('til the robot revolution comes, anyway)

Thanks for explaining the acronyms though. As usual in this profession it seems like I learn what things are long before realizing they have acronyms or fancy million dollar words (see: me and dependency injection)

Ciaphas
Nov 20, 2005

> BEWARE, COWARD :ovr:


Thermopyle posted:

But does it have to involve sneakernet? Like, is it a literal requirement of your system that you can't have a network cable run from the PC building your project?

At the level where I can do anything about it? Yep :(

Ciaphas
Nov 20, 2005

> BEWARE, COWARD :ovr:


boo_radley posted:

:sever:

Life's too short to waste your time like that

Someday, when I have the courage and will to uproot to a new town. Someday.
if i just keep telling myself that it makes it not hurt so much

Adbot
ADBOT LOVES YOU

Ciaphas
Nov 20, 2005

> BEWARE, COWARD :ovr:


boo_radley posted:

Come to Denver. I'm can water your time I'm s much more efficient way.

speech to text and autocorrect translation: "I can waste your time in a much more efficient way". amuses me that that's a useful skill to learn nowadays :v:

but yeah being a denizen of las vegas, denver is high on my list if i ever work up the guts to apply let alone interview let alone say goodbye to the lovable dorks I work with

  • 1
  • 2
  • 3
  • 4
  • 5
  • Post
  • Reply