# Replicate Pkg.jl progress bar

**URL:** <https://discourse.julialang.org/t/replicate-pkg-jl-progress-bar/84217>\
**Category:** New to Julia\
**Tags:** question\
**Created:** [July 14, 2022, 12:54pm UTC](https://discourse.julialang.org/t/replicate-pkg-jl-progress-bar/84217 "2022-07-14T12:54:53Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![gitboy16](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/gitboy16/32/24906_2.png) [@gitboy16](https://discourse.julialang.org/u/gitboy16)\
**Post date:** [July 14, 2022, 12:54pm UTC](https://discourse.julialang.org/t/replicate-pkg-jl-progress-bar/84217/1 "2022-07-14T12:54:53Z")

</div>

Hi,

Is there a way to replicate exactly the progress bar of julia package manager Pkg.jl ?

The progress bar appears when a project is pre-compiling the necessary libraries. It displays spinning wheels for multiple package at the same time…etc. It seems precimpilation is happening in parallel, but i might be wrong about that.

I like this progress bar because it tells which packages are being processed (in parallel), which one complete successfully or not.

I noticed that there is a module called MiniProgressBars in Pkg.jl but how it is used seems complicated. Maybe someone has an example of how it works?

Thank you

---

<div class="post-metadata">

**Author:** ![ianshmean](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/ianshmean/32/216042_2.png) [@ianshmean](https://discourse.julialang.org/u/ianshmean)\
**Post date:** [July 14, 2022, 1:21pm UTC](https://discourse.julialang.org/t/replicate-pkg-jl-progress-bar/84217/2 "2022-07-14T13:21:04Z")

</div>

The precompilation animation isn’t abstracted unfortunately. It’s baked into a single `Pkg.precompile` function.

It could be brought out, but be aware that `MiniProgressBars` is an internal, and a progress bar is unlikely to become part of the public API of Pkg.

I’d recommend porting the ‘precompile’ progress animation to one of the progress bar packages.

---

<div class="post-metadata">

**Author:** ![gitboy16](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/gitboy16/32/24906_2.png) [@gitboy16](https://discourse.julialang.org/u/gitboy16)\
**Post date:** [July 14, 2022, 1:54pm UTC](https://discourse.julialang.org/t/replicate-pkg-jl-progress-bar/84217/3 "2022-07-14T13:54:46Z")

</div>

Thank you @ianshmean . Is there a way to trigger that `precompile` function (let’s say for a local julia package) so maybe I can then step into the function to see how it works? And “extract” the progress bar?

Thank you

---

<div class="post-metadata">

**Author:** ![halleysfifthinc](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/halleysfifthinc/32/206280_2.png) [@halleysfifthinc](https://discourse.julialang.org/u/halleysfifthinc)\
**Post date:** [July 14, 2022, 3:44pm UTC](https://discourse.julialang.org/t/replicate-pkg-jl-progress-bar/84217/4 "2022-07-14T15:44:51Z")

</div>

This sounds like it might be an [XY problem](https://en.wikipedia.org/wiki/XY_problem). If you’re just looking for progress bars in general (and unrelated to Pkg), [ProgressMeter.jl](https://github.com/timholy/ProgressMeter.jl) has progress bars and progress spinners (the appearance of either is customizable).

---

<div class="post-metadata">

**Author:** ![gitboy16](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/gitboy16/32/24906_2.png) [@gitboy16](https://discourse.julialang.org/u/gitboy16)\
**Post date:** [July 14, 2022, 4:12pm UTC](https://discourse.julialang.org/t/replicate-pkg-jl-progress-bar/84217/5 "2022-07-14T16:12:27Z")

</div>

@halleysfifthinc , thank you. I know about ProgressMeter but I was unable to reproduce the behaviour that I can observe in Pkg.jl. If you know how to do that, I am curious to know how you do it.

---

<div class="post-metadata">

**Author:** ![halleysfifthinc](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/halleysfifthinc/32/206280_2.png) [@halleysfifthinc](https://discourse.julialang.org/u/halleysfifthinc)\
**Post date:** [July 14, 2022, 5:58pm UTC](https://discourse.julialang.org/t/replicate-pkg-jl-progress-bar/84217/6 "2022-07-14T17:58:21Z")

</div>

The desired behaviour observed in Pkg.jl being multiple, simultaneously updating progress bars/spinners? I don’t think ProgressMeter can do that but that is a feature I would definitely use if it were to be added.
