Re: [PATCH 0/9] remove dead shell code

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, Sep 2, 2021 at 6:04 PM Ævar Arnfjörð Bjarmason <avarab@xxxxxxxxx> wrote:
>
> Remove dead shell code in git-sh-setup, inspired by parallel
> discussion on another topic (but the two don't conflict):
> https://lore.kernel.org/git/87lf4f9gre.fsf@xxxxxxxxxxxxxxxxxxx/
>
> The last two patches were picked from a dropped series of mine
> submitted earlier this year, it was dropped because of other more
> complex patches that I haven't included here:
> https://lore.kernel.org/git/20210311001447.28254-1-avarab@xxxxxxxxx/
>
[...]

Hm, I have scripts here, implementing some porcelain commands which
follow the same approach as
the git porcelain scripts, e.g.

  #!/bin/bash
  SUBDIRECTORY_OK=Yes
  . git-sh-setup
  require_work_tree
  require_clean_work_tree
  cd_to_toplevel || die "Can't find top level for the git repo"
  set_reflog_action my-special-script                          # this
will be broken by the patch series

I was under the impression that this is how it should be done when one
needs to write some custom git scripts.
If that is the case, then removing these functions might break some
other users scripts out there.
At least  I have a quite an old self written script here which uses
`set_reflog_action`.
Obviously I can manage and adapt the script, but the more generic
question comes to mind if sourcing git-sh-setup
by end users is the correct approach to write porcelain scripts!

-Peter




[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux