Add styleguide build command.#93
Conversation
… the configuration task in the install process.
|
Running this by default in the VM will cause issues for devs using Yarn on their host machine. When there's a mismatch, it results in the following type of error: Would it be best to limit this to |
|
For documentation, it might be a good idea to add a section to the project readme, with maybe a link to a new document in |
|
|
||
| <!-- Target: styleguide --> | ||
| <target name="styleguide" description="Install and build the style guide."> | ||
|
|
There was a problem hiding this comment.
Should this test whether the properties are set first? That way they can be only run on Circle, if desired.
There was a problem hiding this comment.
That's a good point -- especially re: the nodejs installs that vary by platform.
The thing is, where the styleguide is built tends to vary between development roles -- folks doing design and front end development will build it locally, but folks doing engineering, devops, or support will build the styleguide within the VM.
So I'm not sure where to go with this...
There was a problem hiding this comment.
@becw and @russom-woldezghi, I think I have resolved this by checking for a linux-x64-59 binding in node-sass. If it isn't there, Phing will run yarn install, which actually allows you to use Butler on both the host and VM to build the styleguide (assuming the Node versions match).
There was a problem hiding this comment.
I tested by building the styleguide on my host, then running phing build in the VM, which ran successfully. I was also able to go back to my host and build the styleguide again.
We could also point to have users run: |
russom-woldezghi
left a comment
There was a problem hiding this comment.
Looks good overall. It would be nice to have a way to test against a Pantheon/Acquia environment to get close to production test run.
…example <includeresource /> call.
|
Requires palantirnet/butler#101 and palantirnet/the-vagrant#56 for new projects. |
|
Since we're not using Butler for new projects, I'm not going to worry about palantirnet/butler#101 :) |
|
... and, I'm going to close this in favor of #117, which I just merged! Thank you, @byrond and @russom-woldezghi, for uncovering and pursuing these issues! Your work in this PR made it super easy to update this work for the release-2.0 branch. |
Completes ZRAD-119 - Add styleguide target to palantirnet/the-build.
To test:
composer require --dev palantirnet/the-build:dev-styleguide-build-commandsvendor/bin/the-build-installerphing build-- this should install the styleguide dependencies and run the styleguide command that you configuredphing styleguide-- since your dependencies are already installed, this should just rerun the styleguide commandOpen questions:
<import>line for the styleguide targets to the project'sbuild.xmlstyleguideto the existingbuildtarget, if desiredphing styleguide-configure -Dbuild.env=default