Skip to content

Looking for good documentation on how to get started on a straight forward CLI workflow. #397

Answered by wwilsman
alphex asked this question in Support
Discussion options

You must be logged in to vote

I wanted to add that if you're using the latest version of the CLI, the percy snapshot command also accepts a --base-url flag that will be used as the base URL for any snapshots with relative URLs.

So if you have this snapshots.yml:

- /about
- /contact
- /blog
- /etc

You can take snapshots of two different base-urls like so:

# to take snapshots of the production branch:
PERCY_BRANCH=production \
percy snapshot snapshots.yml --base-url https://www.foobar.com

# to take snapshots of the staging branch:
PERCY_BRANCH=staging \
PERCY_TARGET_BRANCH=production \
percy snapshot snapshots.yml --base-url https://staging.foobar.com

If the project is under version control and you're running the comma…

Replies: 3 comments 4 replies

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
4 replies
@alphex
Comment options

@alphex
Comment options

@wwilsman
Comment options

@alphex
Comment options

Answer selected by alphex
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Support
Labels
None yet
3 participants
Converted from issue

This discussion was converted from issue #395 on June 28, 2021 16:18.