Ubuntu on Windows 10 - using Command line
1
1
Entering edit mode
2.7 years ago
WUSCHEL ▴ 750

I am from a Biology background. To learn command line, GitHub, and Linux I have installed Ubuntu on Windows 10 laptop.

When I run the app message pop-up

To run a command as administrator (user "root"), use "sudo <command>".
See "man sudo_root" for details.

name@LAPTOP-xxxxx:

when I look the location running ~$ pwd

it shows /home/name

  1. Using the ubuntu app — how can I move to D drive and different folders in D drive?

  2. Also, what is the difference between running Ubuntu on Windows and Windows Command Prompt (cmd.exe)? Are they similar?

  3. Can I run command line script on Ubuntu and cmd?

I tried to Google these. however unable to find a friendly answer.

I would be grateful if someone shares what is happening when running Ubuntu on Windows and any relevant tutorial if possible.

Commandline Linux Git Ubuntu • 1.1k views
ADD COMMENT
3
Entering edit mode
2.7 years ago

Windows drives are mounted under /mnt, for example:

ls /mnt/c

The Linux subsystem can be thought of as a separate, simulated Linux environment.

You cannot run Linux commands on Windows. But because the Linux is simulated within Windows, you can start some Windows programs from it. For example typing:

explorer.exe . 

in the Linux bash, will open a Windows Explorer instance that shows the current linux directory. Very handy shortcut.

Or, if you have Visual Studio Code you can start it from the Linux Subsystem just by typing code. The newly opened Visual Code editor runs in Windows, but it is connected to Linux, code that is executed from the editor will run under Linux.

In general you should think of the two as separate environments that only share files.

ADD COMMENT
0
Entering edit mode

Thanks a heap, Prof.

ADD REPLY

Login before adding your answer.

Traffic: 2665 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6