GitHub PullRequestReviewCommentEvent at 2014-03-06 15:36:54
Repository: docker
Actor: tianon
Payload: {"comment":{"url":"https://api.github.com/repos/dotcloud/docker/pulls/comments/10346193","id":10346193,"diff_hunk":"@@ -128,10 +140,15 @@ set -x\n \n # bootstrap\n mkdir -p \"$target\"\n-sudo http_proxy=$http_proxy debootstrap --verbose --variant=\"$variant\" --include=\"$include\" --arch=\"$arch\" \"$suite\" \"$target\" \"$mirror\"\n+variantarg=\n+if [ \"z$variant\" != \"z\" ]; then\n+    variantarg=--variant=\"$variant\"\n+fi\n+sudo http_proxy=$http_proxy debootstrap --verbose $variantarg --include=\"$include\" --arch=\"$arch\" \"$suite\" \"$target\" \"$mirror\"","path":"contrib/mkimage-debootstrap.sh","position":53,"original_position":53,"commit_id":"25dbf542ff7ee2f8c55bf214a85acab88f1e756f","original_commit_id":"25dbf542ff7ee2f8c55bf214a85acab88f1e756f","user":{"login":"tianon","id":161631,"avatar_url":"https://gravatar.com/avatar/e9917c00ce99aa2b0ecb82e942d01a09?d=https%3A%2F%2Fidenticons.github.com%2Fafe859ad34f103183ef7900a5936a53a.png&r=x","gravatar_id":"e9917c00ce99aa2b0ecb82e942d01a09","url":"https://api.github.com/users/tianon","html_url":"https://github.com/tianon","followers_url":"https://api.github.com/users/tianon/followers","following_url":"https://api.github.com/users/tianon/following{/other_user}","gists_url":"https://api.github.com/users/tianon/gists{/gist_id}","starred_url":"https://api.github.com/users/tianon/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tianon/subscriptions","organizations_url":"https://api.github.com/users/tianon/orgs","repos_url":"https://api.github.com/users/tianon/repos","events_url":"https://api.github.com/users/tianon/events{/privacy}","received_events_url":"https://api.github.com/users/tianon/received_events","type":"User","site_admin":false},"body":"So, a couple comments here.  The convention in this script is camelCasing, so please use `variantArg`, and this is explicitly bash, so the \"z\" hacks are unnecessary in the condition (ie, `[ \"$variant\" ]` is sufficient and preferred), and `$variantArg` in the debootstrap arguments probably ought to be quoted, to be safe (ie, `\"$variantArg\"`).","created_at":"2014-03-06T15:36:54Z","updated_at":"2014-03-06T15:36:54Z","html_url":"https://github.com/dotcloud/docker/pull/4497#discussion_r10346193","pull_request_url":"https://api.github.com/repos/dotcloud/docker/pulls/4497","_links":{"self":{"href":"https://api.github.com/repos/dotcloud/docker/pulls/comments/10346193"},"html":{"href":"https://github.com/dotcloud/docker/pull/4497#discussion_r10346193"},"pull_request":{"href":"https://api.github.com/repos/dotcloud/docker/pulls/4497"}}}}