r-darwish / topgrade

Upgrade everything
GNU General Public License v3.0
3.36k stars 160 forks source link

Git repo paths not expanded on Windows #602

Closed IngwiePhoenix closed 3 years ago

IngwiePhoenix commented 3 years ago

What did you expect to happen? To have all my git repos automatically pulled.

What actually happened?

 2021-01-12T14:52:14.086Z DEBUG topgrade::config > Path E:\cloud.ingwie.me\Work\Git\* expanded to E:\cloud.ingwie.me\Work\Git\*
 2021-01-12T14:52:14.086Z DEBUG topgrade::config > Path E:\cloud.ingwie.me\Work\Favorites\* expanded to E:\cloud.ingwie.me\Work\Favorites\*
 2021-01-12T14:52:14.086Z DEBUG topgrade::config > Path E:\cloud.ingwie.io\Work\Git\mkxp expanded to E:\cloud.ingwie.io\Work\Git\mkxp

mkxp was pulled successfuly - but the other two folders, that do contain a good lot of git repos, were not.

Additional details:

 2021-01-12T14:52:14.081Z DEBUG topgrade::config > Configuration at C:\Users\ingwi\AppData\Roaming\topgrade.toml
 2021-01-12T14:52:14.086Z DEBUG topgrade::config > Path E:\cloud.ingwie.me\Work\Git\* expanded to E:\cloud.ingwie.me\Work\Git\*
 2021-01-12T14:52:14.086Z DEBUG topgrade::config > Path E:\cloud.ingwie.me\Work\Favorites\* expanded to E:\cloud.ingwie.me\Work\Favorites\*
 2021-01-12T14:52:14.086Z DEBUG topgrade::config > Path E:\cloud.ingwie.io\Work\Git\mkxp expanded to E:\cloud.ingwie.io\Work\Git\mkxp
 2021-01-12T14:52:14.087Z DEBUG topgrade::config > Loaded configuration: ConfigFile { pre_commands: Some({}), post_commands: None, commands: Some({"V (self)": "v up", "v (modules)": "v upgrade"}), git_repos: None, predefined_git_repos: None, disable: None, ignore_failures: None, remote_topgrades: Some(["macmini", "ingwie.io", "dragonsinn"]), remote_topgrade_path: None, ssh_arguments: None, git_arguments: None, tmux_arguments: None, set_title: None, assume_yes: Some(true), yay_arguments: None, no_retry: Some(true), run_in_tmux: None, cleanup: Some(true), notify_each_step: None, accept_all_windows_updates: None, only: None, composer: Some(Composer { self_update: Some(true) }), brew: Some(Brew { greedy_cask: None }), linux: Some(Linux { yay_arguments: None, trizen_arguments: None, dnf_arguments: None, enable_tlmgr: None, redhat_distro_sync: None, emerge_sync_flags: None, emerge_update_flags: None }), git: Some(Git { max_concurrency: Some(10), arguments: None, repos: Some(["E:\\cloud.ingwie.me\\Work\\Git\\*", "E:\\cloud.ingwie.me\\Work\\Favorites\\*", "E:\\cloud.ingwie.io\\Work\\Git\\mkxp"]), pull_predefined: None }), windows: Some(Windows { accept_all_updates: None, self_rename: None, open_remotes_in_new_terminal: None }), vagrant: None }
 2021-01-12T14:52:14.087Z DEBUG topgrade         > Version: 6.2.3
 2021-01-12T14:52:14.087Z DEBUG topgrade         > OS: x86_64-pc-windows-msvc
 2021-01-12T14:52:14.087Z DEBUG topgrade         > Args { inner: ["C:\\Users\\ingwi\\.cargo\\bin\\topgrade.exe", "-v", "--only", "git_repos"] }
 2021-01-12T14:52:14.087Z DEBUG topgrade         > Binary path: Ok("C:\\Users\\ingwi\\.cargo\\bin\\topgrade.exe")
 2021-01-12T14:52:14.087Z DEBUG topgrade         > Self Update: false
 2021-01-12T14:52:14.095Z DEBUG topgrade::utils  > Detected "C:\\Program Files\\Git\\cmd\\git.EXE" as "git"
 2021-01-12T14:52:14.105Z DEBUG topgrade::utils  > Cannot find "doas"
 2021-01-12T14:52:14.109Z DEBUG topgrade::utils  > Detected "C:\\ProgramData\\chocolatey\\bin\\sudo.EXE" as "sudo"
 2021-01-12T14:52:14.118Z DEBUG topgrade::utils  > Cannot find "pwsh"
 2021-01-12T14:52:14.121Z DEBUG topgrade::utils  > Detected "C:\\Windows\\System32\\WindowsPowerShell\\v1.0\\powershell.EXE" as "powershell"
 2021-01-12T14:52:14.365Z TRACE topgrade::executor > Output of "C:\\Windows\\System32\\WindowsPowerShell\\v1.0\\powershell.EXE" "-NoProfile" "-Command" "Split-Path $profile": Output { status: ExitStatus(ExitStatus(0)), stdout: "E:\\cloud.ingwie.io\\Dokumente (Cloud)\\WindowsPowerShell\r\n", stderr: "" }
 2021-01-12T14:52:14.366Z DEBUG topgrade::utils    > Path "E:\\cloud.ingwie.io\\Dokumente (Cloud)\\WindowsPowerShell" exists
 2021-01-12T14:52:14.366Z DEBUG topgrade::utils    > Path "C:\\Users\\ingwi\\AppData\\Roaming\\.emacs.d" doesn't exist
 2021-01-12T14:52:14.366Z DEBUG topgrade::steps::git > Checking if \\?\C:\Users\ingwi\AppData\Local\Packages\Microsoft.WindowsTerminal_8wekyb3d8bbwe\LocalState is a git repository
 2021-01-12T14:52:14.366Z DEBUG topgrade::steps::git > Transformed path to C:\Users\ingwi\AppData\Local\Packages\Microsoft.WindowsTerminal_8wekyb3d8bbwe\LocalState
 2021-01-12T14:52:14.383Z TRACE topgrade::executor   > Output of "C:\\Program Files\\Git\\cmd\\git.EXE" "rev-parse" "--show-toplevel": Output { status: ExitStatus(ExitStatus(128)), stdout: "", stderr: "fatal: not a git repository (or any of the parent directories): .git\n" }
 2021-01-12T14:52:14.383Z DEBUG topgrade::steps::git > Checking if \\?\E:\cloud.ingwie.io\Dokumente (Cloud)\WindowsPowerShell is a git repository
 2021-01-12T14:52:14.383Z DEBUG topgrade::steps::git > Transformed path to E:\cloud.ingwie.io\Dokumente (Cloud)\WindowsPowerShell
 2021-01-12T14:52:14.399Z TRACE topgrade::executor   > Output of "C:\\Program Files\\Git\\cmd\\git.EXE" "rev-parse" "--show-toplevel": Output { status: ExitStatus(ExitStatus(128)), stdout: "", stderr: "fatal: not a git repository (or any of the parent directories): .git\n" }
 2021-01-12T14:52:14.399Z DEBUG topgrade::steps::git > Checking if \\?\E:\cloud.ingwie.io\Work\Git\mkxp is a git repository
 2021-01-12T14:52:14.399Z DEBUG topgrade::steps::git > Transformed path to E:\cloud.ingwie.io\Work\Git\mkxp
 2021-01-12T14:52:14.414Z TRACE topgrade::executor   > Output of "C:\\Program Files\\Git\\cmd\\git.EXE" "rev-parse" "--show-toplevel": Output { status: ExitStatus(ExitStatus(0)), stdout: "E:/cloud.ingwie.io/Work/Git/mkxp\n", stderr: "" }
 2021-01-12T14:52:14.414Z DEBUG topgrade::runner     > Step "Git repositories"

