Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Download and install Git for Windows pop-up window #4591

Closed
1 task done
krisanathema opened this issue Sep 6, 2023 · 7 comments
Closed
1 task done

Download and install Git for Windows pop-up window #4591

krisanathema opened this issue Sep 6, 2023 · 7 comments
Labels

Comments

@krisanathema
Copy link

krisanathema commented Sep 6, 2023

  • I was not able to find an open or closed issue matching what I'm seeing

Setup

  • Which version of Git for Windows are you using? Is it 32-bit or 64-bit?
$ git --version --build-options

git version 2.42.0.windows.1
cpu: x86_64
built from commit: a2e49ec355ae22e74288fa74f50821f3cc1a1551
sizeof-long: 4
sizeof-size_t: 8
shell-path: /bin/sh
feature: fsmonitor--daemon
  • Which version of Windows are you running? Vista, 7, 8, 10? Is it 32-bit or 64-bit?
$ cmd.exe /c ver

Microsoft Windows [Version 10.0.19045.3324]
(c) Microsoft Corporation. All rights reserved.
  • What options did you set as part of the installation? Or did you choose the
    defaults?
# One of the following:
> type "C:\Program Files\Git\etc\install-options.txt"
> type "C:\Program Files (x86)\Git\etc\install-options.txt"
> type "%USERPROFILE%\AppData\Local\Programs\Git\etc\install-options.txt"
> type "$env:USERPROFILE\AppData\Local\Programs\Git\etc\install-options.txt"
$ cat /etc/install-options.txt

Editor Option: VisualStudioCode
Custom Editor Path:
Default Branch Option:
Path Option: Cmd
SSH Option: OpenSSH
Tortoise Option: false
CURL Option: OpenSSL
CRLF Option: CRLFAlways
Bash Terminal Option: MinTTY
Git Pull Behavior Option: Merge
Use Credential Manager: Enabled
Performance Tweaks FSCache: Enabled
Enable Symlinks: Disabled
Enable Pseudo Console Support: Disabled
Enable FSMonitor: Disabled
  • Any other interesting things about your environment that might be related
    to the issue you're seeing?

Not sure if this is related, but I also cannot download packages from sources in R, a different software, potentially indicating some issues on my machine to allow software connections to the Internet?

Details

  • Which terminal/shell are you running Git from? e.g Bash/CMD/PowerShell/other
  • What commands did you run to trigger this issue? If you can provide a
    Minimal, Complete, and Verifiable example
    this will help us understand the issue.

After starting my Windows 10 laptop, I get a pop-up window from Git for Windows. It states: “Download and install Git for Windows v2.42.0.windows.2?” and has two choice buttons: “Yes” and “No”. The version number is irrelevant: I had this issue for many versions. When I click on “Yes”, nothing happens. I am just wondering whether this is normal and, if so, why it is asking to download and install and then not doing it. If I want to update, I need to do it directly from Git Bash.

  • What did you expect to occur after running these commands?

I would have expected that clicking on “Yes” would start the downloading process and also install the new version.

  • What actually happened instead?

Nothing.

@dscho
Copy link
Member

dscho commented Sep 6, 2023

After starting my Windows 10 laptop, I get a pop-up window from Git for Windows. It states: “Download and install Git for Windows v2.42.0.windows.2?” and has two choice buttons: “Yes” and “No”. The version number is irrelevant: I had this issue for many versions. When I click on “Yes”, nothing happens. I am just wondering whether this is normal and, if so, why it is asking to download and install and then not doing it. If I want to update, I need to do it directly from Git Bash.

I cannot reproduce, it works here.

@krisanathema can you execute the following command in a CMD?

git update-git-for-windows --testing --gui

@dscho dscho added the unclear label Sep 6, 2023
@krisanathema
Copy link
Author

Thanks @dscho. Yeah, I assume it will not be reproducible for most users, because it seems to be a problem with my machine, but I cannot find the solution and not even identify the problem.

Here is the output of the command:

C:\Users\Christophe Bousquet>git update-git-for-windows --testing --gui
Git for Windows 2.42.0.windows.1 (64-bit)
Update 2.42.0.windows.2 is available

It also launched the Git for Windows pop-up window. Then, when I clicked on "Yes", it adds the following message in the CMD:

Git for Windows 2.42.0.windows.1 (64-bit)
Update 2.42.0.windows.2 is available
The user clicked on action #0
################################################################################################################ 100.0%
/usr/bin/start: line 8: C:\WINDOWS\system32\cmd.exe;C:\Users\Christophe Bousquet\AppData\Roaming\Python\Python39\Scripts: No such file or directory

So it seems to recognize that I clicked on "Yes", but then does not find a file somewhere...

@dscho
Copy link
Member

dscho commented Sep 6, 2023

Oh, is that a multi-value COMSPEC I'm seeing there?

@dscho
Copy link
Member

dscho commented Sep 6, 2023

This is that mentioned line 8, with that COMSPEC I talked about.

@dscho
Copy link
Member

dscho commented Sep 6, 2023

But Microsoft's own documentation of the CMD built-in start says:

If you run a command that contains the string CMD as the first token without an extension or path qualifier, CMD is replaced with the value of the COMSPEC variable. This prevents users from picking up cmd from the current directory.

That reads to me as if COMSPEC is not intended as a semicolon-separated, multi-valued variable. Instead, it should be the absolute path to the cmd.exe that should be used in start cmd [...] invocations (to prevent a cmd.bat in the current directory from being picked up by mistake).

So git-update-for-windows (or better: /usr/bin/start) got it right, methinks.

@dscho
Copy link
Member

dscho commented Sep 6, 2023

C:\WINDOWS\system32\cmd.exe;C:\Users\Christophe Bousquet\AppData\Roaming\Python\Python39\Scripts

The second part does not even looks like an executable.

@krisanathema maybe your ~/.profile appends the Scripts directory to COMSPEC but wants to do that to PATH instead?

@krisanathema
Copy link
Author

Thanks @dscho. By specifying ComSpec correctly [only 1 value and without a semi-column], I manage to solve this Git for Windows issue, but also another one related to installing packages from source in R, both apparently related to this mispecification.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants