[Smtk-developers] Big rename
David Thompson
david.thompson at kitware.com
Thu Jan 29 21:29:41 EST 2015
Hi all,
I plan to perform a large rename of classes in SMTK tomorrow and want to make sure you have a chance to merge branches before it takes place. Please let me know if you need me to postpone.
The list of renames is
Cursor -> EntityRef
Bridge -> Session (not a Cursor subclass)
BridgeSession -> SessionRef (a Cursor subclass)
GroupEntity -> Group
InstanceEntity -> Instance
ModelEntity -> Model
RemusRemoteBridge -> Session
BridgeIO -> SessionIO
BridgeIOJSON -> SessionIOJSON
BridgeExodusIOJSON -> SessionExodusIOJSON
BridgeRegistrar -> SessionRegistrar
The scripts I will use on SMTK (and adapt to CMBv4) are below.
David
## This is the shell script to rename files and
## run VIM on every SMTK file to capture name changes:
git mv smtk/model/Cursor.h smtk/model/EntityRef.h
git mv smtk/model/Cursor.h smtk/model/EntityRef.cxx
git mv smtk/model/Cursor.cxx smtk/model/EntityRef.cxx
git mv smtk/model/Bridge.h smtk/model/Session.h
git mv smtk/model/Bridge.cxx smtk/model/Session.cxx
git mv smtk/model/BridgeIO.h smtk/model/SessionIO.h
git mv smtk/model/BridgeIO.cxx smtk/model/SessionIO.cxx
git mv smtk/model/BridgeIOJSON.h smtk/model/SessionIOJSON.h
git mv smtk/model/BridgeIOJSON.cxx smtk/model/SessionIOJSON.cxx
git mv smtk/model/BridgeRegistrar.h smtk/model/SessionRegistrar.h
git mv smtk/model/BridgeRegistrar.cxx smtk/model/SessionRegistrar.cxx
git mv smtk/model/BridgeSession.h smtk/model/SessionRef.h
git mv smtk/model/BridgeSession.cxx smtk/model/SessionRef.cxx
git mv smtk/model/ModelEntity.h smtk/model/Model.h
git mv smtk/model/ModelEntity.cxx smtk/model/Model.cxx
git mv smtk/model/GroupEntity.h smtk/model/Group.h
git mv smtk/model/GroupEntity.cxx smtk/model/Group.cxx
git mv smtk/model/InstanceEntity.h smtk/model/Instance.h
git mv smtk/model/InstanceEntity.cxx smtk/model/Instance.cxx
git mv smtk/bridge/remote/RemusRemoteBridge.h smtk/bridge/remote/Bridge.h
git mv smtk/bridge/remote/RemusRemoteBridge.cxx smtk/bridge/remote/Bridge.cxx
git mv CMake/SMTKBridgeJSON.cmake CMake/SMTKSessionJSON.cmake
git mv smtk/bridge/cgm/Bridge.h smtk/bridge/cgm/Session.h
git mv smtk/bridge/cgm/Bridge.cxx smtk/bridge/cgm/Session.cxx
git mv smtk/bridge/cgm/Bridge_json.h smtk/bridge/cgm/Session_json.h
git mv smtk/bridge/cgm/Bridge.json smtk/bridge/cgm/Session.json
git mv smtk/bridge/discrete/Bridge.h smtk/bridge/discrete/Session.h
git mv smtk/bridge/discrete/Bridge.cxx smtk/bridge/discrete/Session.cxx
git mv smtk/bridge/discrete/Bridge.json smtk/bridge/discrete/Session.json
git mv smtk/bridge/discrete/Bridge_json.h smtk/bridge/discrete/Session_json.h
git mv smtk/bridge/exodus/Bridge.h smtk/bridge/exodus/Session.h
git mv smtk/bridge/exodus/Bridge.cxx smtk/bridge/exodus/Session.cxx
git mv smtk/bridge/exodus/Bridge.json smtk/bridge/exodus/Session.json
git mv smtk/bridge/exodus/BridgeExodusIOJSON.h smtk/bridge/exodus/SessionExodusIOJSON.h
git mv smtk/bridge/exodus/BridgeExodusIOJSON.cxx smtk/bridge/exodus/SessionExodusIOJSON.cxx
find doc smtk CMake -type f -exec vim -S /path/to/vscript {} \;
## This is the contents of the "vscript" file that
## performs the renames in VIM using the most excellent
## VIM "abolish" plugin:
## http://www.vim.org/scripts/script.php?script_id=1545
%S+BridgeSession+SessionRef+g
%S+BridgeIOJSON+SessionIOJSON+g
%S+BridgeIO+SessionIO+g
%S+BridgeRegistrar+SessionRegistrar+g
%S+Bridge+Session+g
%S+Cursor+EntityRef+g
%S+GroupEntity+Group+g
%S+InstanceEntity+Instance+g
%S+ModelEntity+Model+g
%S+RemusRemoteBridge+Bridge+g
%S+BridgeExodusIOJSON+SessionExodusIOJSON+g
wq
More information about the Smtk-developers
mailing list