―― 15:52:14 - Git repositories ―――――――――――――――――――――――――――――――――――――――――――――――――
 2021-01-12T14:52:14.433Z TRACE topgrade::executor   > Output of "C:\\Program Files\\Git\\cmd\\git.EXE" "remote" "show": Output { status: ExitStatus(ExitStatus(0)), stdout: "origin\n", stderr: "" }
 2021-01-12T14:52:14.450Z TRACE topgrade::executor   > Output of "C:\\Program Files\\Git\\cmd\\git.EXE" "rev-parse" "HEAD": Output { status: ExitStatus(ExitStatus(0)), stdout: "66dc9309dbdabfbb5ff3a5e6d935d9833304aedd\n", stderr: "" }
Pulling E:/cloud.ingwie.io/Work/Git/mkxp
 2021-01-12T14:52:15.703Z TRACE topgrade::executor   > Output of "C:\\Program Files\\Git\\cmd\\git.EXE" "rev-parse" "HEAD": Output { status: ExitStatus(ExitStatus(0)), stdout: "66dc9309dbdabfbb5ff3a5e6d935d9833304aedd\n", stderr: "" }
Up-to-date E:/cloud.ingwie.io/Work/Git/mkxp

―― 15:52:15 - Summary ――――――――――――――――――――――――――――――――――――――――――――――――――――――――――
Git repositories: OK
 2021-01-12T14:52:15.707Z DEBUG topgrade::terminal   > Desktop notification: Topgrade finished sucessfully
IngwiePhoenix commented 3 years ago

False alert:

I typo'd the path name. I own both, ingwie.me and ingwie.io - and mistakenly typed the wrong TLD. Changing that, fixed it.

Would there be a way to hint the user at this?

r-darwish commented 3 years ago

I suppose Topgrade can print a warning. I'll experiment with it later