let demo_content target in makefile run multiple times #295
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
To test:
I ran into some trouble building the demo site and had to run
make demo
multiple times, but on iterations after the first I kept seeing this error related to running setup.py in Islandora workbench:I tracked the problem back to the final
sed
command in thedemo_content
target; it replaces "author_email="mjordan@sfu", with "author_email="mjordan@sfu", packages=[... but it's happy to do that multiple times, leading to the error above. Most other things in the repeat run seemed to work despite some warnings. I just modified thesed
so it'll only run the substitution on the line if the line doesn't already have "packages" listed. I also removed sed's "g" flag since I don't think a global substitution makes sense here.I realize this is an edge case since people shouldn't be running
make demo
multiple times without cleaning things out in between but it came up for me so I figured I'd submit a PR.