Changesets: Import 2017-06-07 23:51:09
master 456baac3 2014-03-12 14:42:26 mwoehlke Details Diff |
STYLE: Move wrapping width to formatter Move the variable holding the text wrap width from a global in SlicerWizard/Utilities.py to a member of the log formatter class, now that it is only used from there, and not from a freestanding function. git-svn-id: http://svn.slicer.org/Slicer4/trunk@22967 3bd1e089-480b-0410-8dfb-8563597acbee |
||
mod - Utilities/Scripts/SlicerWizard/Utilities.py | Diff File | ||
master 9b01f80e 2014-03-12 14:42:25 mwoehlke Details Diff |
STYLE: Move exception logging to die() Change die() in SlicerWizard/Utilities.py to log the current exception, if there is one, and --debug has been given. This allows us to remove the code to re-raise the exception (in order to produce the traceback) any time we would otherwise call die() after catching an exception. git-svn-id: http://svn.slicer.org/Slicer4/trunk@22966 3bd1e089-480b-0410-8dfb-8563597acbee |
||
mod - Utilities/Scripts/SlicerWizard/SlicerWizard.py | Diff File | ||
mod - Utilities/Scripts/SlicerWizard/Utilities.py | Diff File | ||
master 9a80fea2 2014-03-12 14:42:24 mwoehlke Details Diff |
ENH: Refactor SlicerWizard logging Convert SlicerWizard reporting to use Python's built-in logging facility, and add additional debug messages (newly controlled by the --debug option). This gives us additional features and better control over logging, e.g. we now implicitly use logging levels, with WARNING and higher going to stderr, and INFO/DEBUG going to stdout, as well as applying text wrapping to everything. git-svn-id: http://svn.slicer.org/Slicer4/trunk@22965 3bd1e089-480b-0410-8dfb-8563597acbee |
||
mod - Utilities/Scripts/SlicerWizard/SlicerWizard.py | Diff File | ||
mod - Utilities/Scripts/SlicerWizard/TemplateManager.py | Diff File | ||
mod - Utilities/Scripts/SlicerWizard/Utilities.py | Diff File | ||
master 44952fd0 2014-03-12 14:42:23 mwoehlke Details Diff |
BUG: Include target in submit branch name Include the target branch in the extension index branch created to submit an extension. This is required to concurrently submit to multiple target branches (which would otherwise be impossible due to branch name collision). git-svn-id: http://svn.slicer.org/Slicer4/trunk@22964 3bd1e089-480b-0410-8dfb-8563597acbee |
||
mod - Utilities/Scripts/SlicerWizard/SlicerWizard.py | Diff File | ||
master 0dbf18a2 2014-03-12 14:42:22 mwoehlke Details Diff |
ENH: Update user's fork when submitting extension When submitting an extension, also push the current upstream branch to the user's fork, so that the branch does not seem to include extraneous history due to the target branch on the user's fork being behind upstream. git-svn-id: http://svn.slicer.org/Slicer4/trunk@22963 3bd1e089-480b-0410-8dfb-8563597acbee |
||
mod - Utilities/Scripts/SlicerWizard/SlicerWizard.py | Diff File | ||
master 97990e24 2014-03-12 14:42:21 mwoehlke Details Diff |
BUG: Avoid trailing whitespace in description file Change ExtensionDescription.py to strip whitespace from output lines when writing the description file, in order to avoid writing trailing space in case a value is not set. git-svn-id: http://svn.slicer.org/Slicer4/trunk@22962 3bd1e089-480b-0410-8dfb-8563597acbee |
||
mod - Utilities/Scripts/SlicerWizard/ExtensionDescription.py | Diff File | ||
master b9c480ab 2014-03-12 14:42:19 mwoehlke Details Diff |
ENH: Add 'submit extension' to SlicerWizard.py Add a utility to manipulate slicer extension description files, which can read an existing description file or create a description from an extension git repository, and also write a description file (without comments). Add helpers to get a named repository from github, or a user's fork of a github repository. Add a git helper to find or create a remote matching a specified fetch url. Modify git 'get repository' helper to take a callable as the 'create' parameter in order to allow enforcing that a newly-created repository is created in an empty (or previously non-existing) directory. Use all of the above to start implementing a 'submit extension' command, which takes an extension repository and creates a pull request to add the extension to the extensions index. So far this does everything but create the actual pull request (i.e. handles the user's fork of the index repository, and creating and pushing the commit against the index repository to add or update the extension). git-svn-id: http://svn.slicer.org/Slicer4/trunk@22961 3bd1e089-480b-0410-8dfb-8563597acbee |
||
add - Utilities/Scripts/SlicerWizard/ExtensionDescription.py | Diff File | ||
mod - Utilities/Scripts/SlicerWizard/GithubHelper.py | Diff File | ||
mod - Utilities/Scripts/SlicerWizard/SlicerWizard.py | Diff File | ||
mod - Utilities/Scripts/SlicerWizard/Utilities.py | Diff File | ||
master 8125a3bf 2014-03-12 14:42:18 mwoehlke Details Diff |
ENH: Add wrapped output to SlicerWizard.py Add a 'printw' helper function to print wrapped text. Use this in die() and one other appropriate spot. git-svn-id: http://svn.slicer.org/Slicer4/trunk@22960 3bd1e089-480b-0410-8dfb-8563597acbee |
||
mod - Utilities/Scripts/SlicerWizard/SlicerWizard.py | Diff File | ||
mod - Utilities/Scripts/SlicerWizard/Utilities.py | Diff File | ||
master f87b8240 2014-03-12 14:42:17 mwoehlke Details Diff |
BUG: Don't catch die() in SlicerWizard.py Separately catch SystemExit and re-raise, so that calls to die() from within a try-except don't print strange error messages. git-svn-id: http://svn.slicer.org/Slicer4/trunk@22959 3bd1e089-480b-0410-8dfb-8563597acbee |
||
mod - Utilities/Scripts/SlicerWizard/SlicerWizard.py | Diff File | ||
master 3332f455 2014-03-12 14:42:16 mwoehlke Details Diff |
ENH: Add debug option to SlicerWizard.py Add an undocumented --debug option to SlicerWizard.py. When used, exceptions are re-raised when caught, rather than showing a fatal error with just the exception message. This is useful for development to get the stack trace in case of unexpected exceptions due to incorrect code. git-svn-id: http://svn.slicer.org/Slicer4/trunk@22958 3bd1e089-480b-0410-8dfb-8563597acbee |
||
mod - Utilities/Scripts/SlicerWizard/SlicerWizard.py | Diff File | ||
master 1d14965b 2014-03-12 14:42:15 mwoehlke Details Diff |
ENH: Add publishExtension to SlicerWizard Add a new 'command' to SlicerWizard to publish (to github) an extension. This creates a git repository for the extension (if one does not already exist), creates a github repository for the extension, changes the extension meta-information to reference the github repository, commits said changes (or makes an initial commit with the contents of the extension tree), adds the github repository as a remote, and pushes to github. git-svn-id: http://svn.slicer.org/Slicer4/trunk@22957 3bd1e089-480b-0410-8dfb-8563597acbee |
||
mod - Utilities/Scripts/SlicerWizard/ExtensionProject.py | Diff File | ||
add - Utilities/Scripts/SlicerWizard/GithubHelper.py | Diff File | ||
mod - Utilities/Scripts/SlicerWizard/SlicerWizard.py | Diff File | ||
mod - Utilities/Scripts/SlicerWizard/Utilities.py | Diff File | ||
master 13dcc18d 2014-03-12 14:42:14 mwoehlke Details Diff |
ENH: Create CMake parser for SlicerWizard Create a Python implementation of a CMake script parser (of sorts). This is believed to parse most well-formed CMake script (including CMake 3.0 long brackets for strings and comments), and turns the script into a parse tree that is well suited to editing and capable of reconstructing the exact input document without reformatting. Use this, instead of regular expressions, to perform the CMakeLists.txt manipulation when adding a module to an extension. In the long run, this will make it much easier to reliably manipulate CMake scripts. git-svn-id: http://svn.slicer.org/Slicer4/trunk@22956 3bd1e089-480b-0410-8dfb-8563597acbee |
||
add - Utilities/Scripts/SlicerWizard/CMakeParser.py | Diff File | ||
mod - Utilities/Scripts/SlicerWizard/ExtensionProject.py | Diff File | ||
master 9ab3dc96 2014-03-12 14:42:13 mwoehlke Details Diff |
STYLE: Change error reporting in SlicerWizard Create a new utility module for generic helper functions. Create and use a new die() function to terminate the script with an error message, rather than calling exit() all over the place. git-svn-id: http://svn.slicer.org/Slicer4/trunk@22955 3bd1e089-480b-0410-8dfb-8563597acbee |
||
mod - Utilities/Scripts/SlicerWizard/SlicerWizard.py | Diff File | ||
mod - Utilities/Scripts/SlicerWizard/TemplateManager.py | Diff File | ||
add - Utilities/Scripts/SlicerWizard/Utilities.py | Diff File | ||
master 1cf54984 2014-03-12 14:42:12 mwoehlke Details Diff |
ENH: Add option to list templates to SlicerWizard git-svn-id: http://svn.slicer.org/Slicer4/trunk@22954 3bd1e089-480b-0410-8dfb-8563597acbee |
||
mod - Utilities/Scripts/SlicerWizard/SlicerWizard.py | Diff File | ||
mod - Utilities/Scripts/SlicerWizard/TemplateManager.py | Diff File | ||
master 1312a82e 2014-03-12 14:42:11 mwoehlke Details Diff |
STYLE: Fix indentation in SlicerWizard.py git-svn-id: http://svn.slicer.org/Slicer4/trunk@22953 3bd1e089-480b-0410-8dfb-8563597acbee |
||
mod - Utilities/Scripts/SlicerWizard/SlicerWizard.py | Diff File | ||
master b1400af0 2014-03-12 14:42:09 mwoehlke Details Diff |
STYLE: Improve SlicerWizard.py help Use action.metavar to simplify our usage customization (some is still needed to avoid breaking the word splitting). Mention TYPE in --createExtension usage. Show usage when no action was requested. git-svn-id: http://svn.slicer.org/Slicer4/trunk@22952 3bd1e089-480b-0410-8dfb-8563597acbee |
||
mod - Utilities/Scripts/SlicerWizard/SlicerWizard.py | Diff File | ||
master c79a27dd 2014-03-12 14:42:08 mwoehlke Details Diff |
STYLE: More refactoring of SlicerWizard Also move manipulation of extension CMakeLists.txt to its own Python module, and adjust code style to prefer raising exceptions in modules rather than calling exit(). (We still do call exit(), but it is moved to higher up the stack where we now catch the newly raised exceptions.) git-svn-id: http://svn.slicer.org/Slicer4/trunk@22951 3bd1e089-480b-0410-8dfb-8563597acbee |
||
add - Utilities/Scripts/SlicerWizard/ExtensionProject.py | Diff File | ||
mod - Utilities/Scripts/SlicerWizard/SlicerWizard.py | Diff File | ||
mod - Utilities/Scripts/SlicerWizard/TemplateManager.py | Diff File | ||
master 4ef5d939 2014-03-12 14:42:07 mwoehlke Details Diff |
STYLE: Refactor SlicerWizard into Python modules Replace Scripts/SlicerWizard.py with a very short script that merely imports the main wizard class, intantiates it, and calls its execute() method. Move the code into two new Python module files in a subdirectory. This will allow for better scaling as we add features, by allowing us to create additional modules as it makes sense, rather than needing to encapsulate everything in a single monolithic script file. git-svn-id: http://svn.slicer.org/Slicer4/trunk@22950 3bd1e089-480b-0410-8dfb-8563597acbee |
||
mod - Utilities/Scripts/SlicerWizard.py | Diff File | ||
add - Utilities/Scripts/SlicerWizard/SlicerWizard.py | Diff File | ||
add - Utilities/Scripts/SlicerWizard/TemplateManager.py | Diff File | ||
add - Utilities/Scripts/SlicerWizard/__init__.py | Diff File | ||
master 4eaea797 2014-03-12 14:42:06 mwoehlke Details Diff |
ENH: Add user templates to SlicerWizard.py Add support for user-specified template directories and keys to SlicerWizard.py. This allows users to provide their own templates in addition to the "built in" templates. git-svn-id: http://svn.slicer.org/Slicer4/trunk@22949 3bd1e089-480b-0410-8dfb-8563597acbee |
||
mod - Utilities/Scripts/SlicerWizard.py | Diff File | ||
master a6ec49bf 2014-03-12 14:42:05 mwoehlke Details Diff |
BUG: Fix argparse assert wrapping arguments Tweak WizardHelpFormatter in SlicerWizard.py to temporarily replace '[]'s in option value strings during formatting in order to avoid argparse splitting these and tripping an assert in its internals. git-svn-id: http://svn.slicer.org/Slicer4/trunk@22948 3bd1e089-480b-0410-8dfb-8563597acbee |
||
mod - Utilities/Scripts/SlicerWizard.py | Diff File | ||
master b8a2810d 2014-03-12 14:42:04 mwoehlke Details Diff |
ENH: Create new templates for wizard Refactor the ModuleWizard.py templates for use by the new SlicerWizard.py. The main changes are that the module templates no longer have extension templates wrapped around them (and the extension templates no longer contain modules), the directory organization has been improved, and the placeholders are all now TemplateKey. This last change in particular was to allow the SuperBuild template to be named "SuperBuild" (which is easy for users to type and logical given the new organization), and still contain files named like "SuperBuild" that should not be renamed. git-svn-id: http://svn.slicer.org/Slicer4/trunk@22947 3bd1e089-480b-0410-8dfb-8563597acbee |
||
add - Utilities/Templates/Extensions/Default/CMakeLists.txt | Diff File | ||
add - Utilities/Templates/Extensions/Default/TemplateKey.png | Diff File | ||
add - Utilities/Templates/Extensions/SuperBuild/CMakeLists.txt | Diff File | ||
add - Utilities/Templates/Extensions/SuperBuild/CTestConfig.cmake | Diff File | ||
add - Utilities/Templates/Extensions/SuperBuild/SuperBuild.cmake | Diff File | ||
add - Utilities/Templates/Extensions/SuperBuild/SuperBuild/External_Foo.cmake | Diff File | ||
add - Utilities/Templates/Modules/CLI/CMakeLists.txt | Diff File | ||
add - Utilities/Templates/Modules/CLI/Data/Baseline/TemplateKeyTest.nhdr.md5 | Diff File | ||
add - Utilities/Templates/Modules/CLI/Data/Baseline/TemplateKeyTest.raw.md5 | Diff File | ||
add - Utilities/Templates/Modules/CLI/Data/Input/CTHeadAxial.nhdr.md5 | Diff File | ||
add - Utilities/Templates/Modules/CLI/Data/Input/CTHeadAxial.raw.gz.md5 | Diff File | ||
add - Utilities/Templates/Modules/CLI/TemplateKey.cxx | Diff File | ||
add - Utilities/Templates/Modules/CLI/TemplateKey.xml | Diff File | ||
add - Utilities/Templates/Modules/CLI/Testing/CMakeLists.txt | Diff File | ||
add - Utilities/Templates/Modules/CLI/Testing/Cxx/CMakeLists.txt | Diff File | ||
add - Utilities/Templates/Modules/CLI/Testing/Cxx/TemplateKeyTest.cxx | Diff File | ||
add - Utilities/Templates/Modules/Loadable/CMakeLists.txt | Diff File | ||
add - Utilities/Templates/Modules/Loadable/Logic/CMakeLists.txt | Diff File | ||
add - Utilities/Templates/Modules/Loadable/Logic/vtkSlicerTemplateKeyLogic.cxx | Diff File | ||
add - Utilities/Templates/Modules/Loadable/Logic/vtkSlicerTemplateKeyLogic.h | Diff File | ||
add - Utilities/Templates/Modules/Loadable/Resources/Icons/TemplateKey.png | Diff File | ||
add - Utilities/Templates/Modules/Loadable/Resources/UI/qSlicerTemplateKeyFooBarWidget.ui | Diff File | ||
add - Utilities/Templates/Modules/Loadable/Resources/UI/qSlicerTemplateKeyModuleWidget.ui | Diff File | ||
add - Utilities/Templates/Modules/Loadable/Resources/qSlicerTemplateKeyModule.qrc | Diff File | ||
add - Utilities/Templates/Modules/Loadable/Testing/CMakeLists.txt | Diff File | ||
add - Utilities/Templates/Modules/Loadable/Testing/Cxx/CMakeLists.txt | Diff File | ||
add - Utilities/Templates/Modules/Loadable/Widgets/CMakeLists.txt | Diff File | ||
add - Utilities/Templates/Modules/Loadable/Widgets/qSlicerTemplateKeyFooBarWidget.cxx | Diff File | ||
add - Utilities/Templates/Modules/Loadable/Widgets/qSlicerTemplateKeyFooBarWidget.h | Diff File | ||
add - Utilities/Templates/Modules/Loadable/qSlicerTemplateKeyModule.cxx | Diff File | ||
add - Utilities/Templates/Modules/Loadable/qSlicerTemplateKeyModule.h | Diff File | ||
add - Utilities/Templates/Modules/Loadable/qSlicerTemplateKeyModuleWidget.cxx | Diff File | ||
add - Utilities/Templates/Modules/Loadable/qSlicerTemplateKeyModuleWidget.h | Diff File | ||
add - Utilities/Templates/Modules/Scripted/CMakeLists.txt | Diff File | ||
add - Utilities/Templates/Modules/Scripted/Resources/Icons/TemplateKey.png | Diff File | ||
add - Utilities/Templates/Modules/Scripted/TemplateKey.py | Diff File | ||
add - Utilities/Templates/Modules/Scripted/Testing/CMakeLists.txt | Diff File | ||
add - Utilities/Templates/Modules/Scripted/Testing/Python/CMakeLists.txt | Diff File | ||
master 0bb127a8 2014-03-12 14:42:02 mwoehlke Details Diff |
ENH: Create new slicer "wizard" tool Create new SlicerWizard.py tool, more or less based on the existing ModuleWizard.py, with improvements. This one separates the concepts of extensions and modules, and allows creating an extension containing several modules, as well as adding modules to an existing extension. The mechanism for specifying templates is also changed; we now take named templates which are searched for in a well-known location relative to the script. (In the future it is expected that users will be able to add additional template directories, however this has not been implemented yet.) Eventually it is hoped that this tool will add other actions, e.g. publishing extensions. git-svn-id: http://svn.slicer.org/Slicer4/trunk@22946 3bd1e089-480b-0410-8dfb-8563597acbee |
||
add - Utilities/Scripts/SlicerWizard.py | Diff File | ||
master 3d6cc2d7 2014-03-12 14:42:01 mwoehlke Details Diff |
STYLE: Fix spelling error in s4ext template git-svn-id: http://svn.slicer.org/Slicer4/trunk@22945 3bd1e089-480b-0410-8dfb-8563597acbee |
||
mod - Extensions/CMake/SlicerFunctionGenerateExtensionDescription.cmake | Diff File | ||
master 5646a4f4 2014-03-11 15:52:21 Details Diff |
BUG: Update OtsuThresholdImageFilter test baseline Following transition to ITKv4, the test started to fail because of the minor different in the output. See [1] This commit simply replaced the existing baseline with the current output of the test. [1] http://massmail.spl.harvard.edu/public-archives/slicer-devel/2013/011716.html git-svn-id: http://svn.slicer.org/Slicer4/trunk@22944 3bd1e089-480b-0410-8dfb-8563597acbee |
||
mod - Modules/CLI/OtsuThresholdImageFilter/Data/Baseline/OtsuThresholdImageFilterTest.raw.gz | Diff File | ||
master fccc2801 2014-03-11 15:52:20 Details Diff |
COMP: Gracefully fail if Slicer build against an external non-system python This commit relaxes the check initially introduced by commit r21191 Note that ideally the build system should be updated to install python libraries and module even if they are not built into the usual directory <Slicer-Superbuild>/python-install git-svn-id: http://svn.slicer.org/Slicer4/trunk@22943 3bd1e089-480b-0410-8dfb-8563597acbee |
||
mod - CMake/SlicerBlockInstallPython.cmake | Diff File |