-
Notifications
You must be signed in to change notification settings - Fork 18
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
delete files in destination repo #46
Comments
Hehe, good timing. You created this issue 8 days ago, and I was writing about it 6 days ago asyncapi/.github#199 (comment) 😆 So yeah, this action does not support removal. It has simple behavior, copies changes to files (new or edits), and pastes in give repo where things need to be replicated. I was thinking of modifying the code to also support the removal of files by basically detecting that file was deleted so it must be removed form the destination folder. But...but recently I had a use case when I had to remove a workflow file from 55 repos out of 62 and luckily found a contributor willing to do clean up. I could not remove the original workflow from I love the idea with we could have:
so Go-related now only question is how If I say
then Also, my assumption is that pinging other contributors for opinion as they might also be interested in this solution |
I would keep the settings the same and introduce no additional settings. When a file is removed (assuming the delete file is included in patterns_to_include) in the source repo, I would expect that it's also removed in the destination repo's. It seems like the natural behaviour. |
I actually think we need 2 different solutions:
Looks like another action name change is approaching. Name Any suggestions? |
|
I would have made a discussion on this, but it's not enabled for this repo so thought I'd share here. Did you guys see this new feature being rolled out on GitHub? https://github.blog/changelog/2023-01-10-github-actions-support-for-organization-wide-required-workflows-public-beta/ I don't think it replaces this action completely as I often use it to copy non-workflow files. I've yet to try it but I think it can at least simplify the matrix I'm using for this action. Edit: These currently only support |
I opened a PR to get this done finally #48 |
Thank you! Unfortunately I won't be able to test it as I've already manually removed everything and don't have a test org setup. |
@ReenigneArcher no worries, thanks for info |
v2.1.0 is out but |
worked well asyncapi/generator#950 workflows with 2 jobs https://github.com/asyncapi/.github/blob/master/.github/workflows/global-remover.yml normally would create 2 PRs, not just one PR with 2 commits |
anyone have time to test before |
Hi, I finally have another use case for this. Unfortunately the option being mutually exclusive is really not ideal. That severely complicates my matrix run. Edit: maybe not that big a deal now that this is in #50 Didn't even realize that got merged... going to try it out. |
Reason/Context
Please try answering few of those questions
I am in process of combining two workflow files into one. One of the files will then be deleted. I would assume this action does not currently delete files from the destination repo (please correct me if I'm mistaken).
It would be preferable to have the files to delete specified by this action as I don't want to open additional PRs.
Description
Please try answering few of those questions
You could add a new input
patterns_to_remove
. Then try to delete the file in the destination repo, but don't fail if it doesn't exist.The text was updated successfully, but these errors were encountered: