-
Notifications
You must be signed in to change notification settings - Fork 0
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
Timestamps of installed packages in container? #1
Comments
Yes. I did it on purpose. Take a look at the base container this depends on: tidyviz-base Hope this helps |
It does, thanks. I was trying to modify your code so that I could see when a package started, and completed install, and this is what I have come up with: I'm wondering if this is a good use case for the glue package to combine the strings package name, along with when execution is complete for a function?
|
I've noticed your call to install glue outside pacman call. Better this way:
Also, you don't need all the code for your purpose:
Hope this works |
Hmm, I'm not exactly sure how glue works, as that last line was causing me errors, but this seems to work on startup:
which produces: Starting Install for packagefortunesmethodsbase But if I call install.packages("tidytext"), shouldn't I expect the .First and .last calls to trigger, or does that only trigger at the beginning of an R Session? |
.First( ) will be run at the start of the R session and .Last( ) will be run at the end of the session. |
@verajosemanuel so is it possible to have a .Last() call trigger after the install.packages completes, or is it better to simply create a wrapper for If I understand your script, it seems like fortunes is simply a placeholder for your package, and when the function completes, it should output a message? |
Fortunes is a package showing random sentences on console. |
I understand what the fortunes package does, but isen't that a placeholder? Like these lines from your build file: �[0m How is stanheaders using the .First and .Last call if you diden't explicitly define |
that is very odd, didn't notice this. I've to assume this behavior is due to some hidden call to .Last even if you don't make it explicit. Thanks for reporting |
@verajosemanuel No problem, it's just that I'd really like to create some sort of way of stating that the package install started for package x, and completed for package x. That would be incredibly helpful. |
FYI it looks like |
Have you looked at pacman functions? maybe any is suitable for you. https://cran.r-project.org/web/packages/pacman/vignettes/Introduction_to_pacman.html |
pacman does not support this natively, but I would love it if it did. You should try |
just because the time i've included in the dockerfile the only option was github, and had no time to check it all... |
I see. It might be worth trying to do a simple unit test via testthat's tool to view what packages installed successfully: |
Hello,
I'm curious how you were able to implement time stamps in your Build logs for this container such as:
Did you purposefully intend to do so? I've been meaning to try and do something similar for a container I am working on. Thanks
The text was updated successfully, but these errors were encountered: