{"action":"created","issue":{"url":"https://api.github.com/repos/git-for-windows/git/issues/682","repository_url":"https://api.github.com/repos/git-for-windows/git","labels_url":"https://api.github.com/repos/git-for-windows/git/issues/682/labels{/name}","comments_url":"https://api.github.com/repos/git-for-windows/git/issues/682/comments","events_url":"https://api.github.com/repos/git-for-windows/git/issues/682/events","html_url":"https://github.com/git-for-windows/git/issues/682","id":137997095,"number":682,"title":"Installer does not roll back properly","user":{"login":"fourpastmidnight","id":6895593,"avatar_url":"https://avatars.githubusercontent.com/u/6895593?v=3","gravatar_id":"","url":"https://api.github.com/users/fourpastmidnight","html_url":"https://github.com/fourpastmidnight","followers_url":"https://api.github.com/users/fourpastmidnight/followers","following_url":"https://api.github.com/users/fourpastmidnight/following{/other_user}","gists_url":"https://api.github.com/users/fourpastmidnight/gists{/gist_id}","starred_url":"https://api.github.com/users/fourpastmidnight/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/fourpastmidnight/subscriptions","organizations_url":"https://api.github.com/users/fourpastmidnight/orgs","repos_url":"https://api.github.com/users/fourpastmidnight/repos","events_url":"https://api.github.com/users/fourpastmidnight/events{/privacy}","received_events_url":"https://api.github.com/users/fourpastmidnight/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/git-for-windows/git/labels/help%20wanted","name":"help wanted","color":"159818"}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":165,"created_at":"2016-03-02T21:24:17Z","updated_at":"2016-07-17T01:25:35Z","closed_at":null,"body":"While installing Git 2.7.2, an error was encountered where `C:\\Program Files\\Git\\mingw64\\bin` was unable to be deleted. I was given a dialog with three choices: `Abort`, `Retry`, or `Ignore`. Well, it's fairly safe to say that ignoring this is not a good idea, and retrying didn't work (of course), so really, the only sensible option was to `Abort`.\r\n\r\nWhen I clicked `Abort`, the status bar changed and said `Rolling back...`. However, my previous installation was now corrupted--as not all files were restored/rolled back. This is a pretty huge installer bug. The whole point of MSI's is that they're transactional.\r\n\r\nIf you're not going to support rolling back a failed installation, then remove the rollback steps in the installer."},"comment":{"url":"https://api.github.com/repos/git-for-windows/git/issues/comments/233159970","html_url":"https://github.com/git-for-windows/git/issues/682#issuecomment-233159970","issue_url":"https://api.github.com/repos/git-for-windows/git/issues/682","id":233159970,"user":{"login":"fourpastmidnight","id":6895593,"avatar_url":"https://avatars.githubusercontent.com/u/6895593?v=3","gravatar_id":"","url":"https://api.github.com/users/fourpastmidnight","html_url":"https://github.com/fourpastmidnight","followers_url":"https://api.github.com/users/fourpastmidnight/followers","following_url":"https://api.github.com/users/fourpastmidnight/following{/other_user}","gists_url":"https://api.github.com/users/fourpastmidnight/gists{/gist_id}","starred_url":"https://api.github.com/users/fourpastmidnight/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/fourpastmidnight/subscriptions","organizations_url":"https://api.github.com/users/fourpastmidnight/orgs","repos_url":"https://api.github.com/users/fourpastmidnight/repos","events_url":"https://api.github.com/users/fourpastmidnight/events{/privacy}","received_events_url":"https://api.github.com/users/fourpastmidnight/received_events","type":"User","site_admin":false},"created_at":"2016-07-17T01:25:35Z","updated_at":"2016-07-17T01:25:35Z","body":"@dscho:\r\n\r\n**Warning: This is long. You've been warned. :smile:**\r\n\r\nYes, I saw that 2.9.2 was released. :smile:\r\n\r\nSo, with respect to downgrades, that's a feature that's pretty much something you get \"out of the box\" with MSI (not that you can't ever downgrade if you're using MSI--just that, typically, you only allow upgrades to occur). The way the MSI is curently setup, downgrades are not allowed. You have to uninstall the version of Git for Windows currently installed in order to install an \"older\" version.\r\n\r\nSo now on to the more important topic: which installer should be primary? I'll provide some comments--and yes, I'm slightly biased--but I hope at least that I can provide some food for thought.\r\n\r\nWith respect to the size of the MSI installer vs. the InnoSetup installer: Honestly, for me, I don't care about this one. Currently, it appears the MSI installer is a little under twice the size of the InnoSetup installer. But in this day and age with the speed of internet access and the cost of hard disk space (even USB thumb drive space, for that matter), I don't see this as a huge show stopper. You may disagree with me on this--but I think this is much ado about nothing at this point. I will concede, however, that this is a fair point over all. I just don't see it as a compelling one.\r\n\r\nAn MSI installer is definitely great for sys-admins. However, don't forget the whole reason I created this issue: the InnoSetup installer failed to install a new version of Git on my machine and left my machine in an inconsistent state; it had already uninstalled my previous version, but upon encountering an \"unrecoverable error\", I was left with nothing. MSI totally obviates this scenario. You can actually test this today with the current state of the MSI installer (assuming you can make it fail to install.....maybe by placing a lock on some critical file). I know, because I actually used this \"feature\" during development of the MSI. :wink:\r\n\r\nI'm uncomfortable with having two methods of installation of Git for Windows without having something in place to protect users who, at one point use InnoSetup, and then later use MSI, or vice versa. So, on the one hand, I _may_ be able to engineer the MSI to upgrade from an InnoSetup-based installation. (I've been thinking about this off and on as I've developed the MSI installer.) But then, InnoSetup would need to be modified likewise, to detect an MSI installation and upgrade from that. On the other hand, perhaps it _may_ just be best to detect an InnoSetup installation in the MSI installer (and vice versa) and refuse to continue the installation, guiding the user to use the other installer (or uninstall their current version of Git for Windows before proceeding with the current installer technology). And now that I've written all that, assuming Git for Windows continues to distribute both an InnoSetup and an MSI installer, I think it's probably safest for each installer to detect if Git for Windows has previously  been installed by the other and simply refuse to install--it's easier, safer, and less likely to hose someone's machine.\r\n\r\nLastly, where Git for Windows' InnoSetup installer stores it's `CurrentVersion` information will need to change. I know that you worked hard to get the Visual Studio team to detect the Git for Windows version in the current registry location--but if/when we introduce the MSI installer, Visual Studio will still need to be able to detect the version of Git for Windows that's installed--no matter the installer technology used to install it. The reason the current location used by InnoSetup can't be used is because in MSI, you don't have control over the name of the Uninstall key, unlike in InnoSetup. (And actually, it's not recommended that this location be used for any purposes beyond uninstallation. This location is meant to be opaque (i.e. a black box) to users of the system--it's only used by installers for retrieving uninstallation information.) Currently, the MSI installer stores the `CurrentVersion` of Git for Windows in `HKLM\\SOFTWARE\\GitForWindows\\CurrentVersion`. In addition, all other installation configuration information is stored in the `HKLM\\SOFTWARE\\GitForWindows` key in the Windows registry. (I'm thinking, there could be some advantages here--but my thoughts are incomplete at this time; when I have given this more thought and have something more concrete to share, I'll ping you.)\r\n\r\nThese are my immediate thoughts. I look forward to continuing this conversation funther in case I've misunderstood anything or I have an incomplete picture of any of the issues at hand, or just to answer any additional questions you might come up with. :smile: This is a conversation that would need to have occured sooner or later anyway once the MSI is complete and ready to go and prior to actually releasing it \"into the wild\"."}}
{"actor":{"display_login":"fourpastmidnight"}}