Page Menu
Home
Software Heritage
Search
Configure Global Search
Log In
Files
F7124050
D2328.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
620 B
Subscribers
None
D2328.diff
View Options
diff --git a/swh/core/cli/__init__.py b/swh/core/cli/__init__.py
--- a/swh/core/cli/__init__.py
+++ b/swh/core/cli/__init__.py
@@ -24,14 +24,9 @@
def __init__(self, name=None, commands=None, **attrs):
self.option_notes = attrs.pop('option_notes', None)
+ self.aliases = {}
super().__init__(name, commands, **attrs)
- @property
- def aliases(self):
- if not hasattr(self, '_aliases'):
- self._aliases = {}
- return self._aliases
-
def get_command(self, ctx, cmd_name):
return super().get_command(ctx, self.aliases.get(cmd_name, cmd_name))
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Dec 20 2024, 11:34 AM (11 w, 4 d ago)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
3222946
Attached To
D2328: Make cli aliases a plain dict
Event Timeline
Log In to Comment