Python 3 Script to Show Loading Bars, Spinners, and Custom Animations in the Terminal!
122 views
Jun 3, 2025
Get the full source code of application here:
View Video Transcript
0:00
uh hello guys uh welcome to this video
0:02
So in this video I will show you how to
0:04
show some basic animations inside your
0:07
terminal By default if you want to do
0:09
some animation it's not there So inside
0:12
Python there is a package you can use If
0:14
you want to do some basic animations
0:18
let's suppose show a loading bar If you
0:20
are requesting some data then you can
0:23
show some loading bar animation to your
0:25
user So the package name is very simple
0:29
Let me show you Uh simply type your
0:32
animation This is the package name It
0:36
provides you with
0:38
these cool little animations you can
0:41
have inside your terminal So simply
0:43
install this And after installing it let
0:46
me show you how to use
0:50
this So let me show you the demo here
0:53
Right here If you execute the script
0:56
right here you will see these animations
0:58
will appear This is the first animation
1:00
which is the waiting animation So if
1:02
you're requesting some data and then
1:05
this is the second type of animation
1:07
which is ellipse and then you have the
1:10
spinner animation which is going
1:12
on and this is another animation So
1:16
these are different animations supported
1:17
by this module So if you're requesting
1:20
some kind of data then you can show
1:22
these animations
1:26
So now to get started first of all you
1:28
just need to import the modules using
1:30
the import statement Then you also need
1:33
to import the time module and then we
1:35
will define a series of functions So
1:38
right here we will call these functions
1:41
in the main
1:43
function So one by one I will show you
1:46
all the functions So the first one is
1:49
the simple waiting animation So you
1:52
define this by add the rate and then
1:55
followed by animation and then simple
1:58
weight So this is a simple weight
2:00
animation We define the function right
2:02
here which will be
2:05
task with
2:08
ellipses So as you can see in this way
2:11
you can define this in the form of a
2:14
function So we sleep for 5 seconds So
2:17
for 5 seconds the animation will happen
2:21
and after that the print statement will
2:23
display So in this way you can request
2:26
some API data instead of sleeping for 5
2:29
seconds and then you can print out
2:32
this And same we have the bar animation
2:35
as well This is the bar animation You
2:38
can see
2:39
that again we sleep for 5 seconds Then
2:43
we have also the spinner animation like
2:46
this
2:50
So these are different methods available
2:52
for different animations Then we have
2:55
the custom wheel
2:57
animation So like this Then we have
3:02
this another colored
3:06
animation So these are different types
3:09
of animations supported in the terminal
3:12
So you can check out their module for
3:14
more information If I execute this you
3:17
will
3:29
see So thank you very much for watching
3:32
this video and also check out my website
3:35
freemediatools.com
3:37
uh which contains thousands of tools
#Animated Films
#Clip Art & Animated GIFs
#Comics & Animation
#Computers & Electronics
#Flash-Based Entertainment
#Fun & Trivia
#Movies
#Online Goodies
#Programming
#Scripting Languages