-
Notifications
You must be signed in to change notification settings - Fork 1
requires
Nat! edited this page Mar 1, 2023
·
3 revisions
requires will try to locate a NSBundle at print time. If the bundle
identifier matches, then the bundle will get loaded. The idea is to be able to
load available functionality to a standalone script.
{% if __FOUNDATION__ == "Mulle" %}
{% requires "com.mulle-kybernetik.foundation" %}
{% else %}
{% requires "com.apple.Foundation" %}
{% endif %}
Output:
requires searches in the following places:
- first in all already loaded bundles and frameworks
- in the mainBundle builtInPlugInsPath
- it then will search through all Library directories Frameworks and PlugIns directories.
- Turn on the
MULLESCION_DUMP_BUNDLE_SEARCHPATHenvironment variable to see the paths searched.
requires should not be used in multi-line statements.