Tagged: shell script RSS Toggle Comment Threads | Keyboard Shortcuts

  • John 12:45 am on October 5, 2009 Permalink | Reply
    Tags: , shell script,   

    SVN Notify by Email 

    Svn hook to email you information in post commit hook.

    Install svnnotify which will be used to send the email

    yum install perl-CPAN
    perl -MCPAN -e 'install SVN::Notify'
    perl -MCPAN -e 'install SVN::Notify::HTML::ColorDiff'
    

    The post-commit script

    #!/bin/sh
    for i in 'email1@domain.co.uk' 'email2@domain.com'
    do
    	svnnotify --repos-path "$1" \
    		--revision "$2" \
    		--to $i \
    		--from account@example.co.uk \
    		--handler HTML::ColorDiff -d \
    done
    
     
    • SonPhan 3:20 am on November 28, 2009 Permalink | Reply

      Hi , Please help me , How can i configure my svn server auto send mail with SVN-Notify modules?
      I have did as you show, but it can’t send mail.
      :(

  • John 4:45 pm on March 28, 2009 Permalink | Reply
    Tags: , shell script   

    Get PDF Word Count In Linux 

    Quick easy way to get the word count of a pdf.

    # pdfwc.sh
    # usage ./pdfwc.sh filename.pdf
    #
    TMPFILE=___tmpfile.tmp
    pdftotext $1 $TMPFILE
    wc $TMPFILE -w
    rm $TMPFILE
    
     
    • Jonas 3:50 am on July 30, 2009 Permalink | Reply

      Would probably do:
      #!/bin/sh
      # pdfwc.sh
      # usage ./pdfwc.sh filename.pdf
      #
      pdftotext $1 – | wc -w
      #__EOF__

      instead.

c
compose new post
j
next post/next comment
k
previous post/previous comment
r
reply
e
edit
o
show/hide comments
t
go to top
l
go to login
h
show/hide help
shift + esc
cancel