-
Notifications
You must be signed in to change notification settings - Fork 4
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Set up shared code between molecules-and-light and greenhouse-effect #19
Comments
Here is the issue where we set up the shared code between energy-skate-park and energy-skate-park-basics phetsims/energy-skate-park#6. We decided to create one main repo (energy-skate-park) and a thin shell for basics when was dependent on the main repo. From phetsims/energy-skate-park#6 (comment), I used https://docs.github.com/en/github/creating-cloning-and-archiving-repositories/duplicating-a-repository to duplicate the contents and history of energy-skate-park-basics into energy-skate-park to preserve the history. That worked because energy-skate-park was empty but greenhouse-effect already has sim code and history so we can't put a clone of molecules-and-light at this repo. |
Perennial now has a copy-history-to-different-repo.sh which looks promising. Can use this on a directory or file to move things from molecules-and-light to this repo. |
I am using copy-history-to-different-repo.sh now to move things over, going through each subdirectory then moving things around. Taking some notes as I go through.
|
…ble atmosphere, see issue #19
The contents of molecules-and-light have been moved to greenhouse-effect including assets, images, mipmaps, and sounds and code. Most code from molecules-and-light has been moved under the micro subdirectory, since molecules-and-light will mostly borrow from that screen. I verified that history was preserved by checking history of several files under micro. I expect some things could move out of micro and into common or maybe back into molecules-and-light for some components that aren't used in greenhouse-effect. But since we don't have a mockup for the micro screen yet, I moved everything over eagerly to finish getting the relationship set up. Next, I will start removing things from molecules-and-light and pulling from greenhouse-effect. |
I think this is done. molecules-and-light is now a shell that pulls almost all code from greenhouse-effect. As mentioned in #19 (comment) I suspect that things could be moved back into molecules-and-light if there are components that are specific to that sim. We will do that when we have a mockup for the micro screen. Regarding strings, all strings have been moved into greenhouse-effect except those that are used for the molecules-and-light KeyboardShortcuts Dialog. |
@jbphet I wanted to reassign to you in case you wanted to spot check in case I missed anything. Otherwise I think this can be closed. |
I've reviewed this and made a few minor commits, and I think we're good to go. There will need to be a fair amount of work done on the code in the |
Reopening because there is a TODO marked for this issue. |
I created a new, more specific issue to which to link the TODO in the code and have updated the reference. Re-closing. |
The molecules-and-light sim is a subset of the greenhouse-effect sim, and in other cases that I've worked on where one sim is a subset of another, the more extensive "parent" sim contains all of the code for both. The atomic-interactions sim has this sort of a relationship with states-of-matter, where pretty much all of the code for the sim is in the states-of-matter repo. So, if we want to follow this pattern, most of the code for molecules-and-light should live here in the greenhouse-effect repo. The problem with doing it this way is that molecules-and-light was done quite a while ago, so there is a lot of code and issue history already in the repo, and there are also quite a few translations. Moving the molecules-and-light code into the newer greenhouse-effect repo would not be an easy task, and we might lose some information in the process.
@jessegreenberg may have run into a similar situation a while back, since I think he worked on energy-skate-park after the subset energy-skate-park-basics had already been published. @jessegreenberg - Do you have any insights based on your past experiences as to how to handle this situation? Feel free to label this for dev meeting if you think it might help to discuss it with the other developers.
The text was updated successfully, but these errors were encountered: