Skip to content

Commit 88a19b8

Browse files
Update CONTRIBUTING.md to reflect new style
1 parent e13a9bc commit 88a19b8

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

CONTRIBUTING.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -142,7 +142,7 @@ Tool implementations are defined in classes in the `usethis._tool.impl` module.
142142
- Start by implementing its `name` property method, then work through the other methods. Most method have default implementations, but even in those cases you will need to consider them individually and determine an appropriate implementation. For example, methods which specify the tool's dependencies default to empty dependencies, but you shouldn't rely on this.
143143
- Mark all methods in your `ToolSpec` subclass with the `@typing.final` decorator. This prevents the methods from being accidentally overridden in the `Tool` subclass.
144144
- Then, define a subclass of the `ToolSpec` subclass you just created, which also subclasses `usethis._tool.base.Tool`, e.g. for a tool named Xyz, define a class `XyzTool(XyzToolSpec, Tool)`. The only method this usually requires a non-default implementation for is `config_spec` to specify which configuration sections should be set up for the tool (and which sections the tool manages). However, you may find it helpful to provide custom implementations for other methods as well, e.g. `print_how_to_use`.
145-
- Mark all methods in your `Tool` subclass with `@final` as well, to prevent further subclassing from overriding them.
145+
- Mark your `Tool` subclass with `@final` as well, to prevent further subclassing.
146146

147147
#### Register your `Tool` subclass
148148

0 commit comments

Comments
 (0)