How to obtain the names of all objects in batches using the doscommand

Source: Internet
Author: User

In windows, how does one use the doscommand to obtain the names of all files in a folder in batches? The following is a small Editor for you to operate.

1. Start --> Run --> Enter cmd and press enter to enter your path in the black box.

For example, f: \ 1 \ 2 \ 3 is input in the target path.

F: Press enter.

Cd \ 1 \ 2 \ 3 Press ENTER

2. Use tree or dir/w

Input: dir/w> c: \ temp.txt

3. Open my computer and access the C-root directory to view a temp.txt file. If it is a multi-level directory structure and you want to view the hidden file, try to enter:

Dir/w/a/s> c: \ temp.txt press ENTER

4. The specific operation project is as follows:

Microsoft Windows XP [version 5.1.2600]

(C) Copyright 1985-2001 Microsoft Corp.

C: \ Documents ents and Settings \ Administrator> f:

F: \> cd perl

F: \ perl> dir/w> c: \ temp.txt

F: \ perl>

Microsoft Windows XP [version 5.1.2600]

(C) Copyright 1985-2001 Microsoft Corp.

C: \ Documents ents and Settings \ Administrator> f:

F: \> cd perl

F: \ perl> dir/w> c: \ temp.txt

F: \ perl>

5. The result is as follows:

The volume in drive F is Trans

The serial number of the volume is 2009-9830

F: \ perl directory

[.]

[...]

A.csv

A. fasta

A. pl

B .csv

B. pl

C. pl

D. pl

D90.csv

DNA. maf

DNA .txt

E. pl

F.txt

G. pl

Join. pl

M. pl

[Magic.15012010]

Magic.15012010.tar.gz

Mokuaiceshichengshu. pl

N. pl

REBASE.txt

Result.csv

Result.txt

Result.xlsx

S288c_yjm789.snp

Sequence.txt

Sh. pl

Strawberry. gb

Strawberry1.gb

Test. pl

Yeast_set2.S288C.stampy.pe.recal.variants.filter.vcf

Yeast_set2.YJM789.stampy.pe.recal.variants.filter.vcf

[Save]

30 files, 270,744,642 bytes

4 directories, 7,031,603,200 available bytes

The volume in drive F is Trans

The serial number of the volume is 2009-9830

F: \ perl directory

[.]

[...]

A.csv

A. fasta

A. pl

B .csv

B. pl

C. pl

D. pl

D90.csv

DNA. maf

DNA .txt

E. pl

F.txt

G. pl

Join. pl

M. pl

[Magic.15012010]

Magic.15012010.tar.gz

Mokuaiceshichengshu. pl

N. pl

REBASE.txt

Result.csv

Result.txt

Result.xlsx

S288c_yjm789.snp

Sequence.txt

Sh. pl

Strawberry. gb

Strawberry1.gb

Test. pl

Yeast_set2.S288C.stampy.pe.recal.variants.filter.vcf

Yeast_set2.YJM789.stampy.pe.recal.variants.filter.vcf

[Save]

30 files, 270,744,642 bytes

4 directories, 7,031,603,200 available bytes

In linux, the operation is simpler:

You only need one command,

Ls> a.txt

Ls> a.txt

In this case, the result is output to the.txt file.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.