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

Re: [PATCH/RFC 0/7] Support for Ruby

From
Felipe Contreras <felipe.contreras@gmail.com>
Date
Sep 28, 2013, 23:06 UTC
Message-ID
<CAMP44s0JnG8wQ6DhHxbrdoxhdt3UTC8WG6R2yVmctGntEx0yzQ@mail.gmail.com>
In-Reply-To
<20130921235647.GC235845@vauxhall.crustytoothpaste.net>

On Sat, Sep 21, 2013 at 6:56 PM, brian m. carlson <sandals@crustytoothpaste.net> wrote:

> On Sat, Sep 21, 2013 at 05:52:05PM -0500, Felipe Contreras wrote:
>> On Sat, Sep 21, 2013 at 4:29 PM, brian m. carlson
>> <sandals@crustytoothpaste.net> wrote:
Show 12 quoted lines
>> Now, if anybody has ideas into how the bindings could be more object
>> oriented, I'm all ears, but unfortunately what I foresee is that
>> nobody will consider this proposal seriously.
>
> My concern is that the Ruby code will end up not being idiomatic, and
> people will view it as bizarre and unmaintainable.
>
> for_each_ref could end up being something like REPOSITORY.refs.each,
> which would be more idiomatic.  repository.refs would probably be an
> Enumerator in that case.  If the decision is made to incorporate Ruby
> code, I'm happy to submit some patches to help provide a sane interface,
> even though I'm not that familiar with Ruby.
I think my proposed bindings are quite idiomatic.

git ruby - master origin/master <<EOF commits = ARGV.map { |id| Git::Commit.get(get_sha1(id)) } puts get_merge_bases(commits, 0).map { |commit| sha1_to_hex(commit.sha1) } EOF

-- 
Felipe Contreras
Previous: Felipe Contreras
Message 26 of 26 in “Support for Ruby”
  1. 0/7 Support for RubyFelipe Contreras, Sep 21, 2013
  2. 1/7 Add support for ruby commandsFelipe Contreras, Sep 21, 2013
  3. 2/7 ruby: add setup scriptFelipe Contreras, Sep 21, 2013
  4. 3/7 ruby: add simple wrappersFelipe Contreras, Sep 21, 2013
  5. 4/7 ruby: rewrite 'request-pull'Felipe Contreras, Sep 21, 2013
  6. 5/7 ruby: rewrite perl scriptFelipe Contreras, Sep 21, 2013
  7. 6/7 ruby: remove one forkFelipe Contreras, Sep 21, 2013
  8. 7/7 ruby: rewrite 'reset'Felipe Contreras, Sep 21, 2013
  9. brian m. carlsonSep 21, 2013
  10. Felipe ContrerasSep 21, 2013
  11. brian m. carlsonSep 21, 2013
  12. Felipe ContrerasSep 22, 2013
  13. Fredrik GustafssonSep 22, 2013
  14. Felipe ContrerasSep 22, 2013
  15. Fredrik GustafssonSep 22, 2013
  16. Felipe ContrerasSep 22, 2013
  17. Patrick DonnellySep 23, 2013
  18. Felipe ContrerasSep 23, 2013
  19. Patrick DonnellySep 23, 2013
  20. Felipe ContrerasSep 23, 2013
  21. Junio C HamanoSep 23, 2013
  22. brian m. carlsonSep 23, 2013
  23. Felipe ContrerasSep 28, 2013
  24. Felipe ContrerasSep 23, 2013
  25. Felipe ContrerasSep 28, 2013
  26. Felipe ContrerasSep 28, 2013

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.