Closed bgervan closed 1 year ago
Fix:
Add working-directory: sites
to action steps
- name: Check website-stalker config
working-directory: sites
run: website-stalker check
- name: Run website-stalker
working-directory: sites
run: website-stalker run --all
Move website-stalker.yml (config) to the used working directory, in the above case sites
folder
This is basically the intended behaviour of #187 as this tool assumes a clean repository with only website-stalker.yaml
and the stalked files. (Hidden files and folders like .git
or .github
are preserved)
I am not sure about working-directory
as it probably also breaks the --commit
feature.
An option could be an additional option to define the root folder of the sites. The downside would be more logic.
Alternatively every site entry could be in sites
again with the domain structure inside the sites
folder.
Out of curiosity: why do you need other content in the same repository? Is there a use case I wasn't aware of yet?
The new behaviour is fine, but it broke the already used github action out of nowhere. Is there a config in the github action where we can specify the desired version?
Sorry for the breaking change there with a different setup than I expected.
There is a version input which should work:
Thanks, I will use that too. No worries, we can close this, my comments shows the solution in case others ran into the same problem
Your comment is a workaround which will prohibit --commit
of working correctly. I'm still curious about your use case and the thought of putting the files into sites
again is not dead.
I have a repo which is a API wrapper and I am using the stalker to check updates for the API doc. I am using the sites folder to store the fetched txt files. Basically I am using the same approach as the commit which introduced the change. The config was in the root and the stalker downloaded the websites into "sites" folder by default, with the lates version I moved the config to the sites folder and changed the action steps accordingly, so the stalker only removed all the files inside the sites folder.
I am not sure to understand what is prohibited by my approach and usage. The above solution requires a manual work on the commit to remove the old files though, if that is what you mean.
https://github.com/EdJoPaTo/website-stalker/commit/fd9163fc376ee1913600fa24501e616983d2d90c This commit contains the same changes that I mentioned, the yml is moved to sites folder etc.
Describe the bug The Github Action started to remove all folders and files from the repo before running fetching the websites.
Versions
Expected behavior Works as before with the same config.
Additional information