https://github.com/ampproject/amphtml/blob/master/validator/README.md does not contain Mac OSX and Windows installation steps for dependencies
This is what worked for me on OSX.
brew install protobuf
Result:
Editor support and examples have been installed to:
/usr/local/opt/protobuf/share/doc/protobuf
Python modules have been installed and Homebrew's site-packages is not
in your Python sys.path, so you will not be able to import the modules
this formula installed. If you plan to develop with these modules,
please run:
mkdir -p /Users/USERNAME/Library/Python/2.7/lib/python/site-packages
echo 'import site; site.addsitedir("/usr/local/lib/python2.7/site-packages")' >> /Users/USERNAME/Library/Python/2.7/lib/python/site-packages/homebrew.pth
So I ran:
mkdir -p /Users/USERNAME/Library/Python/2.7/lib/python/site-packages
echo 'import site; site.addsitedir("/usr/local/lib/python2.7/site-packages")' >> /Users/USERNAME/Library/Python/2.7/lib/python/site-packages/homebrew.pth
Then I installed JDK.
brew tap caskroom/cask
brew install Caskroom/cask/java
Then I was able to run gulp validator
Erwin was experiencing some issues with .DS_Store files. Here are my notes about that:
Macs create a file called .DS_Store every time a user enters that director. amphtml-validation tries to traverse it as a directory and throws an error. Deleting the file allows amphtml-validation to work, but if the user enters the directory (e.g. component/test/...) the .DS_Store file will be created again.
/cc @mrjoro
thanks so much @levidurfee
This issue hasn't been updated in awhile. @erwinmombay Do you have any updates?
This worked for me! @erwinmombay I think we should really add this to the documentation :)
@Enriqe oops. i always thought we added this... ill send out a PR
how about windows??
when I run gulp validator --update_tests to build .out file
[[build.py CheckPrereqs]] - entering ...
Sorry, this script assumes Linux or Mac OS X thus far. Please feel free to edit the source and fix it to your needs.
[15:56:24] The following tasks did not complete: validator
[15:56:24] Did you forget to signal async completion?
@Exlord as the script suggests, maybe you can update it to work for windows?
@Exlord as the script suggests, maybe you can update it to work for windows?
How? The script just says do it, does not say how?? And I don't know python!