diff --git a/infinitepush/__init__.py b/infinitepush/__init__.py --- a/infinitepush/__init__.py +++ b/infinitepush/__init__.py @@ -351,11 +351,9 @@ destpath = path.pushloc or path.loc other = hg.peer(repo, opts, destpath) if not names: - defaultscratchpatterns = ui.configlist( - 'infinitepush', 'defaultremotepatterns', ['*']) - fetchedbookmarks = other.listkeyspatterns( - 'bookmarks', patterns=defaultscratchpatterns) - fetchedbookmarks.update(other.listkeys('bookmarks')) + raise error.Abort( + '--list-remote requires a bookmark pattern', + hint='use "hg book" to get a list of your local bookmarks') else: fetchedbookmarks = other.listkeyspatterns('bookmarks', patterns=names) diff --git a/tests/test-infinitepush-bundlestore.t b/tests/test-infinitepush-bundlestore.t --- a/tests/test-infinitepush-bundlestore.t +++ b/tests/test-infinitepush-bundlestore.t @@ -371,12 +371,13 @@ scratch/anotherbranch 1de1d7d92f8965260391d0513fe8a8d5973d3042 scratch/mybranch 8872775dd97a750e1533dc1fbbca665644b32547 $ hg book --list-remote - newbook 0000000000000000000000000000000000000000 - scratch/anotherbranch 1de1d7d92f8965260391d0513fe8a8d5973d3042 - scratch/mybranch 8872775dd97a750e1533dc1fbbca665644b32547 + abort: --list-remote requires a bookmark pattern + (use "hg book" to get a list of your local bookmarks) + [255] $ hg book --config infinitepush.defaultremotepatterns=scratch/another* --list-remote - newbook 0000000000000000000000000000000000000000 - scratch/anotherbranch 1de1d7d92f8965260391d0513fe8a8d5973d3042 + abort: --list-remote requires a bookmark pattern + (use "hg book" to get a list of your local bookmarks) + [255] $ hg book --list-remote scratch/my $ hg book --list-remote scratch/my* scratch/mybranch 8872775dd97a750e1533dc1fbbca665644b32547