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

Re: error: cannot run hooks/pre-receive: No such file or directory

From
Computer Druid <computerdruid@gmail.com>
Date
Mar 30, 2011, 18:35 UTC
Message-ID
<AANLkTimkVSL52Bhdhnu+OC8SWzfUJ7ZK0KBcydjG4wXT@mail.gmail.com>
In-Reply-To
<AANLkTinehsLJWYona7ONqquWpCZozr3hW-JNMhYz4Rvn@mail.gmail.com>

On Wed, Mar 30, 2011 at 9:27 AM, Mathieu Malaterre <mathieu.malaterre@gmail.com> wrote:

Show 23 quoted lines
> Hi all,
>
>  I am trying to use a ruby script to reject commit with non-linear
> history (*). However it keeps failing with the following message:
>
> $ git push
> Counting objects: 5, done.
> Delta compression using up to 4 threads.
> Compressing objects: 100% (3/3), done.
> Writing objects: 100% (3/3), 304 bytes, done.
> Total 3 (delta 2), reused 0 (delta 0)
> error: cannot run hooks/pre-receive: No such file or directory
> To ssh://malat@gdcm.git.sourceforge.net/gitroot/gdcm/gdcm.old
>  ! [remote rejected] master -> master (pre-receive hook declined)
> error: failed to push some refs to
> 'ssh://malat@gdcm.git.sourceforge.net/gitroot/gdcm/gdcm.old'
>
> I tried with something as simple as :
>
> % cat pre-receive
> #!/usr/bin/ruby
> % which ruby
> /usr/bin/ruby
Check that hooks/pre-receive is executable? (chmod +x)
Previous: Mathieu MalaterreNext: Jeff King
Message 2 of 4 in “error: cannot run hooks/pre-receive: No such file or directory”
  1. Mathieu MalaterreMar 30, 2011
  2. Computer DruidMar 30, 2011
  3. Jeff KingMar 30, 2011
  4. Mathieu MalaterreMar 31, 2011

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.