|
> I need to know ...
Beware of the square peg round hole issue here. Git was 'designed' because of the limitations of the command and control methods when used in software development.
In some ways "Agile" is a similar response to the difficulties that command and control methods experience.
Git itself is agnostic to the management method, and includes flexible working approaches. It also include `git stash` should you have to redirect developer work at very short notice to 'drop every thing and fix this NOW'.
Don't try to solve / pre-plan everything at once. Start 'small' by at least just creating a git repo of what you have got.
Maybe think about copying/transferring existing history to git and explore that to get a feel about the quality of the previous system.
Any new system will feel awkward, don't let it become a 737MAX.
|
|
|
|
|
Quote: You get to see what they've done only when they make a pull request or, God forbid, when they push their changes to the main repository.
Why "God forbid"? Where else other than the remote do you want them to push changes to? You're supposed to push to the remote, you're just not supposed to push to remote/main (or remote/master).
Quote: Given that your team is just starting with git I'd suggest to have only one person with write access to the main repository.
I get the feeling that by "main repository" you mean either "main branch" or "remote repository", but I can't tell which it is. "Main repository" is a phrase with no meaning in git.
|
|
|
|
|
Going from the end to clarify what I mean:
Quote: I get the feeling that by "main repository" you mean either "main branch" or "remote repository", but I can't tell which it is. Let's assume the organization ACMECompany has an account with a Git provider, consider Bitbucket for the sake of argument. Then the project repository will be git@bitbucket.org:ACMECompany/BigProject.git . This is what I call the main repository because everything useful should end up in there.
Quote: Why "God forbid"? Where else other than the remote do you want them to push changes to? You, as a developer, make a clone of that repository and it will reside at git@bitbucket.org:Developer/BigProject.git . You add a wonderful new feature and you are ready to send it home. You send a pull request to the person responsible of BigProject and now different things could happen:
- if it's a small change or something he can immediately validate, he will push it in the main branch (formerly called master branch).
- if it's something where other people need to contribute, either to validate or to further develop, he will push it on a new branch and other developers or testers will pull the new branch, do their work and make new pull requests when finished.
In the end the person in charge will merge the new branch into the main branch.
Quote: You're supposed to push to the remote, you're just not supposed to push to remote/main (or remote/master). I know there is an alternate workflow where all developers are allowed to push in the main repository and it works based on an honor system where each one promises to merge into the main branch only stuff that has been thoroughly tested and never make any mistake. However I'm an old, cynical developer who believes that only what you cannot touch you cannot harm
I also know that both Bitbucket and Github have branch permissions where you can limit who can commit on the main branch but somehow, working only on the main repository, makes me a bit less comfortable. The workflow I described does not depend on any particular Git provided and can be used anywhere.
Mircea
|
|
|
|
|
Quote: I know there is an alternate workflow where all developers are allowed to push in the main repository and it works based on an honor system where each one promises to merge into the main branch only stuff that has been thoroughly tested and never make any mistake. However I'm an old, cynical developer who believes that only what you cannot touch you cannot harm
So? What does "main repository" have to do with that? My team all works off one repo, no one (not even me) is allowed to push to master, everyone works of branches from that one repo, there is no "main repository", there is only one repository that has /master changeable only via PRs from branches on that repository.
I don't know what multiple repositories have to do with protection. We use branches for that, not an honor system.
|
|
|
|
|
Member 13301679 wrote: I don't know what multiple repositories have to do with protection. We use branches for that, not an honor system.
AFAIK branch protection is not a Git feature. Different Git providers implement it in different ways. If that works for you and your team, that's great.
Mircea
|
|
|
|
|
Quote: The thing is though that I need to know what others are doing in branches they have made on their local machines that aren't on the repository
Well, as long as they perform a "git push" once a day (I do pushes maybe every 60m or so), you'll see what's been last committed to a particular branch using any git client (I've heard good things about gitkraken, but bad things about their licence), even the plain old command-line one will present an ascii-art (colored) branch diagram which is easily understood.
Quote: Not so much details, but so that we all know who is doing something so we will be careful to work together.
There's no need to be - this isn't like TFS or CVS or Subversion where you can step on each other's toes and only find out months later, or where conflicts are a pain in the rear to address.
Let's say a new issue comes up - "Implement Baz into the Fob". Dev-A gets assigned to do it. You create a new branch of the current pre-release branch called "feature/baz-into-fob", and tell Dev-A to pull that branch and make his changes.
New issue comes up - "Implement Squiz into Fob". Dev-B gets assigned to do it. You create a new branch of the current pre-release called "feature/quiz-into-fob", and tell Dev-B to pull that branch and make her changes.
Now, daily, as those two devs are working, they will commit+push their respective branches. This lets anyone else (with the correct access) see the changes that are pushed. Yes, you can keep yourself updated if you're too bored to do anything else
Additionally, they must pull daily as well. If they try to push while there are conflicts it just won't happen and git will issue a message saying "You need to pull and fix the conflicts first", so as long as they are pulling their branch daily, all should be good. To minimise conflicts I also rebase my feature off the parent branch as well, so that there are never any conflicts when sending the eventual PR.
Of course, they're both modifying Fob at some point, so you expect conflicts. Whoever finishes their branch first will send you a PR, you will review it and merge the PR (it passed review! Yay!).
Then the second PR comes in from the second-place dev, and when you (and she) examine the PR you see in the diff that there are conflicts. She pulls the current pre-release, merges (or rebases) into her feature/squiz branch, gets a bunch of reported conflicts which she then fixes, commits her rebased and fixed conflict-free branch to the remote origin/feature/squiz branch and resends the PR. This time there are no conflicts and you approve the PR and perform the merge.
The problem you are going to have is that you're coming from a primitive product with a marvelous interface but few features (TFS, SVN), to an advanced product with a million features but a piss-poor interface (Git).
The git UI is poor, unintuitive, unhelpful, not fail-safe, confusing as hell, etc. Couple that poor interface to the advanced feature set (with tons of features) and the result is a very intimidating product.
The best thing to do is find a GUI client (I only use the git CLI client so I am not much help there, I'm afraid) that doesn't hide the details from you even when it is operating at a high-level.
|
|
|
|
|
While I prefer SmartGit[^] mainly because it specifically does not go color crazy with branches, if you want lots of color, try GitKraken[^]. Both work equally well in our team's experience but there are nuances in how they handle things like commits and pushes. I find GitKraken to be less intuitive but once I'm shown "hey, you just right click and stuff happens", it looks really easy to use.
If you google "GitKraken vs. SmartGit" you might get some useful information before committing to one or the other.
|
|
|
|
|
VS Code with the GitLens extension isn't bad.
|
|
|
|
|
Assuming you are using Windows, see: best-git-clients-for-windows[^]
If you are looking for a Git server with a nice GitHub like interface, I can recommend Gitea[^] it's free and open-source.
modified 26-Jun-21 8:04am.
|
|
|
|
|
To Git or not to Git that is the question. Is the right place for this post, or should it be in Ask a Question forum?
"I'm a mean old man, a dirty old man" - paraphrasing the Beatles.
|
|
|
|
|
I found Visual Studio rather helpful in working with Git, including it's visual history display (including branches). It gets better, you get a note about who worked on this method and what did they change right in the code editor!
Of course is there nothing about Git in the agile manifesto and/or agile methodogies! The first line in the agile manifesto is "people & interactions>processes" and Git is just a tool. Granted, it's the default go-to tool for code management, but it's still just a tool.
|
|
|
|
|
I will consider also Sourcetree, easy to use and good UI.
|
|
|
|
|
From the ProGit text (publicly available), in Appendix A, there are a few excellent conceptual tools:
1: git-prompt that you can display your current directory and current branch via command line prompt
2: git-completion: just like normal shell text completion, but git call specific
3: GitHub for Windows or Mac
4: gitk and git-gui: this is what you're looking for. Although, not sure it illustrates remote.
|
|
|
|
|
to flip the question
Why do you need to visualise?
Are you creating to many branches, or are branches open to long creating many changes per branch?
Simplify: Create Branch, make code, Pull Request (PR tools like devops, help show what changes going to do), Delete Branch on Pull
New branch per feature change. Delete on complete Pull Request.
As for history tools: Visual Studio 2019 built in Git history ok. SourceTree was great when used it, but Im in on VS Pro 2019 git change tool.
|
|
|
|
|
The 'gitk' tool is pretty good for showing history and is typically packaged with Git. It can take command line options that limit which lines of development are shown, and where they should start and end, though the documentation is minimal..
Likewise the git-gui is a nice developer front end for those who aren't 100% head-in-a-terminal.
The key aspects will be to set ground rules, and to decide on the server/remote structure (or set rules based on the one you are given, e.g. single central repo, or repo [fork] per dev plus a golden repo).
Remember that Git distributes 'control' to the developer, away from the manager.
But that is good! Because the manager no only has to decide if contributions are acceptable for inclusion on the main/master/trunk.
It is also good because the developer can now keep all their wip revisions on their own machine with many and varied branches, and you don't care! Finally they start using version management because it helps them!
Key rules:
* Small commits often, with imperative style concise comments (try looking at the git repo itself).
* merge relatively often, or rebase long running dev branches (minimal in-work tech debt)
* All file names must be valid Windows file names. No Directory/File name (Linux) conflicts (i.e. no Readme/Readme, foo/foo) Git won't accept them.
* Give devs their own branch namespace prefix `dev1/`, or use initials like my `po/`
* Use a hook on the central repo to ensure simple common sense (branch separation).
* Keep focus on the prize.
* Don't tell senior management. They will only misunderstand even worse! (Job for Direct Implementation - JFDI)
|
|
|
|
|
|
|
Do Canadian cats play Mice Hockey?
"I have no idea what I did, but I'm taking full credit for it." - ThisOldTony
"Common sense is so rare these days, it should be classified as a super power" - Random T-shirt
AntiTwitter: @DalekDave is now a follower!
|
|
|
|
|
I feel like I'm pouncing on you but your skating on thin ice with that one.
Ravings en masse^ |
---|
"The difference between genius and stupidity is that genius has its limits." - Albert Einstein | "If you are searching for perfection in others, then you seek disappointment. If you seek perfection in yourself, then you will find failure." - Balboos HaGadol Mar 2010 |
|
|
|
|
|
Canadian cats are much too polite to play with their food.
Freedom is the freedom to say that two plus two make four. If that is granted, all else follows.
-- 6079 Smith W.
|
|
|
|
|
No cats are polite. They are sleek, beautiful, and underneath sadistic and viscious.
|
|
|
|
|
Quote: The Store is wide open now. Developers don't have to use Microsoft's payment tools; they can choose how their app is updated; they can build and host their app any way they want to.
Microsoft is adding some curation and editorial content, but relinquishing almost all control of the apps in the store. It's a total inversion of the app store model, swapping a carefully curated, walled garden for a pure discovery engine.
Even Android apps are coming to the Windows Store. They're available through the Amazon App Store, which is in the Windows Store. Users will be able to use a Microsoft Store to download an Amazon Store to download Google apps onto their Microsoft devices. Figure that out. From Protocol's article on the Win11 pre-pre-pre-reality announcement paid political advertisement: [^].
All your base are belong to you ?
«One day it will have to be officially admitted that what we have christened reality is an even greater illusion than the world of dreams.» Salvador Dali
|
|
|
|
|
Except ... the Amazon App Store is the weakest of the bunch, and almost nothing there is anything like the latest version.
Apparently devs have to pay to be there, and the approvals procedure is long winded and tiresome as well.
"I have no idea what I did, but I'm taking full credit for it." - ThisOldTony
"Common sense is so rare these days, it should be classified as a super power" - Random T-shirt
AntiTwitter: @DalekDave is now a follower!
|
|
|
|
|
Hi, I suspect I'll exit mortality without ever having owned an android device, and I didn't even know Amazon had an app store ... I stopped using Amazon because I object to its business practices.
How about the Google app store ... any better ?
«One day it will have to be officially admitted that what we have christened reality is an even greater illusion than the world of dreams.» Salvador Dali
|
|
|
|
|
The Google app store has the most content of any device related store: Biggest app stores in the world 2020 | Statista[^]
Quality? Variable ... all stores suffer from this: get-rich-quick "developers" rehashing crap for the ad revenue.
Samsung has the Galaxy Store, but it's cupboard is pretty bare - but it's available in China, which Google isn't. for "native Chinese, Huawei also have one (around 55,000 apps, nearly all total rubbish or stolen with the serial numbers quickly filed off).
"I have no idea what I did, but I'm taking full credit for it." - ThisOldTony
"Common sense is so rare these days, it should be classified as a super power" - Random T-shirt
AntiTwitter: @DalekDave is now a follower!
|
|
|
|
|