Skip to content

Commit

Permalink
Merge pull request #4 from zegervdv/zegervdv-settables
Browse files Browse the repository at this point in the history
Make compliant with cmd2 > 0.10.0
  • Loading branch information
tleonhardt authored Feb 21, 2020
2 parents 12143ff + b755150 commit ef8c90a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion cmd2_abbrev/abbrev.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ def __init__(self, *args, **kwargs):
# code placed here runs after cmd2 initializes
# this is where you register any hook functions
self.abbrev = False
self.settable.update({'abbrev': 'Accept command abbreviations'})
self.add_settable(cmd2.Settable('abbrev', bool, 'Accept command abbreviations'))
self.register_postparsing_hook(self.cmd2_abbrev_hook)

def cmd2_abbrev_hook(self, data: cmd2.plugin.PostparsingData) -> cmd2.plugin.PostparsingData:
Expand Down

0 comments on commit ef8c90a

Please sign in to comment.