Skip to content

Instantly share code, notes, and snippets.

@gldraphael
Last active November 8, 2017 18:05
Show Gist options
  • Save gldraphael/ccf45cc5a1cd7f62fc7752ca6c3153b5 to your computer and use it in GitHub Desktop.
Save gldraphael/ccf45cc5a1cd7f62fc7752ca6c3153b5 to your computer and use it in GitHub Desktop.
Reproducing the VS for Mac Push bug

Current behaviour

Pushing commits shows a file-picker when the local repository is not up-to-date with the remote.

Steps to reproduce

Please follow the steps exactly as given below. Time required: Approx. 7-10 minutes.

  1. Create a new project from VS for Mac with the Use git for version control option checked.
  2. Make a few commits (from within VS for Mac)
  3. Browse to the git directory on the terminal
  4. Create a new repo on GitHub (setup SSH if you haven't and only use ssh uris)
  5. Paste the two commands under …or push an existing repository from the command line. The github repo should now be in sync with your local repo.
  6. Make a commit directly for GitHub (add or edit the README file for example)
  7. Now make a few more commits from within VS for Mac
  8. Push the commits using Version Control > Push Changes... > Push Changes from the menu (Pushing the commits won't work from VS for Mac, because the changes on GitHub needs to be pulled first, but still do this)
  9. Pull the commits using Version Control > Update Solution. (Doesn't work on my machine. Shows a file picker instead. Cancelling the operation shows a dialog with text: Invalid credentials were supplied. Aborting operation.)
  10. Now attempt to push the commits a few times and you'll see the same file picker. (You might see a diaog saying something on the lines of parameter is null the first time).
  11. Run git pull from the terminal and then try pushing the commits from within VS for Mac. It'll still show the file-picker.
  12. Restart VS for Mac, and the push will work fine.

Twitter discussion with @VisualStudio: https://twitter.com/visualstudio/status/925061740567650305

Version Information

Visual Studio Community 2017 for Mac
Version 7.2.2 (build 7)
Installation UUID: 71c7a174-5c3f-4eeb-a940-f27e9a42fc12
Runtime:
	Mono 5.4.1.6 (2017-06/1f4613aa1ac) (64-bit)
	GTK+ 2.24.23 (Raleigh theme)

	Package version: 504010006

NuGet
Version: 4.3.1.4445

.NET Core
Runtime: /usr/local/share/dotnet/dotnet
Runtime Versions:
	2.0.0
	1.1.1
	1.1.0
	1.1.0-preview1-001100-00
	1.0.4
	1.0.3
	1.0.2
	1.0.0
	1.0.0-rc2-3002702
SDK: /usr/local/share/dotnet/sdk/2.0.0/Sdks
SDK Versions:
	2.0.0
	1.0.1
	1.0.0-preview2.1-003155
	1.0.0-preview2-1-003177
	1.0.0-preview2-003156
	1.0.0-preview2-003148
	1.0.0-preview2-003121
	1.0.0-preview1-002702
MSBuild SDKs: /Library/Frameworks/Mono.framework/Versions/5.4.1/lib/mono/msbuild/15.0/bin/Sdks

Xamarin.Profiler
'/Applications/Xamarin Profiler.app' not found

Apple Developer Tools
Xcode 9.1 (13532)
Build 9B55

Xamarin.iOS
Version: 11.2.1.0 (Visual Studio Community)
Hash: 12e80e01
Branch: d15-4-xi
Build date: 2017-10-13 12:03:42-0400

Xamarin.Android
Version: 8.0.2.1 (Visual Studio Community)
Android SDK: /Users/gldraphael/Library/Android/sdk
	Supported Android versions:
		4.0.3 (API level 15)
		6.0   (API level 23)
		7.0   (API level 24)
		7.1   (API level 25)
		8.0   (API level 26)

SDK Tools Version: 26.1.1
SDK Platform Tools Version: 26.0.1
SDK Build Tools Version: 26.0.1

Java SDK: /usr
java version "1.8.0_65"
Java(TM) SE Runtime Environment (build 1.8.0_65-b17)
Java HotSpot(TM) 64-Bit Server VM (build 25.65-b01, mixed mode)

Android Designer EPL code available here:
https://github.com/xamarin/AndroidDesigner.EPL

Xamarin Inspector
Not Installed

Xamarin.Mac
Version: 3.8.1.0 (Visual Studio Community)

Build Information
Release ID: 702020007
Git revision: 2236098c68f51eeb447cb947a87371d1e84f6213
Build date: 2017-10-23 11:43:05-04
Xamarin addins: eaa605cf97f25ce184949f32c712b465ca96f665
Build lane: monodevelop-lion-d15-4

Operating System
Mac OS X 10.12.6
Darwin 16.7.0 Darwin Kernel Version 16.7.0
    Thu Jun 15 17:36:27 PDT 2017
    root:xnu-3789.70.16~2/RELEASE_X86_64 x86_64

Enabled user installed addins
MonoDevelop.MonoGame.Templates 0.6

Git Information

  • Version: 2.13.6 (Apple Git-96)

~/.gitconfig:

[user]
	name = Galdin Raphael
	email = [email protected]
	signingkey = CF59AE09
	username = gldraphael
[push]
	default = simple
[core]
	autocrlf = input
	editor = vim
[filter "lfs"]
	clean = git-lfs clean %f
	smudge = git-lfs smudge %f
	required = true
[color]
	ui = auto
[github]
	user = gldraphael
[commit]
	gpgsign = true
[gpg]
	program = /usr/local/MacGPG2/bin/gpg2
[alias]
	quick-stats = ! /usr/local/bin/git-quick-stats

~/.gnupg/gpg.conf:

# Comments removed for brevity

default-key 16B7F55567538DF567FF6F5D9DF020BDCF59AE09

require-cross-certification

keyserver hkps://hkps.pool.sks-keyservers.net
keyserver-options auto-key-retrieve

auto-key-locate keyserver cert pka ldap keyserver

comment GPGTools - http://gpgtools.org
no-emit-version

use-agent
batch

~/.gnupg/.gpg-agent-info:

GPG_AGENT_INFO=/Users/gldraphael/.gnupg/S.gpg-agent:450:1

~/.bash_profile:

 # To auto start GPG agent
 # From https://gist.github.com/bmhatfield/cc21ec0a3a2df963bffa3c1f884b676b
 if [ -f ~/.gnupg/.gpg-agent-info ] && [ -n "$(pgrep gpg-agent)" ]; then
     source ~/.gnupg/.gpg-agent-info
     export GPG_AGENT_INFO
 else
     eval $(gpg-agent --daemon --write-env-file ~/.gnupg/.gpg-agent-info)
 fi
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment