-
Notifications
You must be signed in to change notification settings - Fork 296
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix issue with duplicate execution of plugins
- Loading branch information
1 parent
8c2dc8c
commit a63e9ef
Showing
3 changed files
with
33 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
import os | ||
from dotbot.plugin import Plugin | ||
from dotbot.plugins import Clean, Create, Link, Shell | ||
|
||
# https://github.com/anishathalye/dotbot/issues/357 | ||
# if we import from dotbot.plugins, the built-in plugins get executed multiple times | ||
|
||
class NoopPlugin(Plugin): | ||
_directive = 'noop' | ||
|
||
def can_handle(self, directive): | ||
return directive == self._directive | ||
|
||
def handle(self, directive, data): | ||
return True |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters