Skip to content

I2PC/scipion-afm

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Scipion template plugin

This is a template plugin for scipion

Steps to adapt this plugin

IMPORTANT: To simplify the instructions all the commands would refer to an hypothetical new plugin name called "coolem". Note that you must replace "coolem" by your plugin name.

Clone it:

git clone https://github.com/scipion-em/scipion-em-template.git scipion-em-coolem

Reset the git repo

cd scipion-em-coolem
rm -rf .git
git init

Empty CHANGES.txt

rm CHANGES.txt && touch CHANGES.txt

Rename "myplugin" to coolem

mv myplugin coolem

Tidy up imports

IDE refactorization should rename at once the classes and the imports. Search in your IDE for "myplugin" and replace by "coolem"
  • coolem/protocols/protocol_hello_world.py:
class MyPluginPrefixHelloWorld --> class CoolemPrefixHelloWorld
  • coolem/protocol/__init__.py:
from .protocol_hello_world import MyPluginPrefixHelloWorld --> from .protocol_hello_world import CoolemPrefixHelloWorld
  • coolem/wizards/wizard_hello_world.py:
_targets = [(MyPluginPrefixHelloWorld, ['message'])] --> _targets = [(CoolemPrefixHelloWorld, ['message'])] class MyPluginPrefixHelloWorldWizard --> class CoolemPrefixHelloWorldWizard
  • coolem/wizards/__init__.py:
from .wizard_hello_world import MyPluginPrefixHelloWorldWizard --> from .wizard_hello_world import CoolemPrefixHelloWorldWizard
  • protocols.conf: rename MyPluginPrefixHelloWorld --> CoolemPrefixHelloWorld
  • setup.py: Update almost all values: name, description, ... Be sure to update package data
  package_data={  # Optional
     'coolem': ['icon.png', 'protocols.conf'],
  }

and the entry point
entry_points={
    'pyworkflow.plugin': 'coolem = coolem'
}

Install the plugin in devel mode

scipion3 installp -p /home/me/scipion-em-coolem --devel

If installation fails, you can access pip options like:

scipion3 python -m pip ... (list, install, uninstall)

Customize it

Replace icon.png with your logo and update the bibtex.py with your reference.

Get rid of this content and keep the readme informative

Repository

To create the repository, following those guide depending the platform:

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages