Fixed Flamenco exclusion filter bug
There was a mistake in an older version of the property tooltip, showing semicolon-separated instead of space-separated. We now just handle both.
This commit is contained in:
parent
4fd4ad7448
commit
8899bff5e4
@ -219,8 +219,8 @@ class BlenderCloudPreferences(AddonPreferences):
|
|||||||
flamenco_manager = PointerProperty(type=flamenco.FlamencoManagerGroup)
|
flamenco_manager = PointerProperty(type=flamenco.FlamencoManagerGroup)
|
||||||
flamenco_exclude_filter = StringProperty(
|
flamenco_exclude_filter = StringProperty(
|
||||||
name='File Exclude Filter',
|
name='File Exclude Filter',
|
||||||
description='Filter like "*.abc;*.mkv" to prevent certain files to be packed '
|
description='Space-separated list of filename filters, like "*.abc *.mkv", to prevent '
|
||||||
'into the output directory',
|
'matching files from being packed into the output directory',
|
||||||
default='',
|
default='',
|
||||||
update=project_specific.store,
|
update=project_specific.store,
|
||||||
)
|
)
|
||||||
|
@ -2,9 +2,10 @@
|
|||||||
|
|
||||||
import asyncio
|
import asyncio
|
||||||
import logging
|
import logging
|
||||||
|
import pathlib
|
||||||
|
import re
|
||||||
import threading
|
import threading
|
||||||
import typing
|
import typing
|
||||||
import pathlib
|
|
||||||
|
|
||||||
import bpy
|
import bpy
|
||||||
from blender_asset_tracer import pack
|
from blender_asset_tracer import pack
|
||||||
@ -114,7 +115,11 @@ async def copy(context,
|
|||||||
as packer:
|
as packer:
|
||||||
with _packer_lock:
|
with _packer_lock:
|
||||||
if exclusion_filter:
|
if exclusion_filter:
|
||||||
packer.exclude(*exclusion_filter.split())
|
# There was a mistake in an older version of the property tooltip,
|
||||||
|
# showing semicolon-separated instead of space-separated. We now
|
||||||
|
# just handle both.
|
||||||
|
filter_parts = re.split('[ ;]+', exclusion_filter.strip(' ;'))
|
||||||
|
packer.exclude(*filter_parts)
|
||||||
|
|
||||||
packer.progress_cb = BatProgress()
|
packer.progress_cb = BatProgress()
|
||||||
_running_packer = packer
|
_running_packer = packer
|
||||||
|
Reference in New Issue
Block a user