git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH] Add git-submodule command

From
LHLars Hjemli <hjemli@gmail.com>
Date
May 25, 2007, 22:33 UTC
Message-ID
<8c5c35580705251533r21a3dea5w5d263fad9f8bbfa7@mail.gmail.com>
In-Reply-To
<Pine.LNX.4.64.0705251924280.4648@racer.site>
On 5/25/07, Johannes Schindelin <Johannes.Schindelin@gmx.de> wrote:
> [* many usefull comments about the docs *]
Thanks, will fix
Show 9 quoted lines
> > +USAGE='[--init | --update | --cached] [--quiet] [--] [<path>...]'
> > +. git-sh-setup
> > +require_work_tree
>
> Maybe
>
>         test -f "$GIT_DIR"/.gitmodules || die "Not a superproject"
>
> Hmm?

Yeah, maybe. But the command will only touch entries with mode 160000 anyway, so it might not be a big deal.

>
> > +                     rmdir "$path" 2>/dev/null ||
>
> Just out of curiousity: is rmdir portable? I always used "rm -r"...

I have no idea, really. But the reason for using rmdir was this section of the man page:

NAME
       rmdir - remove empty directories

I do not want to delete an unempty directory. But there is probably some better way to do this?

-- larsh

Previous: Johannes Schindelin
Message 26 of 26 in “Add git-submodule command”
  1. Add git-submodule commandLars Hjemli, May 25, 2007
  2. Johannes SchindelinMay 25, 2007
  3. Johannes SchindelinMay 25, 2007
  4. Lars HjemliMay 25, 2007
  5. Johannes SchindelinMay 25, 2007
  6. Lars HjemliMay 25, 2007
  7. Johannes SchindelinMay 25, 2007
  8. Lars HjemliMay 25, 2007
  9. Add git-submodule commandLars Hjemli, May 25, 2007
  10. Johannes SchindelinMay 25, 2007
  11. Junio C HamanoMay 25, 2007
  12. Lars HjemliMay 25, 2007
  13. Junio C HamanoMay 25, 2007
  14. Lars HjemliMay 25, 2007
  15. Add git-submodule commandLars Hjemli, May 26, 2007
  16. Johannes SchindelinMay 26, 2007
  17. Junio C HamanoMay 26, 2007
  18. Lars HjemliMay 26, 2007
  19. Johannes SchindelinMay 26, 2007
  20. Add git-submodule commandLars Hjemli, May 26, 2007
  21. Simon HausmannMay 26, 2007
  22. Lars HjemliMay 26, 2007
  23. Johannes SchindelinMay 25, 2007
  24. Linus TorvaldsMay 25, 2007
  25. Johannes SchindelinMay 25, 2007
  26. Lars HjemliMay 25, 2007

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.