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

How to keep all packages synchronized with the evolving skeleton? #1

Closed
ximeg opened this issue May 13, 2020 · 10 comments
Closed

How to keep all packages synchronized with the evolving skeleton? #1

ximeg opened this issue May 13, 2020 · 10 comments
Assignees

Comments

@ximeg
Copy link

ximeg commented May 13, 2020

The hyperSpec.skeleton will be a 'template' for several packages. Do we have a plan how we are going to synchronize them with each other?

I can imagine the following situation: we make four derived packages named A, B, C and D. Some time later, we decide to change the build system, or contrinuous integration, or vignette style, whatever. The purpose of the skeleton is to simplify this, so it should be possible to make a change only once in the skeleton package and propagate it to the derived packages.

Once we have this clarified, it should also go into the contributor's guide :)

@eoduniyi
Copy link
Contributor

eoduniyi commented May 14, 2020

That's interesting...

Maybe there should be a hy_update_packages() similar to utils::update.package()...

# Install hyperSpec.skeleton package from github
remotes::install_github("eoduniyi/hyperSpec.skeleton")
library(hyperSpec.skeleton)

# Update all the packages
hy_update_packages()
.
.
.

But yeah, that's just the interface...I'm not entirely sure what hy_update_packages() would do in order to ensure all of the users' currently installed hyperSpec CRAN packages are "updated"

Perhaps a user (contributor) would call hy_update_packages() from within R and the function would go find all the hyperSpec packages and update them appropriately (update .yml, .md, etc.)

Note: But if hyperSpec.skeleton has a function that can modify the user's file system, then I'm not sure it will pass through CRAN's requirements, so maybe hyperSpec.skeleton doesn't go on CRAN, but its derived packages can/will.

@ximeg
Copy link
Author

ximeg commented May 14, 2020

I did a bit of research... Apparently one can create template repositories in GitHub and create new repos from this template. I'm not sure whether it is what we need, and that one can pull the upstream changes from the template to the derived repo. I think we need to investigate this.

There is also a corresponding discussion on StackOverflow.

@bryanhanson
Copy link
Collaborator

Good find @ximeg I think this is worth a try. Probably safer if the template branch has a single branch.

@eoduniyi
Copy link
Contributor

eoduniyi commented May 18, 2020

Hmmm,

Well, it appears that being able to propagate changes from the template repository is only possible if we make the template repository a remote of its derived repositories. So if we happen to make changes to the hyperSpec.skeleton repository, the derived repositories would need to fetch those changes from hyperSpec.skeleton.

..seems like a solid solution assuming we change hyperSpec.skeleton rarely.

@eoduniyi eoduniyi self-assigned this May 18, 2020
@GegznaV
Copy link
Member

GegznaV commented Jun 23, 2020

We can create a test on CI system, that checks if we need to update certain files from the "skeleton" repo.

@cbeleites
Copy link
Collaborator

... and then maybe use patches to propagate relevant changes to the derived repositories.

@eoduniyi
Copy link
Contributor

... and then maybe use patches to propagate relevant changes to the derived repositories.

How would you recommend us/me going about this?

@GegznaV
Copy link
Member

GegznaV commented Jun 24, 2020 via email

@eoduniyi
Copy link
Contributor

E.g., Script + GitHub (GH) actions. Eric, can you find out how to use GH Actions to copy files from one repository in to the other? Maybe you can create two repos on your account and experiment with them? 2020 birž. 24, tr 22:16, Erick Oduniyi [email protected] rašė:

... and then maybe use patches to propagate relevant changes to the derived repositories. How would you recommend us/me going about this? — You are receiving this because you commented. Reply to this email directly, view it on GitHub <#1 (comment)>, or unsubscribe https://github.com/notifications/unsubscribe-auth/ADBC43HY2KMJ2KYQHHMH2R3RYJGIZANCNFSM4NAGKTGQ .

Sounds good! On it

@bryanhanson
Copy link
Collaborator

Closed in favor of r-hyperspec/r-hyperspec.github.io#13

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

No branches or pull requests

5 participants