-
-
Notifications
You must be signed in to change notification settings - Fork 3
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
Add working directory #14
base: master
Are you sure you want to change the base?
Conversation
👿 It is a travesty - a blundering mountain of hatred and rage. |
Hi @sondalex, Thank you for such great contribution! I appreciate you for taking the time to prepare and submit it. I must admit that I'm not familiar with If you have the time, it would be wonderful to add this Lastly, it is important to preserve backward compatibility as with any software. So in order to ensure that we won't be disrupting the existing users with this change, we need to test it thoroughly. I've already hooked one of my repos to your feature branch, and it worked fine with no issues: I'll also test it with some of our current dependents, to see if it would break their workflow or not. My main focus will be the repos which pass various parameters to the action, to see if they conflict with each other or not. I'll update you on this afterwards, to let you know how it fares. In the meantime, it would be great if you could address the necessities I've disclosed above. I'm looking forward to working and merging this together with you, this will be a great addition. Thank you very much! P.S: Note to myself, don't forget to add it to the acknowledgement section |
Hi @skywarth, thank you for your response and feedback. Your project is greatly helpful for rapidly deploying Vite applications to GitHub. I appreciate the effort you put into developing it! The working-directory keyword allows you to specify the directory in which commands are executed within a GitHub Action workflow. Currently, the main branch assumes that the repository's structure includes
With this structure, a corresponding GitHub Action configuration would look like this: name: Vite GitHub Pages Deploy
on:
push:
branches: ["master", "main"]
workflow_dispatch:
permissions:
contents: read
pages: write
id-token: write
concurrency:
group: "pages"
cancel-in-progress: false
jobs:
build:
runs-on: ubuntu-latest
environment:
name: gh-pages
url: ${{ steps.deploy_to_pages.outputs.github_pages_url }}
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Deploy to GitHub Pages
uses: sondalex/vite-github-pages-deployer@add_working_directory
id: deploy_to_pages
with:
working-directory: ./app In addition you I have updated the documentation accordingly. |
Looking good! Thank you for updating the documentation as well. I was wondering how does this differ from the existing |
🕯️ A sister of battle. Pious and unrelenting. |
The Example: Since Here’s an improved version of your note: Note: This method has the advantage of eliminating the need to define an intermediary environment variable for specifying the artifact directory. @skywarth what are your thoughts on this ? |
Gotcha, it's crystal. Thank you for the explanation. It is a good use-case then. About that alternative solution; I actually like the ring of it. It would simplify things a lot. But I'm considering if there is a catch where it could make it difficult for us, whether somehow there would a be case where we would need to be on another upper (or root) directory of the repository. Let's stick to what we have for now, I wouldn't want you to invest even more effort into it. I'll try to find a few dependents where they specified I'm listing the test cases below for easier time tracking:
I plan on doing the tests on weekend, I'll ping you once they are done. Afterwards if all goes well, we can wrap it up and merge it for good. Two considerations you might wanna give a pondering about in the meantime:
Thank you |
This PR adds
working-directory
for build and deployment process.