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 changing upstream content #395

Merged
merged 5 commits into from
Mar 8, 2017
Merged

Conversation

tfoote
Copy link
Member

@tfoote tfoote commented Mar 8, 2017

This will auto commit changes to the upstream tarball as diffs for the debian increment.
Addresses issue in #374

It's not recommended, but there are a lot of times that this comes up in our community. This will make the sourcedebs robust to that.

This fixed the build: http://build.ros.org/view/Kbin_uxhf_uXhf/job/Ksrc_uX__openhrp3__ubuntu_xenial__source/18/console

tfoote and others added 2 commits March 8, 2017 11:17
This will auto commit changes to the upstream tarball as diffs for the debian increment.
Addresses issue in #374
# set the option for dpkg-source to auto-commit upstream changes
# This is needed for Debian increments where the upstream has changed.
# It's not the best practice but we have people doing it a bunch.
'--hook-source=\'bash -c "echo auto-commit > debian/source/options"\'',
Copy link
Member

@dirk-thomas dirk-thomas Mar 8, 2017

Choose a reason for hiding this comment

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

Since the file debian/source/options might already exist it would be better to append a line containing auto-commit rather than overwrite the content.

Copy link
Member Author

Choose a reason for hiding this comment

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

I updated it to append instead of write. There's still some edge cases, like what happens if it's already defined. But I think those are fewer and a good config file parser should handle that.

# set the option for dpkg-source to auto-commit upstream changes
# This is needed for Debian increments where the upstream has changed.
# It's not the best practice but we have people doing it a bunch.
'--hook-source=\'bash -c "echo auto-commit >> debian/source/options"\'',
Copy link
Member

Choose a reason for hiding this comment

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

This only works when an existing file has a trailing newline. Please update it to also work when an existing file doesn't.

Copy link
Member Author

Choose a reason for hiding this comment

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

injected new line

@dirk-thomas dirk-thomas merged commit a34649f into master Mar 8, 2017
@dirk-thomas dirk-thomas deleted the sourcedeb_fix branch March 8, 2017 22:53
@dirk-thomas
Copy link
Member

I retriggered http://build.ros.org/view/Kbin_djv8_dJv8/job/Ksrc_dJ__openhrp3__debian_jessie__source/18/ Once all downstream jobs have finished Kinetic can be synced again. Then we can merge pending rosdistro PRs.

@dirk-thomas
Copy link
Member

dirk-thomas commented Mar 9, 2017

@tfoote This patch is failing new source jobs on Zesty and Stretch. Can you please take care of this, e.g.:

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.

2 participants