-
Notifications
You must be signed in to change notification settings - Fork 46
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
Customize the directory to serve from #42
Comments
Deploying documentation to A more traditional approach would be to copy # Preview
- name: Deploy Preview
uses: rossjrw/pr-preview-action@v1
with:
source-dir: docs
preview-branch: gh-pages
umbrella-dir: pr-preview
action: auto # Main deployment
- uses: JamesIves/github-pages-deploy-action@v4
with:
folder: docs
target-folder: .
branch: gh-pages
clean-exclude: pr-preview That would probably be easiest and more in line with the 'standard' approach. But assumptions and principle aside, if you really do need to deploy from Line 131 in 0223615
Lines 152 to 153 in 0223615
The long-term solution to this would be to add a parameter that indicates what directory Pages is being served from in that repo, as you originally suggested. |
We can definitely get around this by changing configurations in GH, but I think this is still a valuable feature to add for anyone who doesn't have easy access to the repo settings or a person with repo admin access. |
+1 for this, even if it was just a separate input which would replace the partial string of umbrella-dir. umbrella-dir: 'docs/preview'
pages-base: 'docs/' then on the output just replace any instance of |
Our Github Pages configuration is set up to serve from a subdirectory and there is currently no documented way to address this with pr-preview-action.
Example:
Preview Deployment Action
Deployment Action
With the above configurations, we end up with everything correctly being saved to the
docs
directory. The generated preview link is/docs/pr-preview/pr-xx
. I can delete the/docs
path part and see the preview just fine, but the generated link shows a totally valid 404 because we are serving directly from thedocs
directory that things are being saved to rather than serving from the root directory.The text was updated successfully, but these errors were encountered: