Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(41)

Issue 4969065: code review 4969065: hgpatch: workaround for 'hg -q incoming' on windows. (Closed)

Can't Edit
Can't Publish+Mail
Start Review
Created:
14 years, 1 month ago by mattn
Modified:
14 years ago
Reviewers:
golang-dev, rsc, brainman, peterGo
CC:
golang-dev
Visibility:
Public.

Description

hgpatch: workaround for 'hg -q incoming' on windows. Mercurial provides binary package and source package for windows. If using binary package, hg.exe return 1 for exit code correctly. But hg.bat does not return 1. This is workaround to get exit code from batch file like following. cmd /v:on /c hg -q incoming & exit !ERRORLEVEL! This is working fine for both packages.

Patch Set 1 #

Patch Set 2 : diff -r c0fea223bc90 http://go.googlecode.com/hg/ #

Patch Set 3 : diff -r c0fea223bc90 http://go.googlecode.com/hg/ #

Unified diffs Side-by-side diffs Delta from patch set Stats (+12 lines, -1 line) Patch
M src/cmd/hgpatch/main.go View 1 2 chunks +12 lines, -1 line 0 comments Download

Messages

Total messages: 18
mattn
Hello golang-dev@googlecode.com, rsc@golang.org (cc: golang-dev@googlegroups.com), I'd like you to review this change to http://go.googlecode.com/hg/
14 years, 1 month ago (2011-09-08 02:20:16 UTC) #1
rsc
Do most people have hg.exe or hg.bat? Is the buggy hg behavior common enough to ...
14 years, 1 month ago (2011-09-08 02:24:17 UTC) #2
mattn
This is behavior of windows. If the user install hg from source code, 'setup.py' make ...
14 years, 1 month ago (2011-09-08 02:36:06 UTC) #3
brainman
On 2011/09/08 02:36:06, mattn wrote: > > GetExitCodeProcess() can't exit code from batch file. > ...
14 years, 1 month ago (2011-09-08 02:58:22 UTC) #4
mattn
On Thursday, September 8, 2011 11:58:22 AM UTC+9, brainman wrote: > > If someone creates ...
14 years, 1 month ago (2011-09-08 03:15:44 UTC) #5
brainman
On 2011/09/08 03:15:44, mattn wrote: > > No, As long as that hg is batch ...
14 years, 1 month ago (2011-09-08 03:25:35 UTC) #6
rsc
This only matters for people developing Go on Windows, since hgpatch is only used by ...
14 years, 1 month ago (2011-09-08 03:32:39 UTC) #7
mattn
Are you saying mercurial MUST provide hg.bat using "exit /b" ? Then, that's right :) ...
14 years, 1 month ago (2011-09-08 03:34:12 UTC) #8
brainman
On 2011/09/08 03:34:12, mattn wrote: > Are you saying mercurial MUST provide hg.bat using "exit ...
14 years, 1 month ago (2011-09-08 03:42:34 UTC) #9
mattn
On Thursday, September 8, 2011 12:42:35 PM UTC+9, brainman wrote: > > On 2011/09/08 03:34:12, ...
14 years, 1 month ago (2011-09-08 03:55:58 UTC) #10
brainman
On 2011/09/08 03:55:58, mattn wrote: > > ... it will take many times until that ...
14 years, 1 month ago (2011-09-08 04:12:21 UTC) #11
mattn
Sorry, I just noticed important thing. I added following line into hg.bat, exit /b 1 ...
14 years, 1 month ago (2011-09-08 04:27:10 UTC) #12
mattn
Hmm, On the second thought, GetExitCodeProcess() can't get exit code from batch file. seems impossible ...
14 years, 1 month ago (2011-09-08 05:01:40 UTC) #13
rsc
It looks to me like hg.bat should say exit, and not exit /b. exit /b ...
14 years, 1 month ago (2011-09-08 18:02:39 UTC) #14
mattn
Yes, If pass exit code to cmd.exe, we should call as: cmd /c call hg.bat ...
14 years, 1 month ago (2011-09-08 18:14:18 UTC) #15
peterGo
Russ, On 2011/09/08 03:32:39, rsc wrote: > Can we tell people developing on Windows > ...
14 years, 1 month ago (2011-09-09 13:28:33 UTC) #16
mattn
> On 2011/09/08 03:32:39, rsc wrote: > > Can we tell people developing on Windows ...
14 years ago (2011-09-21 00:37:11 UTC) #17
mattn
14 years ago (2011-09-26 06:41:55 UTC) #18
*** Abandoned ***
Sign in to reply to this message.

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld f62528b