ScriptFu: move test plugins and install more in unstable build

Move test plugins from /scripts to /scripts/test.
POTFILES.skip that directory.

Add a readme to scripts dir.

Revise readme in scripts/test

Rename test9.scm which tests the new byte type support in Scheme.
Install it in unstable build, it is an important test,
long and sophisticated.

Install contactsheet.scm as a test plugin in unstable build.
See test/meson.build for comments about its issue.
This commit is contained in:
bootchk 2024-04-23 13:47:13 -04:00 committed by Lloyd Konneker
parent deb4dc8190
commit 60a584f91a
9 changed files with 79 additions and 14 deletions

View file

@ -0,0 +1,30 @@
The files in this directory are:
- production plugins
- demo plugins
- initialization scripts for ScriptFu
Don't put test plugins in this directory, but in subdirectory test.
Production plugins:
- installed in a release.
- appear in diverse menus, not just Filters.
- should be marked for translation, and not in potfiles.skip
Demo plugins:
- installed in a release (with goat exercise plugins)
- appear in Filters>Development>Demos
- FUTURE: marked for translation, and not in potfiles.skip
Initialization scripts
- loaded by the TinyScheme interpreter
- have suffix .init or .scm
- are not plugins
FUTURE:
The initialization scripts should all should have suffix .scm
(like the rest of the Scheme world.)
They should be in a separate directory
so advanced users can load library scripts.
The files script-fu-util.scm and script-fu-util-setpt.scm
are also initialization scripts but loaded differently from .init files.
FUTURE: unify loading of initialization scripts.

View file

@ -1,4 +1,5 @@
subdir('images') subdir('images')
subdir('test')
# scripts interpreted by extension-script-fu, installed to /scripts # scripts interpreted by extension-script-fu, installed to /scripts
scripts = [ scripts = [
@ -48,15 +49,6 @@ scripts = [
'xach-effect.scm', 'xach-effect.scm',
] ]
if not stable
scripts += [
'contactsheet.scm',
'clothify-v3.scm',
'test-sphere.scm',
'test-v3.scm',
]
endif
install_data( install_data(
scripts, scripts,
install_dir: gimpdatadir / 'scripts', install_dir: gimpdatadir / 'scripts',

View file

@ -333,4 +333,7 @@
SF-COLOR _"Background color" "black" SF-COLOR _"Background color" "black"
) )
(script-fu-menu-register "script-fu-contactsheet" "<Image>/Filters/Combine") ; Originally installed w release in "<Image>/Filters/Combine"
; Now installed in unstable as a test plugin because
; it has an open issue: dirstream fails on Windows.
(script-fu-menu-register "script-fu-contactsheet" "<Image>/Filters/Development/Demos")

View file

@ -0,0 +1,42 @@
# test plugins
# Some, but not all, plugins in this directory are installed in unstable build.
# None should be installed in a release.
# None should be translated: not marked or marked but in potfiles.skip.
# scripts interpreted by extension-script-fu, installed to /scripts
if not stable
scripts = [
'contactsheet.scm',
'clothify-v3.scm',
'test-sphere.scm',
'test-v3.scm',
]
endif
install_data(
scripts,
install_dir: gimpdatadir / 'scripts',
)
# scripts interpreted by gimp-script-fu-interpreter
# Each installed in subdirectory of /plug-in
# Each have a shebang and executable permission.
# Like other interpreted plugins.
# Lacking a shebang, a .interp file is needed to associate .scm suffix
if not stable
scripts_independent = [
{ 'name': 'test-bytes' },
]
endif
foreach plugin : scripts_independent
name = plugin.get('name')
srcs = plugin.get('srcs', name + '.scm')
install_data(srcs,
install_dir: gimpplugindir / 'plug-ins' / name,
install_mode: 'rwxr-xr-x')
endforeach

View file

@ -584,4 +584,4 @@
SF-STRING "Test name (optional)" "" SF-STRING "Test name (optional)" ""
) )
(script-fu-menu-register "script-fu-test9" "<Image>/Test") (script-fu-menu-register "script-fu-test9" "<Image>/Filters/Development/Demos")

View file

@ -50,9 +50,7 @@ plug-ins/print
plug-ins/python plug-ins/python
plug-ins/screenshot plug-ins/screenshot
plug-ins/script-fu/script-fu-refresh.c plug-ins/script-fu/script-fu-refresh.c
plug-ins/script-fu/scripts/contactsheet.scm plug-ins/script-fu/scripts/test
plug-ins/script-fu/scripts/clothify-v3.scm
plug-ins/script-fu/scripts/test-v3.scm
plug-ins/selection-to-path plug-ins/selection-to-path
plug-ins/twain plug-ins/twain
plug-ins/ui plug-ins/ui