mirror of
https://github.com/ynput/ayon-core.git
synced 2025-12-25 21:32:15 +01:00
Added possibility to skip version collecting
Useful for headless publishing via webpublisher. Currently applicable only for Photoshop studio processing.
This commit is contained in:
parent
d6be6b0182
commit
676dce041a
1 changed files with 14 additions and 0 deletions
|
|
@ -11,6 +11,7 @@ class CollectSceneVersion(pyblish.api.ContextPlugin):
|
|||
|
||||
order = pyblish.api.CollectorOrder
|
||||
label = 'Collect Scene Version'
|
||||
# configurable in Settings
|
||||
hosts = [
|
||||
"aftereffects",
|
||||
"blender",
|
||||
|
|
@ -26,7 +27,20 @@ class CollectSceneVersion(pyblish.api.ContextPlugin):
|
|||
"tvpaint"
|
||||
]
|
||||
|
||||
# in some cases of headless publishing (for example webpublisher using PS)
|
||||
# you want to ignore version from name and let integrate use next version
|
||||
skip_hosts_headless_publish = [
|
||||
|
||||
]
|
||||
|
||||
def process(self, context):
|
||||
# tests should be close to regular publish as possible
|
||||
if (context.data["hostName"] in self.skip_hosts_headless_publish
|
||||
and os.environ.get("HEADLESS_PUBLISH")
|
||||
and not os.environ.get("IS_TEST")):
|
||||
self.log.debug("Skipping for headless publishing")
|
||||
return
|
||||
|
||||
assert context.data.get('currentFile'), "Cannot get current file"
|
||||
filename = os.path.basename(context.data.get('currentFile'))
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue