Ubuntu 20.04 and OneDrive

Help Please! I am in the process of establishing my OneDrive connection to my Ubuntu 20.04.2 server. After installing the dependencies, I then attempted to unpack and run a binary file using the following command:

sudo dpkg -i dmd_2.093.1-0_amd64.deb

I received the following output:

    (Reading database ... 150962 files and directories currently installed.)
    Preparing to unpack dmd_2.093.1-0_amd64.deb ...
    Unpacking dmd (2.093.1-0) ...
    dpkg: error processing archive dmd_2.093.1-0_amd64.deb (--install):
     trying to overwrite '/usr/bin/dub', which is also in package dub 1.26.0-0
    dpkg-deb: error: paste subprocess was killed by signal (Broken pipe)
    Processing triggers for shared-mime-info (1.15-1) ...
    Processing triggers for gnome-menus (3.36.0-1ubuntu1) ...
    Processing triggers for desktop-file-utils (0.24-1ubuntu3) ...
    Processing triggers for mime-support (3.64ubuntu1) ...
    Processing triggers for man-db (2.9.1-1) ...
    Processing triggers for hicolor-icon-theme (0.17-2) ...
    Processing triggers for libc-bin (2.31-0ubuntu9.2) ...
    Errors were encountered while processing:
     dmd_2.093.1-0_amd64.deb

What can I do to eliminate the install errors? What have I missed?


You previously installed the dub 1.26.0-0 package, which contained /usr/bin/dub. How?

Your attempt to install dmd from the .deb file also contained /usr/bin/dub (same? different?), so dpkg didn't overwrite the original /usr/bin/dub.

Read the error message.

Uninstall dub and try again.

Rather than downloading .deb files from unofficial sources, I suggest that you use Ubuntu packages. Read man apt apt-get apt-cache synaptic.