Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8193523
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 7, 20262026-06-07T04:30:26+00:00 2026-06-07T04:30:26+00:00

I am trying to use a pre-commit hook for Git. The hook looks like

  • 0

I am trying to use a pre-commit hook for Git. The hook looks like the following:

#!/bin/bash
echo "fail"
exit 1

Thus, it will always fail, i.e. my Git commit should fail.

If I add something with git and then commit it in the commandline I nicely get a fail and my commit fails.

But if I commit with NetBeans, my pre-commit hook does not get executed. It simply seems to ignore it.

I am using Ubuntu and NetBeans 7.1. The permissions for the pre-commit hook are -rwxrwxrwx (just changed it to 777 for testing purposes).

How is this possible?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-07T04:30:27+00:00Added an answer on June 7, 2026 at 4:30 am

    It looks like that. Yes.

    If you look at the NetBeans Git Integration Plan, you’ll notice that there’s no support for hooks planned at all.

    Apart of this, I wouldn’t rely on any IDE integration of Git but use the command line. What if you decide to drop NetBeans tomorrow and use Eclipse instead? Or Visual Studio? Or KDevelop? You’ll have to learn a new IDE and again the integration of Git in the IDE. And you must hope that the developers of the IDE plugin did really implement that subset of Git that you need. It is a waste of time.

    Furthermore, the implementation of Git in NetBeans is far from complete. The features named as nice-to-have (stash, cherry-pick, rebase) are super-useful. Other killer features aren’t even mentioned (git bisect anyone?).

    Take the command line. Learn to use Git with it. Save your time.


    Looking at M2 of the NetBeans Git Integration Plan, one could see that the targeted backend for Git shall not be a native (i.e. platform specific) implementation of Git but jgit. That’s a totally braindead approach. Nearly every platform that you’re going to develop with has a native implementation of Git. The JNI exists. Why not take the platform specific binaries (that are surely better tested than a pure from-scratch Java implementation of the commands), put a small JNI wrapper around and you’re done? Yes, you’re going to lose write-once-run-everywhere, but stability and code quality would grow.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm trying to use mod_rewrite to achieve the following rewrite: From - http:// pre.domain.com/public/?project=Awesome
Using tortoiseSVN client side hook script for pre-commit, we are trying to run some
I'm trying to use ThreadLocal to provide thread safety to pre-existing non-thread-safe classes, but
I'm trying use mod_rewrite to rewrite URLs from the following: http://www.site.com/one-two-file.php to http://www.site.com/one/two/file.php The
trying to use hibernate with my web app and getting following exception: Initial SessionFactory
I wrote the following pre-commit script for SVN to validate that a user has
I'm trying to test some Subversion commit hooks, but when I use the simplest
I installed Bundler on a pre-Rails 3 application and am trying to use it
I'm trying to use git push heroku master to upload my rails 3 app
I'm trying to use a pre-build event in Visual Studio (VS 2005 to be

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.