From: "Daniel Ferreira (theiostream)" <bnmvco@gmail.com>
To: Michael Haggerty <mhagger@alum.mit.edu>
Cc: Git Mailing List <git@vger.kernel.org>,
Junio C Hamano <gitster@pobox.com>,
Stefan Beller <sbeller@google.com>,
Duy Nguyen <pclouds@gmail.com>
Subject: Re: [PATCH v5 4/6] dir_iterator: add tests for dir_iterator API
Date: Thu, 30 Mar 2017 15:25:43 -0300 [thread overview]
Message-ID: <CAEA2_RL18TarW6k5keP+ADFDv+VZE+gG3e6EkCmWby7GjG-T_w@mail.gmail.com> (raw)
In-Reply-To: <ab7a326c-0189-4542-76e8-649eb6e804c9@alum.mit.edu>
On Thu, Mar 30, 2017 at 4:46 AM, Michael Haggerty <mhagger@alum.mit.edu> wrote:
> Is there a special reason to write the date to the file as opposed to, say
>
> touch dir/b
>
> ? (Some people use `: >dir/b` for this purpose, though I've never found
> out why.) If you write the date to the file, the reader will be
> distracted unnecessarily wondering whether the contents are important to
> the test.
>
There's no reason. They will be `touch`ed instead of written in a next version.
`:` is a bash builtin that that returns an exit code of zero and
produces no output. On my Mac at least:
bash-3.2$ type :
: is a shell builtin
bash-3.2$ type touch
touch is /usr/bin/touch
I suppose there are reasons to try to keep the most of a shell
script's logic within the shell itself, without involving external
binaries.
next prev parent reply other threads:[~2017-03-30 18:26 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-03-30 3:32 [PATCH v5 0/6] [GSoC] remove_subtree(): reimplement using iterators Daniel Ferreira
2017-03-30 3:32 ` [PATCH v5 1/6] dir_iterator: add helpers to dir_iterator_advance Daniel Ferreira
2017-03-30 3:32 ` [PATCH v5 2/6] dir_iterator: refactor state machine model Daniel Ferreira
2017-03-30 8:18 ` Michael Haggerty
2017-03-30 3:32 ` [PATCH v5 3/6] dir_iterator: iterate over dir after its contents Daniel Ferreira
2017-03-30 11:03 ` Michael Haggerty
2017-03-30 3:32 ` [PATCH v5 4/6] dir_iterator: add tests for dir_iterator API Daniel Ferreira
2017-03-30 7:46 ` Michael Haggerty
2017-03-30 18:25 ` Daniel Ferreira (theiostream) [this message]
2017-04-01 9:03 ` Jeff King
2017-04-01 17:16 ` Junio C Hamano
2017-03-30 7:48 ` Michael Haggerty
2017-03-30 8:05 ` Michael Haggerty
2017-03-30 18:26 ` Daniel Ferreira (theiostream)
2017-03-30 3:32 ` [PATCH v5 5/6] remove_subtree(): reimplement using iterators Daniel Ferreira
2017-03-30 3:32 ` [PATCH v5 6/6] remove_subtree(): test removing nested directories Daniel Ferreira
2017-03-30 11:07 ` Michael Haggerty
2017-03-30 11:27 ` [PATCH v5 0/6] [GSoC] remove_subtree(): reimplement using iterators Michael Haggerty
2017-03-30 12:10 ` Duy Nguyen
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=CAEA2_RL18TarW6k5keP+ADFDv+VZE+gG3e6EkCmWby7GjG-T_w@mail.gmail.com \
--to=bnmvco@gmail.com \
--cc=git@vger.kernel.org \
--cc=gitster@pobox.com \
--cc=mhagger@alum.mit.edu \
--cc=pclouds@gmail.com \
--cc=sbeller@google.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).