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 support for runnning gitdist from subdir but move to base dir #212

Closed
bartlettroscoe opened this issue Jul 26, 2017 · 1 comment
Closed

Comments

@bartlettroscoe
Copy link
Member

bartlettroscoe commented Jul 26, 2017

CC: @jmgate

Description:

Currently, the gitdist script runs in the current working directory. If there is a .gitdist or .gitdist.default file in that directory, then it will loop over all of the existing git repos listed there. That requires constantly cd'ing to the base git repo to run gitdist. It would be nice if gitdist could be configured to allow it to be run in a subdir or sub git repo and move to the base repo where the .gitdist and .gitidst.default file exists and run from there.

ToDo: More fully document the use cases.

Definition of Done:

  • Implements desired behavior [DONE]
  • New behavior is defined and protected with automated tests.
  • New behavior is documented with gitdist --dist-help=move-to-base-dir.
@bartlettroscoe
Copy link
Member Author

This has been in progress for some time with the PR #203. That PR contains the full implementation (manually tested) but contains no documentation or unit testing. This story is to add unit tests and documentation for that new feature in #203. However, I don't have time right this second to write that documentation or unit tests so I am going to go ahead and merge in the PR branch so that this can be used. Ordinarily I would not do that but since this new behavior is off by default and is undocumented, and the default behavior is well tested, it is harmless to go ahead and merge this branch so that @jmgate can use the 'master' branch of TriBITS for his work. Then, in the next few days, hopefully, I will add the unit tests and documentation so that everyone can know about this great new feature.

bartlettroscoe added a commit that referenced this issue Jul 26, 2017
This merged in the new behavior for the var GITDIST_MOVE_TO_BASE_DIR but not
unit tests or documentation yet.  Since this is off by default and is not
documented, I think it is okay to merge this so that jgmate can start using
this.  In the next few days I will add the needed unit tests and
documentation.

Build/Test Cases Summary
Enabled Packages:
Enabled all Packages
0) MPI_DEBUG => passed: passed=247,notpassed=0 (0.59 min)
1) SERIAL_RELEASE => passed: passed=247,notpassed=0 (0.57 min)
2) MPI_DEBUG_CMAKE-3.6.2 => passed: passed=266,notpassed=0 (0.58 min)
3) SERIAL_RELEASE_CMAKE-3.6.2 => passed: passed=266,notpassed=0 (0.54 min)
Other local commits for this build/test group: 39555f4, 442848e, 014db9f, 82822cb, 9c1c413, 0515073
jmgate added a commit to jmgate/TriBITS that referenced this issue Nov 2, 2017
Added setUp() and tearDown() methods to each unittest class to clear the
GITDIST_MOVE_TO_BASE_DIR environment variable before each test and then
restore it after.
jmgate added a commit to jmgate/TriBITS that referenced this issue Nov 2, 2017
The gitdist_move_to_base_dir unit test now covers the expected behavior
when GITDIST_MOVE_TO_BASE_DIR is unset, or set to IMMEDIATE_BASE, or
EXTREME_BASE.
jmgate added a commit to jmgate/TriBITS that referenced this issue Nov 2, 2017
The ability to use the environment variable GITDIST_MOVE_TO_BASE_DIR to
change gitdist's behavior is now documented (see
--dist-help=move-to-base-dir) and tested (see the
gitdist_move_to_base_dir unit test).
jmgate added a commit to jmgate/TriBITS that referenced this issue Nov 2, 2017
The ability to use the environment variable GITDIST_MOVE_TO_BASE_DIR to
change gitdist's behavior is now documented (see
--dist-help=move-to-base-dir) and tested (see the
gitdist_move_to_base_dir unit test).
jmgate added a commit to jmgate/TriBITS that referenced this issue Nov 3, 2017
IMMEDIATE_BASE now behaves as documented in the absence of any
.gitdist[.default] file in the directory tree.
jmgate added a commit to jmgate/TriBITS that referenced this issue Nov 3, 2017
Also added a unit test for when GITDIST_MOVE_TO_BASE_DIR is set to some
invalid value.
bartlettroscoe added a commit to trilinos/Trilinos that referenced this issue Nov 8, 2017
* Improve error messages from new TriBITS usage checks (TriBITSPub/TriBITS#200).

* Some new features for gitdist:
  - default-branch (TriBITSPub/TriBITS#235)
  - move-to-base-dir (TriBITSPub/TriBITS#212)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant