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

  • SEARCH
  • Home
  • 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 6876775
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T04:31:11+00:00 2026-05-27T04:31:11+00:00

This seems to be very basic question but I am knocked out. How to

  • 0

This seems to be very basic question but I am knocked out. How to test those scripts which one has written for hooking purpose.

As we know that script is running in background and only error is throwing back on us by SVN console. I tried with breakpoint but there is nothing I can provide input to the script.

Does anyone got any idea about it. I am writing svn hook script on windows so many already written hook scripts either not running or not giving desired output for example check mime-type and eol script from apache.

  • 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-05-27T04:31:11+00:00Added an answer on May 27, 2026 at 4:31 am

    I can give you some advice:

    • You need to print out to STDERR. That’s the only way your script will report errors to you. You can use this for actual testing.
    • I wrote my pre-commit script to take both a -t or an -r command line parameter. When executing as a pre-commit hook, I can use the -t parameter to pass in the transaction number. When running it from the command line, I can use the -r parameter and give it a revision number to run against.
    • I also wrote a debug function that allowed me to print out information when I set a -debug command line parameter. I could turn this on and off.
    • If you are actually testing your hook, use a copy of the repository, and make sure that the pre-commit shell script will fail by ending it with an exit code of 2. You’ll never commit your transaction, but you’ll get messages in your pre-commit script what is going on (that is, if you print everything to STDERR).

    You can look at the hook scripts I’m developing to get some ideas. I use the Data::Dumper Perl module which can help print out data structures in my script.

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

Sidebar

Related Questions

This seems like a very basic question but I couldn't find any help on
Maybe I am wrong, but this seems to be a very basic question. Suddenly
This question seems to be very basic, but I don't know why, there is
this is might be a very basic question, but seems like it's not easy
I realise that this must be a very basic question, but my google-fu seems
This seems very basic and I must be missing something, but here goes anyways...
This is probably a very basic question but I haven't found any detailed information
This seems to me like a very simple question, but I can't seem to
This may be a very basic question but somehow it got me tricked... when
I feel like this is a very basic CSS question: There seems 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.