The Lounge is rated Safe For Work. If you're about to post something inappropriate for a shared office environment, then don't post it. No ads, no abuse, and no programming questions. Trolling, (political, climate, religious or whatever) will result in your account being removed.
Hiding in my room, safe within my womb
I touch no one and no one touches me
"the debugger doesn't tell me anything because this code compiles just fine" - random QA comment
"Facebook is where you tell lies to your friends. Twitter is where you tell the truth to strangers." - chriselst
"I don't drink any more... then again, I don't drink any less." - Mike Mullikins uncle
I posted a request earlier today regarding whether I should use Github or Dropbox for my current project and got some good feedback. I think I should use Github. Can I find a basic article on how to use Github from Visual Studio without Azure or some other stuff I don't use ? NO. I need a simple howto ( assuming nothing ) of how to create a HW project and push / fork / branch / share / pull and a myriad of other terms to GH from VS. Please help
"We can't stop here - this is bat country" - Hunter S Thompson - RIP
I found GitHub's online documentation to be fairly good. I have absolutely no patience for learning these kinds of systems, because I'd rather write code. But it didn't take long to get used to GitHub. Just jump in and you'll probably be OK. Sorry, but that's the best advice I can offer.
The command line?! You're a much better man than me. I use the VS extension and would only research the command line if I was trying to do something that didn't appear to be supported within the extension or when using GitHub in the browser.
It's pretty easy to be honest and there are a lot of things you can do that aren't supported in any Git software I've used (GitHub Desktop or VS) like rebase and stash.
Most of what is commonly done can be done using add, commit, merge, branch, status, push, and pull. Not even any complicated options or multiple parameters. To each their own though
EDIT: Viewing branch histories is usually easier in graphical interfaces to be fair, but you can view that on GitHub or use git log --oneline --all --graph --decorate from the command line. I have an alias for it so I don't have to remember all that. Not as pretty as GitHub though.
Atlasian Sourcetree does both. Stashing is dead simple, the rebasing UI is confusing enough that I need to read the docs every 3-6 months when I need to do it. Which is a shame since in GUI app you should be able to indicate what you want to go where by dragging the first commit you want to move to its destination. For simple cases I just cherry pick in a manual point and click loop.
Did you ever see history portrayed as an old man with a wise brow and pulseless heart, weighing all things in the balance of reason?
Is not rather the genius of history like an eternal, imploring maiden, full of fire, with a burning heart and flaming soul, humanly warm and humanly beautiful?
Training a telescope on one’s own belly button will only reveal lint. You like that? You go right on staring at it. I prefer looking at galaxies.
-- Sarah Hoyt
I'll describe the steps (somewhere in here you will get prompted for your github account credentials)
1. Open your solution
2. Right click on the solution in solution explorer, click Add To Source Control
3. Open the team explorer, click on the little home button, then click Sync
4. It will switch to options to publish, either to github, or azure. Click the first GitHub publish button
That should sync it for you. Any time you need to update, go to team explorer|home and then hit sync (you won't be prompted for repository information after the first time)
Finally, remember to commit periodically when you change stuff. It's best to do related changes together and then commit so your commit messages stay targeted to what you did. Make sure to sync to the server otherwise your copy remains local even though you committed
In general more than one branch complicates things. I understand it for large projects with teams and such but for my own stuff I simply don't branch. I just use master. *boo hiss*! (it's just easy and I'm lazy)
You can fix this to varying degrees pretty easily on the command line:
If the branch is newly created or no conflicts are expected: git merge master
You can also use this and just manually resolve conflicts if you really want.
If conflicts are expected and you know you want to keep your changes: git merge -s ours master
If you've been working on something but haven't committed before realizing the problem: git stash && git merge master && git stash pop
If you want a clean history without the additional master merge: git rebase master
modified 20-Mar-20 1:30am.
Last Visit: 4-Jul-20 18:26 Last Update: 4-Jul-20 18:26