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

Install xmllint manually #362

Merged
merged 1 commit into from
Dec 6, 2017

Conversation

jordisala1991
Copy link
Member

@jordisala1991 jordisala1991 commented Dec 6, 2017

Closes #359

Xmllint is not installed by default since we use trusty: xwp/wp-dev-lib#247

Proof that it does not work: just look at this lint build, there are a lot of lines of xmllint not found https://travis-ci.org/sonata-project/SonataAdminBundle/jobs/311420072

@greg0ire
Copy link
Contributor

greg0ire commented Dec 6, 2017

Please also use xargs instead of find so that the build fails on missing xmllint

@jordisala1991
Copy link
Member Author

I am not an expert on those commands, can you show me how to replace find with xargs?

@greg0ire
Copy link
Contributor

greg0ire commented Dec 6, 2017

-not -path './vendor/*' -not -path './Resources/public/vendor/*' -type f \
-exec xmllint --encode UTF-8 --output '{}' --format '{}' \;
-not -path './vendor/*' -not -path './Resources/public/vendor/*' \
| xargs -I'{}' xmllint --encode UTF-8 --output '{}' --format '{}'
Copy link
Member Author

Choose a reason for hiding this comment

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

tested on my environment

@@ -9,3 +9,4 @@ chmod u+x "${HOME}/bin/php-cs-fixer"
composer global require sllh/composer-lint:@stable --prefer-dist --no-interaction

gem install yaml-lint
sudo apt-get install -y libxml2-utils
Copy link
Member

Choose a reason for hiding this comment

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

Are you sure it's working? Sudo is not activated on Travis AFAIK.

Copy link
Member Author

Choose a reason for hiding this comment

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

Let me check on adminbundle

Copy link
Member Author

Choose a reason for hiding this comment

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

It does not work indeed. Do I need to enable sudo?

Copy link
Member

Choose a reason for hiding this comment

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

I would prefer not. It decrease performance a lot.

No another way to get this binary?

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 am trying other way to install it

addons:
apt:
packages:
- libxml2-utils
Copy link
Member Author

Choose a reason for hiding this comment

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

This is the other way I found @soullivaneuh

@jordisala1991
Copy link
Member Author

With this it works on admin-bundle: https://travis-ci.org/sonata-project/SonataAdminBundle/jobs/312312396

@soullivaneuh soullivaneuh merged commit d195c34 into sonata-project:master Dec 6, 2017
@jordisala1991 jordisala1991 deleted the hotfix/xmllint branch December 6, 2017 09:28
kasparsd added a commit to WordPress/two-factor that referenced this pull request Dec 6, 2017
brennensmith75 added a commit to brennensmith75/Two-Factor that referenced this pull request Sep 22, 2023
auroravirtuoso added a commit to auroravirtuoso/two-factor that referenced this pull request Jun 13, 2024
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