File: get_upstream_version.sh

package info (click to toggle)
muttprint 0.72d-8etch1
  • links: PTS
  • area: main
  • in suites: etch
  • size: 1,184 kB
  • ctags: 1
  • sloc: makefile: 73; sh: 67
file content (10 lines) | stat: -rw-r--r-- 292 bytes parent folder | download | duplicates (12)
1
2
3
4
5
6
7
8
9
10
#!/bin/sh

# determine upstream version from the entry in debian/changelog
# 
# thanks Josip Rodin, it  looks ugly but doesn't have much fork()'s
# address comments to him  - <joy@debian.org> :)

perl -pe 's/^.*\((?:[^:]+:)?([^-]+)(?:-\S+)?\).*$/$1/; last if ($. > 1)' \
	< debian/changelog