Support passing --force to repoman.

This commit is contained in:
Michał Górny 2010-07-12 11:45:15 +02:00
parent 0786203159
commit 349d6ae12f

View File

@ -113,6 +113,7 @@ Options:
-c, --changelog backwards compat (ignored), -c, --changelog backwards compat (ignored),
-C, --nocolor disable colorful output, -C, --nocolor disable colorful output,
-f, --force force repoman to proceed with the commit,
-t, --trivial trivial changes (do not add a ChangeLog entry), -t, --trivial trivial changes (do not add a ChangeLog entry),
-v, --verbose enable verbose output. -v, --verbose enable verbose output.
_EOH_ _EOH_
@ -120,7 +121,7 @@ _EOH_
# Guess what! # Guess what!
main() { main() {
local commitmsg monochrome trivial local commitmsg force monochrome trivial
unset SC_VERBOSE unset SC_VERBOSE
while [ ${#} -gt 0 ]; do while [ ${#} -gt 0 ]; do
@ -140,6 +141,9 @@ main() {
-C|--nocolor) -C|--nocolor)
monochrome=1 monochrome=1
;; ;;
-f|--force)
force=1
;;
-t|--trivial) -t|--trivial)
trivial=1 trivial=1
;; ;;
@ -254,7 +258,7 @@ main() {
fi fi
sayv "Now, let's let repoman do its job..." sayv "Now, let's let repoman do its job..."
exec repoman commit ${old_repoman--a} -m "${SC_CP}: ${commitmsg}" exec repoman commit ${old_repoman--a} ${force+-f} -m "${SC_CP}: ${commitmsg}"
;; ;;
esac esac
} }