OMERO and Git
Posted:
Thu Jul 21, 2011 12:45 pm
by icaoberg
I cloned omero using git
- Code: Select all
git clone git://git.openmicroscopy.org/ome.git
There is single branch and multiple tags that reference different versions, including 4.2.1 which is the one I want to edit.
The two tags are
- Code: Select all
v.4.2.1-insight
v.4.2.1-omero
How do I make sure that whatever commit I do only affects v.4.2.1-omero? Should I create a second branch and edit it?
The problem is that if I create a second branch and remove the top nodes until I reach the desired commit/tag, if I create a patch between the two branches the patch will add everything until 4.3.1.
Re: OMERO and Git
Posted:
Thu Jul 21, 2011 1:15 pm
by jmoore
After you clone, you will have one branch named "master". From that point, you want to create a new branch based on our v.4.2.1-omero tag:
- Code: Select all
git checkout -b dev_4_2_1_pslid v.4.2.1-omero
If you run "git branch" you'll see "dev_4_2_1_pslid" now. Any commits you make like:
- Code: Select all
git commit -m "Falcon DB" lib/falcon
will be on the branch. You can see how far you've "diverged" from v.4.2.1-omero via:
- Code: Select all
git show-branch v.4.2.1-omero dev_4_2_1_pslid
To send us your patches, use:
- Code: Select all
git format-patch v.4.2.1-omero..dev_4_2_1_pslid
with whatever options you'd like.
Cheers,
~Josh.
Re: OMERO and Git
Posted:
Mon Jul 25, 2011 5:56 pm
by icaoberg
We originally downloaded and installed omero.server we didn't use the git branch. Now I need to commit my changes within the branch.
We added files to
- Code: Select all
$OMERO_HOME/lib/python
where should I add these files in the git branch?
Re: OMERO and Git
Posted:
Mon Jul 25, 2011 6:17 pm
by jmoore
You can initially put them somewhere under OmeroPy/src, but we may want to eventually create a separate "searcher" component.
Cheers,
~Josh.
Re: OMERO and Git
Posted:
Mon Jul 25, 2011 8:57 pm
by icaoberg
We also modified the file extensions.jar which resides in
- Code: Select all
$OMERO_HOME/lib/server
where should this file be located within the branch?
Re: OMERO and Git
Posted:
Tue Jul 26, 2011 7:10 am
by jmoore
It's not a jar in the source code, but is the one location where external classes can be put by third parties. However, in your case, we want to see the code, so it's probably best to add the files elsewhere. If it's all search based, you might want to add a package under server/src, but again, eventually, we'll want to create a "searcher" component which can contain both the Java and the Python source.
Cheers,
~Josh
Re: OMERO and Git
Posted:
Tue Jul 26, 2011 6:53 pm
by icaoberg
- Code: Select all
/usr0/local/omepslid/ome/components/server/src
bash-3.2$ ls
ome
bash-3.2$ cd ome
bash-3.2$ ls
api formats logic security services tools
where within this folder we add the the source?
we were basically trying to do
- Code: Select all
cp -r $SOURCE/server/extensions.jar $DESTINATION/server/extensions.jar
git add $DESTINATION/server/extensions.jar
git commit -m 'Updated extensions.jar' $DESTINATION/server/extensions.jar
where $SOURCE was our omero.server and $DESTINATION was a clean download of omero,server. The file structure within git is different, so we need to ask about the destination of most of our code.
Re: OMERO and Git
Posted:
Wed Jul 27, 2011 6:36 am
by jmoore
Hi Ivan,
Have you seen
OmeroBuild yet? Most importantly is the layout of source code like:
- Code: Select all
\components
|
|
|--<component-name> ................... Each component has this same basic structure.
| |-- build.xml Main scripts
| |-- ivy.xml Jar dependencies
| |-- src Source code
| |-- resources Other files of interest
| |-- test Test source code and test resources
| \-- target Output of build (deleted on clean)
My goal would be to have all your source code (the .java files, not the .jars) either:
- in the source and resources directories of an existing component. "server" is probably ok, but if you run into any issues you can put it in "blitz".
- in a new component like "tools/OmeroSearcher"
In the long run, I think we will want all of this in its own component, but in order to get things in more quickly, I can understand if you'd prefer to wait on that.
Cheers,
~Josh
Re: OMERO and Git
Posted:
Thu Jul 28, 2011 6:04 pm
by bhcho
Hi Josh,
we also have some python codes and a text file, which are called from both the bridge and OMERO.web page.
Thus we were assumiing those files are located in a specific folder (e.g., OMERO_HOME/lib/python/ ).
In this case, where do we need to copy those files?
best,
BK
Re: OMERO and Git
Posted:
Thu Jul 28, 2011 6:45 pm
by jmoore
Hi BK,
as
above, the python files should go into the OmeroPy/src directory. I'm not sure what your text file contains, but it will most likely need to go into one of the resources/ directories, like server/resources. What's the file ending?
~Josh.