Re: [hackers] [sbase] [PATCH] Add .gitignore

From: Quentin Rameau <quinq_AT_fifth.space>
Date: Mon, 17 Jun 2019 23:53:54 +0200

> On 2019-06-17, Quentin Rameau <quinq_AT_fifth.space> wrote:
> >> How do you deal with ~250 lines of "Untracked files:" in the `git
> >> status` output?
> >>
> >> If you want to see them, you can always run `git status --ignored`.
> >
> > If you want it, you can always run `make .gitignore` *once*.
>
> Once for every clone of sbase.

Yes, as opposed to once for every git status command issued.

> >> >> The place for user-specific and repository-specific ignored files is
> >> >> .git/info/exclude. But in general, we don't know the location of the
> >> >> .git directory, so we'd probably have to use some git command to
> >> >> figure out exactly where to put it.
> >> >
> >> > There's no “we”, that's the user's responsability to figure out where
> >> > to put it.
> >>
> >> There is a "we" if a Makefile rule were to be added, since it needs to
> >> create the file at the appropriate location.
> >
> > The appropriate location is .gitignore.
>
> No, see gitignore(5):
>
> * Patterns which should be version-controlled and distributed to other
> repositories via clone (i.e., files that all developers will want to
> ignore) should go into a .gitignore file.
>
> * Patterns which are specific to a particular repository but which do
> not need to be shared with other related repositories (e.g., auxiliary
> files that live inside the repository but are specific to one user’s
> workflow) should go into the $GIT_DIR/info/exclude file.
>
> * Patterns which a user wants Git to ignore in all situations (e.g.,
> backup or temporary files generated by the user’s editor of choice)
> generally go into a file specified by core.excludesFile in the user’s
> ~/.gitconfig. Its default value is $XDG_CONFIG_HOME/git/ignore. If
> $XDG_CONFIG_HOME is either not set or empty, $HOME/.config/git/ignore
> is used instead.
>
> >> > What's the rationale for having it duplicated both in the SCM and in
> >> > the
> >> > Makefile then?
> >>
> >> So that if a utility is added or removed, .gitignore can easily be kept in
> >> sync.
> >
> > So what's the point of having .gitignore tracked by the SCM?
>
> So that it gets applied by default.

It seems you're deliberately not answering the question, or are
suggesting bloating the make/SCM system with a justification for
lazyness.

You asked if there was any objection to this, you got some, now do what
you want.

But pushing it both into the Makefile and the SCM is not justified at
all, chose either one.
Received on Mon Jun 17 2019 - 23:53:54 CEST

This archive was generated by hypermail 2.3.0 : Tue Jun 18 2019 - 00:00:38 CEST