How To Install ghc-HTTP on Fedora 36

In this tutorial we learn how to install ghc-HTTP in Fedora 36. ghc-HTTP is A library for client-side HTTP

Introduction

In this tutorial we learn how to install ghc-HTTP on Fedora 36.

What is ghc-HTTP

The HTTP package supports client-side web programming in Haskell. It lets you set up HTTP connections, transmitting requests and processing the responses coming back, all from within the comforts of Haskell. It’s dependent on the network package to operate, but other than that, the implementation is all written in Haskell. A basic API for issuing single HTTP requests + receiving responses is provided. On top of that, a session-level abstraction is also on offer (the ‘BrowserAction’ monad); it taking care of handling the management of persistent connections, proxies, state (cookies) and authentication credentials required to handle multi-step interactions with a web server. The representation of the bytes flowing across is extensible via the use of a type class, letting you pick the representation of requests and responses that best fits your use. Some pre-packaged, common instances are provided for ‘ByteString’ and ‘String’.

We can use yum or dnf to install ghc-HTTP on Fedora 36. In this tutorial we discuss both methods but you only need to choose one of method to install ghc-HTTP.

Install ghc-HTTP on Fedora 36 Using dnf

Update yum database with dnf using the following command.

sudo dnf makecache --refresh

After updating yum database, We can install ghc-HTTP using dnf by running the following command:

sudo dnf -y install ghc-HTTP

Install ghc-HTTP on Fedora 36 Using yum

Update yum database with yum using the following command.

sudo yum makecache --refresh

After updating yum database, We can install ghc-HTTP using yum by running the following command:

sudo yum -y install ghc-HTTP

How To Uninstall ghc-HTTP on Fedora 36

To uninstall only the ghc-HTTP package we can use the following command:

sudo dnf remove ghc-HTTP

ghc-HTTP Package Contents on Fedora 36

/usr/lib/.build-id
/usr/lib/.build-id/79
/usr/lib/.build-id/79/b424e9e75b028fd70d0693a0bf5ccce9c6c756
/usr/lib64/libHSHTTP-4000.3.16-JT8fqoprsca71Hyy9dbnyT-ghc8.10.5.so
/usr/share/licenses/ghc-HTTP
/usr/share/licenses/ghc-HTTP/LICENSE

References

Summary

In this tutorial we learn how to install ghc-HTTP on Fedora 36 using yum and [dnf]((/fedora/36/dnf/).