How To Install python-bunch on CentOS 7
Introduction
In this tutorial we learn how to install python-bunch
on CentOS 7.
What is python-bunch
python-bunch provides a python class which can perform as a dict whose keys are also accessible as attributes, similar to JavaScript objects. For instance »> import bunch »> people = bunch.Bunch({‘alice’ »> print people[‘alice’], people.alice here here The piece of python-bunch that sets it apart from similar modules found inside other projects is the bunchify() function which recursively converts from a dict to a Bunch »> multi_level = {‘array’ recursion’} ]} »> bunch.bunchify(multi_level) Bunch(array=[‘scalar’, Bunch(mapping=‘to show recursion’)])
We can use yum
or dnf
to install python-bunch
on CentOS 7. In this tutorial we discuss both methods but you only need to choose one of method to install python-bunch.
Install python-bunch on CentOS 7 Using yum
Update yum database with yum
using the following command.
After updating yum database, We can install python-bunch
using yum
by running the following command:
Install python-bunch on CentOS 7 Using dnf
If you don’t have dnf installed you can install DNF on CentOS 7 first.
Update yum database with dnf
using the following command.
After updating yum database, We can install python-bunch
using dnf
by running the following command:
How To Uninstall python-bunch on CentOS 7
To uninstall only the python-bunch
package we can use the following command:
References
Summary
In this tutorial we learn how to install python-bunch
on CentOS 7 using yum
and dnf
.