Skip to content

add support for append_paths in module generator#2294

Merged
wpoely86 merged 3 commits intoeasybuilders:developfrom
boegel:append_paths
Sep 4, 2017
Merged

add support for append_paths in module generator#2294
wpoely86 merged 3 commits intoeasybuilders:developfrom
boegel:append_paths

Conversation

@boegel
Copy link
Copy Markdown
Member

@boegel boegel commented Sep 3, 2017

No description provided.

Comment thread easybuild/tools/module_generator.py Outdated
raise EasyBuildError(str(err).replace('prepend', 'append'))

regex = re.compile('^prepend([-_]path)', re.M)
return regex.sub(r'append\1', txt)
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't really like this.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The alternative is to copy-paste the code for prepend_paths, and replace prepend with append. I'm not a big fan of that approach...

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It would be a less confusing approach though. This one is slightly ugly in my opinion.

@boegel
Copy link
Copy Markdown
Member Author

boegel commented Sep 4, 2017

@akesandgren @wpoely86 better now?

@easybuilders easybuilders deleted a comment from boegelbot Sep 4, 2017
@wpoely86 wpoely86 merged commit ffc347c into easybuilders:develop Sep 4, 2017
@boegel boegel deleted the append_paths branch September 4, 2017 09:34
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.

3 participants