~ubuntu-branches/ubuntu/oneiric/bugzilla/oneiric

« back to all changes in this revision

Viewing changes to debian/maintenance/16_python_shebang.sh

  • Committer: Bazaar Package Importer
  • Author(s): Raphael Bossek
  • Date: 2008-06-27 22:34:34 UTC
  • mfrom: (1.1.7 upstream)
  • Revision ID: james.westby@ubuntu.com-20080627223434-0ib57vstn43bb4a3
Tags: 3.0.4.1-1
* Update of French, Russian and German translations. (closes: #488251)
* Added Bulgarian and Belarusian translations.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
#! /bin/sh
 
2
# Where to find Python on Debian systems.
 
3
 
 
4
set -e
 
5
 
 
6
echo "> $0 $*"
 
7
 
 
8
for f in `find $1 -type f`; do
 
9
        for s in '#.*!.*python.*'; do
 
10
                if grep -q "^$s" $f; then
 
11
                        cp -p $f $f.new
 
12
                        sed -e "s,^$s,#! /usr/bin/python,g" $f > $f.new
 
13
                        diff -u $f $f.new || true
 
14
                        mv -f $f.new $f
 
15
                fi
 
16
        done
 
17
done