Skip to content
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

Old files remain deployed #12

Closed
TysonMN opened this issue Jun 15, 2020 · 4 comments
Closed

Old files remain deployed #12

TysonMN opened this issue Jun 15, 2020 · 4 comments
Assignees
Labels
enhancement New feature or request

Comments

@TysonMN
Copy link
Contributor

TysonMN commented Jun 15, 2020

I renamed my img folder to images. The images are now accessible via that directory, but they are still available at the previous one as well.

Alternatively, looking at my gh-pages branch shows both the img and images folders.

I expected old files like those in img to be deleted from gh-pages when I push to master commits that removed those files (and all the files inside them).

Is the fix to delete the pre-existing files in the run step of the GitHub deploy script?

I tried removing files from dist with the command rm -rf dist/, but my deploy fails.

@loreanvictor
Copy link
Contributor

for cleaning up your gh-pages build, I suspect the cleanest way is to switch to gh-pages branch locally, remove files you do not want on the branch anymore (and ensure codedoc doesn't generate them again), and then push the branch.

on coding.blog, this is an issue and currently there is no mechanism for cleaning up old files. it is on our roadmap, so I'll keep this issue open for monitoring the release of that feature.

@must

@loreanvictor loreanvictor added the enhancement New feature or request label Jun 15, 2020
@TysonMN
Copy link
Contributor Author

TysonMN commented Jun 16, 2020

for cleaning up your gh-pages build, I suspect the cleanest way is to switch to gh-pages branch locally, remove files you do not want on the branch anymore (and ensure codedoc doesn't generate them again), and then push the branch.

I removed all the files in the img folder of my gh-pages branch, pushed that branch, then triggered another deploy (by pushing some "no-op" change to master), but https://tysonwilliams.coding.blog/img/cb-banner-dark.svg still exists (...as long as I am not being tricked by a cache).

Whatever. I don't really like having to do that anyway. I would rather wait for an automated solution (but this might help in creating the automated solution, so I thought I would share it).

@loreanvictor
Copy link
Contributor

for cleaning up your gh-pages build, I suspect the cleanest way is to switch to gh-pages branch locally, remove files you do not want on the branch anymore (and ensure codedoc doesn't generate them again), and then push the branch.

I removed all the files in the img folder of my gh-pages branch, pushed that branch, then triggered another deploy (by pushing some "no-op" change to master), but https://tysonwilliams.coding.blog/img/cb-banner-dark.svg still exists (...as long as I am not being tricked by a cache).

That solution is for your GitHub pages site not for coding.blog, which is an independent deploy. For example, while your GitHub pages deploys contents of gh-pages branch, coding.blog deploys contents of your main branch, which can be completely different.

Anyways, as mentioned before, currently there is no way to clear files from your coding.blog (but there is for GitHub pages), which is why this issue is open.

@must
Copy link
Member

must commented Oct 14, 2020

This relates to the diff system that we will implement. Then we will be able to update the published files to reflect the latest published built files (i.e. removing ones that don't result from the build any more).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants