From 3e06fcbf074721235c2d9fb2a99ca48a73b6c873 Mon Sep 17 00:00:00 2001 From: Benjamin Staneck Date: Sun, 23 Aug 2015 20:09:06 +0200 Subject: [PATCH 01/13] First step at converting msysgit support to git-for-windows support. --- README.md | 2 +- config/ConEmu.xml | 4 ++-- scripts/pack.ps1 | 2 +- vendor/init.bat | 4 ++-- vendor/profile.ps1 | 2 +- vendor/sources.json | 6 +++--- 6 files changed, 10 insertions(+), 10 deletions(-) diff --git a/README.md b/README.md index 81ecad7..8146437 100644 --- a/README.md +++ b/README.md @@ -23,7 +23,7 @@ The main advantage of Cmder is portability. It is designed to be totally self-co ## Integration -So you've experimented with cmder a little and want to give it a shot in a more permanent home; +So you've experimented with Cmder a little and want to give it a shot in a more permanent home; ### Shortcut to open Cmder in a chosen folder diff --git a/config/ConEmu.xml b/config/ConEmu.xml index 5786fba..1277d86 100644 --- a/config/ConEmu.xml +++ b/config/ConEmu.xml @@ -516,8 +516,8 @@ - - + + diff --git a/scripts/pack.ps1 b/scripts/pack.ps1 index 178d3a8..f047d82 100644 --- a/scripts/pack.ps1 +++ b/scripts/pack.ps1 @@ -42,7 +42,7 @@ Ensure-Executable "7z" $targets = @{ "cmder.zip" = $null; "cmder.7z" = $null; - "cmder_mini.zip" = "-x!`"vendor\msysgit`""; + "cmder_mini.zip" = "-x!`"vendor\git-for-windows`""; } Delete-Existing "..\Version*" diff --git a/vendor/init.bat b/vendor/init.bat index 7a7f02c..769a654 100644 --- a/vendor/init.bat +++ b/vendor/init.bat @@ -21,7 +21,7 @@ :: Run clink @"%CMDER_ROOT%\vendor\clink\clink_x%architecture%.exe" inject --quiet --profile "%CMDER_ROOT%\config" -:: Prepare for msysgit +:: Prepare for git-for-windows :: I do not even know, copypasted from their .bat @set PLINK_PROTOCOL=ssh @@ -33,7 +33,7 @@ ) else if exist "%ProgramFiles(x86)%\Git" ( set "GIT_INSTALL_ROOT=%ProgramFiles(x86)%\Git" ) else if exist "%CMDER_ROOT%\vendor" ( - set "GIT_INSTALL_ROOT=%CMDER_ROOT%\vendor\msysgit" + set "GIT_INSTALL_ROOT=%CMDER_ROOT%\vendor\git-for-windows" ) :: Add git to the path diff --git a/vendor/profile.ps1 b/vendor/profile.ps1 index dad67b7..c460e47 100644 --- a/vendor/profile.ps1 +++ b/vendor/profile.ps1 @@ -14,7 +14,7 @@ try { # Check if git is on PATH, i.e. Git already installed on system Get-command -Name "git" -ErrorAction Stop >$null } catch { - $env:Path += ";$env:CMDER_ROOT\vendor\msysgit\bin" + $env:Path += ";$env:CMDER_ROOT\vendor\git-for-windows\bin" } try { diff --git a/vendor/sources.json b/vendor/sources.json index d15c225..6eca667 100644 --- a/vendor/sources.json +++ b/vendor/sources.json @@ -1,8 +1,8 @@ [ { - "name": "msysgit", - "version": "1.9.5-preview20150319", - "url": "https://github.com/msysgit/msysgit/releases/download/Git-1.9.5-preview20150319/PortableGit-1.9.5-preview20150319.7z" + "name": "git-for-windows", + "version": "v2.5.0.windows.1", + "url": "https://github.com/git-for-windows/git/releases/download/v2.5.0.windows.1/PortableGit-2.5.0-32-bit.7z.exe" }, { "name": "clink", From 373a58e1e6676c8262702ecea58cb777a3d21adb Mon Sep 17 00:00:00 2001 From: Benjamin Staneck Date: Sun, 23 Aug 2015 20:21:45 +0200 Subject: [PATCH 02/13] forgot one --- scripts/build.ps1 | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/scripts/build.ps1 b/scripts/build.ps1 index cca62df..d97a50a 100644 --- a/scripts/build.ps1 +++ b/scripts/build.ps1 @@ -11,11 +11,11 @@ .EXAMPLE .\build.ps1 - Executes the default build for cmder; Conemu, clink. This is equivalent to the "minimum" style package in the releases + Executes the default build for Cmder; Conemu, clink. This is equivalent to the "minimum" style package in the releases .EXAMPLE .\build.ps1 -Full - Executes a full build for cmder, including git. This is equivalent to the "full" style package in the releases + Executes a full build for Cmder, including git. This is equivalent to the "full" style package in the releases .EXAMPLE .\build -verbose @@ -62,7 +62,7 @@ Ensure-Executable "7z" New-Item -Type Directory -Path (Join-Path $saveTo "/tmp/") -ErrorAction SilentlyContinue >$null foreach ($s in $sources) { - if($Full -eq $false -and $s.name -eq "msysgit"){ + if($Full -eq $false -and $s.name -eq "git-for-windows"){ Continue } From fc85915b2c7b879daa371567467ef4921b22bbf6 Mon Sep 17 00:00:00 2001 From: Benjamin Staneck Date: Fri, 28 Aug 2015 02:47:02 +0200 Subject: [PATCH 03/13] git 2.5 packages the unix commands in `/usr/bin` instead of `/bin`so add that to the path, too. --- vendor/init.bat | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/vendor/init.bat b/vendor/init.bat index 769a654..7ede112 100644 --- a/vendor/init.bat +++ b/vendor/init.bat @@ -38,7 +38,7 @@ :: Add git to the path @if defined GIT_INSTALL_ROOT ( - set "PATH=%GIT_INSTALL_ROOT%\bin;%GIT_INSTALL_ROOT%\share\vim\vim74;%PATH%" + set "PATH=%GIT_INSTALL_ROOT%\bin;%GIT_INSTALL_ROOT%\usr\bin;%GIT_INSTALL_ROOT%\share\vim\vim74;%PATH%" :: define SVN_SSH so we can use git svn with ssh svn repositories if not defined SVN_SSH set "SVN_SSH=%GIT_INSTALL_ROOT:\=\\%\\bin\\ssh.exe" ) From 5ce077a74af83c2308d53422c56c842484c25ef1 Mon Sep 17 00:00:00 2001 From: Benjamin Staneck Date: Fri, 28 Aug 2015 02:53:49 +0200 Subject: [PATCH 04/13] call git's own ssh-agent script instead of our own --- vendor/init.bat | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/vendor/init.bat b/vendor/init.bat index 7ede112..a7260ca 100644 --- a/vendor/init.bat +++ b/vendor/init.bat @@ -60,4 +60,4 @@ ) ) -:: @call "%CMDER_ROOT%/bin/agent.cmd" +:: @call "%GIT_INSTALL_ROOT%/cmd/start-ssh-agent.cmd" From 7fd43b939b17e04b33f4d2f8adf7c3aacc522300 Mon Sep 17 00:00:00 2001 From: Benjamin Staneck Date: Mon, 31 Aug 2015 04:40:10 +0200 Subject: [PATCH 05/13] delete our own, now obsolete agent launcher --- bin/agent.cmd | 46 ---------------------------------------------- 1 file changed, 46 deletions(-) delete mode 100644 bin/agent.cmd diff --git a/bin/agent.cmd b/bin/agent.cmd deleted file mode 100644 index 4eaa614..0000000 --- a/bin/agent.cmd +++ /dev/null @@ -1,46 +0,0 @@ -@ECHO OFF - -REM Set default sock file -SET SSH_AUTH_SOCK=/tmp/ssh-agent.sock - -REM Check socket is available -IF NOT EXIST "%TMP%\ssh-agent.sock" GOTO:RUNAGENT - -REM Check if an ssh-agent is running -FOR /f "tokens=*" %%I IN ('ps ^| grep ssh-agent ^| sed "s/^ *\([0-9]\+\) .*/\1/"') DO SET VAR=%%I -IF "%VAR%" == "" GOTO:RUNAGENT - -REM Check if socket file is valid -ssh-add -l 1> NUL 2>&1 -IF ERRORLEVEL 1 GOTO:RUNAGENT -GOTO:ADDKEYS - -:RUNAGENT -REM Remove old socket file -rm -f /tmp/ssh-agent.sock - -REM Run ssh-agent and save (last) PID in VAR -SET VAR= -FOR /f "tokens=*" %%J IN ('ssh-agent -a /tmp/ssh-agent.sock') DO FOR /f "tokens=*" %%K IN ('echo %%J ^| grep "SSH_AGENT_PID" ^| sed "s/^SSH_AGENT_PID=\([0-9]\+\); .*/\1/"') DO SET VAR=%%K - -:ADDKEYS -SET SSH_AUTH_PID=%VAR% - -REM Check if ssh keys are known -SET KEYS= -FOR /f "tokens=*" %%I IN ('DIR /B "%HOME%\.ssh\*_rsa"') DO CALL:CHECKKEY %%I - -REM Add missing ssh keys at once -IF NOT "%KEYS%" == "" ssh-add %KEYS% -GOTO:END - -REM Functions -REM Check if ssh key has to be added -:CHECKKEY -SET VAR= -FOR /f "tokens=*" %%J IN ('ssh-add -l ^| grep "%1"') DO SET VAR=%%J -IF "%VAR%" == "" SET KEYS='%HOME%\.ssh\%1' %KEYS% -GOTO:EOF - -:END -@ECHO ON From 801a4ac901d534c4f56e275a3ed59819ceba400b Mon Sep 17 00:00:00 2001 From: Benjamin Staneck Date: Mon, 31 Aug 2015 05:05:16 +0200 Subject: [PATCH 06/13] update readme --- README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 8146437..63094aa 100644 --- a/README.md +++ b/README.md @@ -64,9 +64,9 @@ All aliases will be saved in `/config/aliases` file ### SSH Agent -To start SSH agent simply call `agent`, which is in the `bin` folder. +To start SSH agent simply call `agent`, which is in the `vendor/git-for-windows/cmd` folder. -If you want to run SSH agent on startup, uncomment the line in `/vendor/init.bat`so it says `@call "%CMDER_ROOT%/bin/agent.cmd"`. +If you want to run SSH agent on startup, uncomment the line in `/vendor/init.bat`so it says `@call "%GIT_INSTALL_ROOT%/cmd/start-ssh-agent.cmd"`. ## Todo From 6952d602d2595a3296d5891951cbebaefaafbc76 Mon Sep 17 00:00:00 2001 From: Benjamin Staneck Date: Wed, 2 Sep 2015 19:50:44 +0200 Subject: [PATCH 07/13] update to 2.5.1 https://github.com/git-for-windows/git/releases/tag/v2.5.1.windows.1 --- vendor/sources.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/vendor/sources.json b/vendor/sources.json index 6eca667..c16c89a 100644 --- a/vendor/sources.json +++ b/vendor/sources.json @@ -1,8 +1,8 @@ [ { "name": "git-for-windows", - "version": "v2.5.0.windows.1", - "url": "https://github.com/git-for-windows/git/releases/download/v2.5.0.windows.1/PortableGit-2.5.0-32-bit.7z.exe" + "version": "v2.5.1.windows.1", + "url": "https://github.com/git-for-windows/git/releases/download/v2.5.1.windows.1/PortableGit-2.5.1-32-bit.7z.exe" }, { "name": "clink", From f783cd8addd1d86d43153e077628c8b07743eec2 Mon Sep 17 00:00:00 2001 From: Benjamin Staneck Date: Sat, 5 Sep 2015 00:04:51 +0200 Subject: [PATCH 08/13] fix readme --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 63094aa..0199493 100644 --- a/README.md +++ b/README.md @@ -64,7 +64,7 @@ All aliases will be saved in `/config/aliases` file ### SSH Agent -To start SSH agent simply call `agent`, which is in the `vendor/git-for-windows/cmd` folder. +To start SSH agent simply call `start-ssh-agent`, which is in the `vendor/git-for-windows/cmd` folder. If you want to run SSH agent on startup, uncomment the line in `/vendor/init.bat`so it says `@call "%GIT_INSTALL_ROOT%/cmd/start-ssh-agent.cmd"`. From 583109b6955201b7f3e232e00c284b12556b2690 Mon Sep 17 00:00:00 2001 From: Benjamin Staneck Date: Fri, 11 Sep 2015 22:53:21 +0200 Subject: [PATCH 09/13] update to 2.5.2 --- vendor/sources.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/vendor/sources.json b/vendor/sources.json index c16c89a..621aaae 100644 --- a/vendor/sources.json +++ b/vendor/sources.json @@ -1,8 +1,8 @@ [ { "name": "git-for-windows", - "version": "v2.5.1.windows.1", - "url": "https://github.com/git-for-windows/git/releases/download/v2.5.1.windows.1/PortableGit-2.5.1-32-bit.7z.exe" + "version": "v2.5.2.windows.1", + "url": "https://github.com/git-for-windows/git/releases/download/v2.5.2.windows.1/PortableGit-2.5.2-32-bit.7z.exe" }, { "name": "clink", From 4edec1675a9465deb4f042377c4260c4c9980d53 Mon Sep 17 00:00:00 2001 From: Benjamin Staneck Date: Wed, 16 Sep 2015 06:18:29 +0200 Subject: [PATCH 10/13] update to 2.5.2 release 2 --- vendor/sources.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/vendor/sources.json b/vendor/sources.json index 621aaae..8afad54 100644 --- a/vendor/sources.json +++ b/vendor/sources.json @@ -1,8 +1,8 @@ [ { "name": "git-for-windows", - "version": "v2.5.2.windows.1", - "url": "https://github.com/git-for-windows/git/releases/download/v2.5.2.windows.1/PortableGit-2.5.2-32-bit.7z.exe" + "version": "v2.5.2.windows.2", + "url": "https://github.com/git-for-windows/git/releases/download/v2.5.2.windows.2/PortableGit-2.5.2.2-32-bit.7z.exe" }, { "name": "clink", From b40b0067c006d75b521d57645132664d41872684 Mon Sep 17 00:00:00 2001 From: Benjamin Staneck Date: Wed, 23 Sep 2015 20:51:53 +0200 Subject: [PATCH 11/13] :arrow_up: Git to v2.5.3.windows.1 --- vendor/sources.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/vendor/sources.json b/vendor/sources.json index 8afad54..78d36ff 100644 --- a/vendor/sources.json +++ b/vendor/sources.json @@ -1,8 +1,8 @@ [ { "name": "git-for-windows", - "version": "v2.5.2.windows.2", - "url": "https://github.com/git-for-windows/git/releases/download/v2.5.2.windows.2/PortableGit-2.5.2.2-32-bit.7z.exe" + "version": "v2.5.3.windows.1", + "url": "https://github.com/git-for-windows/git/releases/download/v2.5.3.windows.1/PortableGit-2.5.3-32-bit.7z.exe" }, { "name": "clink", From 32cd7dcb585aa187b4264d9ee3a797f5a6b4ce52 Mon Sep 17 00:00:00 2001 From: Benjamin Staneck Date: Wed, 30 Sep 2015 20:35:13 +0200 Subject: [PATCH 12/13] :arrow_up: Git to v2.6.0.windows.1 --- vendor/sources.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/vendor/sources.json b/vendor/sources.json index 78d36ff..cc372d3 100644 --- a/vendor/sources.json +++ b/vendor/sources.json @@ -1,8 +1,8 @@ [ { "name": "git-for-windows", - "version": "v2.5.3.windows.1", - "url": "https://github.com/git-for-windows/git/releases/download/v2.5.3.windows.1/PortableGit-2.5.3-32-bit.7z.exe" + "version": "v2.6.0.windows.1", + "url": "https://github.com/git-for-windows/git/releases/download/v2.6.0.windows.1/PortableGit-2.6.0-32-bit.7z.exe" }, { "name": "clink", From 36291ab789172be3d58af0880be16c5bfcaee12d Mon Sep 17 00:00:00 2001 From: Benjamin Staneck Date: Tue, 6 Oct 2015 21:16:32 +0200 Subject: [PATCH 13/13] :arrow_up: Git for Windows to v2.6.1.windows.1 --- vendor/sources.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/vendor/sources.json b/vendor/sources.json index cc372d3..93f949d 100644 --- a/vendor/sources.json +++ b/vendor/sources.json @@ -1,8 +1,8 @@ [ { "name": "git-for-windows", - "version": "v2.6.0.windows.1", - "url": "https://github.com/git-for-windows/git/releases/download/v2.6.0.windows.1/PortableGit-2.6.0-32-bit.7z.exe" + "version": "v2.6.1.windows.1", + "url": "https://github.com/git-for-windows/git/releases/download/v2.6.1.windows.1/PortableGit-2.6.1-32-bit.7z.exe" }, { "name": "clink",