Skip to content
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

Add --repository-config option to set base branch for submodules #225

Merged
merged 8 commits into from
Feb 12, 2018
Merged

Add --repository-config option to set base branch for submodules #225

merged 8 commits into from
Feb 12, 2018

Conversation

rleigh-codelibre
Copy link
Contributor

@rleigh-codelibre rleigh-codelibre commented Feb 8, 2018

Testing:

  • clone https://github.com/ome/bio-formats-build.git
  • build and install scc
  • run scc merge --repository-config=repos.yml master --no-ask --reset --update-gitmodules -D none -I user:rleigh-codelibre -v for example
  • the configuration can be used recursively if submodules contain submodules (add a submodules section alongside base-branch in the submodule definition). The dict for the submodule will be passed to submodule GitRepository initialisation.

repos.yml example:

base-branch: master

submodules:
  ome-common-java:
    base-branch: master

  bioformats:
    base-branch: develop
    
  bio-formats-autogen:
    base-branch: master
    
  bio-formats-bundles:
    base-branch: master
    
  bio-formats-documentation:
    base-branch: master
    
  bio-formats-imagej:
    base-branch: master
    
  bio-formats-matlab:
    base-branch: master
    
  bio-formats-test:
    base-branch: master
    
  ome-codecs:
    base-branch: master
    
  ome-common-java:
    base-branch: master
    
  ome-jai:
    base-branch: master
    
  ome-mdbtools:
    base-branch: master
    
  ome-metakit:
    base-branch: master
    
  ome-model:
    base-branch: master
    
  ome-poi:
    base-branch: master
    
  ome-stubs:
    base-branch: master

@manics
Copy link
Member

manics commented Feb 8, 2018

FYI there are some long-standing requests for scc and omego to support a config file to save having to define common args on the command line, e.g.

@rleigh-codelibre
Copy link
Contributor Author

Presumably, once ome/yaclifw#7 is merged we could switch over to use it.

@manics
Copy link
Member

manics commented Feb 8, 2018

I only mentioned it because of the naming of the new parameter --config which sounds quite generic.

@rleigh-codelibre
Copy link
Contributor Author

Yes, it could be renamed to something more specific. Or, we could allow more than branch configuration in the future. For example, it could be extended to support per-repository filtering options etc.

@rleigh-codelibre
Copy link
Contributor Author

Renamed --config to --repository-config. I used "repository" rather than "branch" because it's more related to repositories regarding submodules and base branches.

@joshmoore joshmoore changed the title Add --config option to set base branch for submodules Add --repository-config option to set base branch for submodules Feb 9, 2018
@sbesson sbesson self-requested a review February 12, 2018 15:03
@sbesson
Copy link
Member

sbesson commented Feb 12, 2018

The changes proposed here make sense, are overall backwards-compatible while allowing more granularity on the control of some of the filter options via a YML configuration file. The support for file-based flexible configuration is something that has been discussed as a more generic feature (see ome/yaclifw#7) and having such a concrete driver is a good first step.

Assuming the unit and integration tests pass, happy for this to be released as 0.9.0.

NB: as an extra feature, should I open a PR to port to scc the project-wide VERSION strategy implemented in omego in ome/omego#114. Depending on the timeline, this should be completely safe to be pushed to a follow-up patch release.

@joshmoore joshmoore merged commit 9a095c5 into ome:master Feb 12, 2018
@rleigh-codelibre rleigh-codelibre deleted the merge-config branch February 12, 2018 16:00
@sbesson sbesson added this to the 0.8.1 milestone Jun 6, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants