'zypper: no repositories defined

The environment is: Ubuntu 20 sub-system in win10. When I run: sudo zypper install -t pattern devel_C_C++. It reported: Warning: No repositories defined. Operating only with the installed resolvables. Nothing can be installed.

How can I fix this problem.



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source