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

In case ID_LIKE contains space separated identifiers #377

Closed
wants to merge 1 commit into from

Conversation

kewlfft
Copy link
Contributor

@kewlfft kewlfft commented Oct 9, 2018

As per follow up discussion in #372 (comment)

@kewlfft
Copy link
Contributor Author

kewlfft commented Oct 16, 2018

Hopefully this should be a straightforward fix, I am waiting for it to update my Arch user package and avoid any bad surprise in case of ID_LIKE with multiple OS names

bin/etc-update Outdated
@@ -32,7 +32,7 @@ get_config() {
"${PORTAGE_CONFIGROOT}"etc/etc-update.conf)
}

OS_RELEASE_POSSIBLE_IDS=$(source /etc/os-release >/dev/null 2>&1; echo ":${ID}:${ID_LIKE}:")
OS_RELEASE_POSSIBLE_IDS=$(source /etc/os-release >/dev/null 2>&1; echo ":${ID}:${ID_LIKE// /:}:")
Copy link
Member

Choose a reason for hiding this comment

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

We can use ${ID_LIKE//[[:space:]]/:} here to handle all whitespace characters (including tabs).

@kewlfft
Copy link
Contributor Author

kewlfft commented Oct 19, 2018

@zmedico I have implemented your proposal.

Copy link
Member

@zmedico zmedico left a comment

Choose a reason for hiding this comment

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

Looks good, thanks! Please squash the commits together.

…incl tabs)

Signed-off-by: Kewl Fft <kewl@alto.eu.org>

to handle all whitespace characters including tabs
Signed-off-by: Kewl Fft <kewl@alto.eu.org>
@kewlfft
Copy link
Contributor Author

kewlfft commented Oct 19, 2018

squashed as requested

@zmedico
Copy link
Member

zmedico commented Oct 20, 2018

Merged in 7a3d898, thanks!

@kewlfft kewlfft deleted the fix/arch branch November 19, 2018 21:05
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