Editing Geometry package:GSoC17
Jump to navigation
Jump to search
The edit can be undone. Please check the comparison below to verify that this is what you want to do, and then publish the changes below to finish undoing the edit.
Latest revision | Your text | ||
Line 61: | Line 61: | ||
===Syncing matGeom and geometry=== | ===Syncing matGeom and geometry=== | ||
The goal is to devise a somewhat automated way to ensure that the functions which are there in geometry are synced with those in matGeom without manually checking the edits. | The goal is to devise a somewhat automated way to ensure that the functions which are there in geometry are synced with those in matGeom without manually checking the edits. | ||
To achieve this, first a workaround is implemented on a dummy repository [https://github.com/piyush-jain1/dummyMatGeom/ dummyMatGeom]. Its master branch is matGeom (dummy) and there is another branch (named geometry) is created which contains geometry package (dummy). Lets assume that local directory of matGeom is named as dummyMatGeom and local directory of geometry is dummyGeom. Then, follow these steps : | |||
To achieve this, first a workaround is implemented on a dummy repository [https://github.com/piyush-jain1/dummyMatGeom/ dummyMatGeom]. Its master branch is matGeom (dummy) and there is another branch (named geometry) is created which contains geometry package (dummy). | 1. go to the local dummyMatGeom directory and pull upstream (dummy matGeom) using these commands : | ||
Then follow | |||
1. go to the local dummyMatGeom directory | |||
- git fetch origin master | - git fetch origin master | ||
- git reset --hard FETCH_HEAD | - git reset --hard FETCH_HEAD | ||
Line 74: | Line 70: | ||
2. run the following octave command. | 2. run the following octave command. | ||
- rmdir("dummyGeom/deprecated","s"); | - rmdir("dummyGeom/deprecated","s"); | ||
- | - movefile("dummyMatGeom/matGeom/deprecated","dummyGeom/"); | ||
- | - movefile("dummyMatGeom/matGeom", "dummyGeom/"); | ||
- rmdir("dummyGeom/inst","s"); | - rmdir("dummyGeom/inst","s"); | ||
- rename("dummyGeom/matGeom","dummyGeom/inst"); | - rename("dummyGeom/matGeom","dummyGeom/inst"); | ||
Line 86: | Line 82: | ||
This will sync the scripts which were already present in the geometry branch with those of the matGeom branch without disturbing other scripts. | This will sync the scripts which were already present in the geometry branch with those of the matGeom branch without disturbing other scripts. | ||
4. Now, update your local geometry repo by | 4. Now, update your local geometry repo by force pulling from the remote branch. | ||
- git | - git pull -f origin master:geometry | ||
* '''Challenges : ''' | * '''Challenges : ''' | ||
Clearly, the above procedure will only sync the script of the function, not it's tests and demo, which are in separate folders in a Matlab package structure. Even if we try to concatenate their corresponding test/demo scripts with the function scripts (as it is in an octave package structure), there will be discrepancies because the notion or writing tests for octave and matlab packages are quite different. The way octave allows tests to work is unique to octave as explained [http://wiki.octave.org/FAQ#What_features_are_unique_to_Octave.3F here]. SO, we can't simply concatenate the Matlab test scripts with the functions. | Clearly, the above procedure will only sync the script of the function, not it's tests and demo, which are in separate folders in a Matlab package structure. Even if we try to concatenate their corresponding test/demo scripts with the function scripts (as it is in an octave package structure), there will be discrepancies because the notion or writing tests for octave and matlab packages are quite different. The way octave allows tests to work is unique to octave as explained [http://wiki.octave.org/FAQ#What_features_are_unique_to_Octave.3F here]. SO, we can't simply concatenate the Matlab test scripts with the functions. | ||
=== Discoveries === | === Discoveries === |