آموزش cmd :
چون تایپ ده انگشتی فارسی سریع بلد نیستم انگلیسی نوشتم . زبانش ساده است و دستورات اصلی رو شامل میشه.
author: Mojtaba Eshghi
cmd(command prompt) is a way to communicate to your OS(operating system)
it's like the command shell for linux
آموزش cmd;
نویسنده : مجتبی عشقی
cmd(command prompt) is a way to communicate to your OS(operating system)
it's like the command shell for linux.
rem
used to add a comment to your script,example;
C:\Users>rem here is my teritory
cd
return to your previous directory(or go to next directory)
or just to see what your path is.examples;
C:\Users>cd shows us what path we are in
C:\Users rem out put
cd..
step back to the previous directory like;
C:\Users\assembler>cd..
C:\Users>
cd
can use it to go to a new directory like below;
C:\Users>cd assembler
C:\Users\assembler>
C:\Users\assembler>cd G:\Java\Eclipse
G:\Java\Eclipse>
dir
used to see what is in which direcory,example;
G:\Java\Eclipse>dir c:
Volume in drive C is 240GB-logical NTFS
Volume Serial Number is A612-F402
Directory of C:\Users\assembler
10/12/2011 02:45 PM <DIR> .
10/12/2011 02:45 PM <DIR> ..
10/12/2011 03:24 PM <DIR> .idlerc
10/10/2011 01:08 AM <DIR> Contacts
10/12/2011 07:42 PM <DIR> Desktop
10/10/2011 01:56 AM <DIR> Documents
10/10/2011 03:33 AM <DIR> Downloads
10/10/2011 01:08 AM <DIR> Favorites
10/12/2011 04:13 AM 67 JESConfig.txt
10/10/2011 01:08 AM <DIR> Links
10/10/2011 11:08 AM <DIR> Music
10/12/2011 08:19 PM <DIR> Pictures
10/10/2011 01:08 AM <DIR> Saved Games
10/10/2011 03:13 AM <DIR> Searches
10/10/2011 01:08 AM <DIR> Videos
1 File(s) 67 bytes
14 Dir(s) 12,081,426,432 bytes free
dir /a
used to access all of files in the directory, like;
G:\Java\Eclipse>dir /a
Volume in drive G is 240GB-logical NTFS
Volume Serial Number is C611-2FFF
Directory of G:\Java\Eclipse
10/03/2011 10:24 AM <DIR> .
10/03/2011 10:24 AM <DIR> ..
06/28/2007 10:44 AM 59 .eclipseproduct
10/03/2011 02:59 AM <DIR> configuratio
10/03/2011 02:59 AM <DIR> d
10/03/2011 02:59 AM <DIR> DATA
06/28/2007 10:44 AM 151,552 eclipse.exe
07/01/2007 11:39 PM 88 eclipse.ini
06/28/2007 10:44 AM 126,976 eclipsec.exe
06/28/2007 10:44 AM 16,536 epl-v10.html
10/03/2011 03:00 AM <DIR> features
06/28/2007 10:44 AM 6,506 notice.html
10/03/2011 03:00 AM <DIR> plugins
10/03/2011 03:01 AM <DIR> readme
10/03/2011 03:01 AM <DIR> workspace
6 File(s) 301,717 bytes
9 Dir(s) 19,989,315,584 bytes free
you can compare the results of these two commands
color
changes the color of the current cmd window, like in;
color 0a
help
documentation of some of cmd commands
help [command]
extravagant help on your desired command
exit
quits the current window
cls
clears the screan
title
sets the title to the expression you want, example;
title mojtaba eshghi
mkdir x
makes a folder called x in your current directory, example;
G:\>mkdir x
G:\>dir
Volume in drive G is 240GB-logical NTFS
Volume Serial Number is C611-2FFF
Directory of G:\
10/11/2011 12:59 AM <DIR> A_programmer's_biography
10/03/2011 03:10 AM <DIR> Java
10/12/2011 08:49 PM <DIR> x
0 File(s) 0 bytes
3 Dir(s) 19,989,315,584 bytes free
rd
removes your desired direction, like in;
G:\>rd x
G:\>dir
Volume in drive G is 240GB-logical NTFS
Volume Serial Number is C611-2FFF
Directory of G:\
10/11/2011 12:59 AM <DIR> A_programmer's_biography
10/03/2011 03:10 AM <DIR> Java
0 File(s) 0 bytes
2 Dir(s) 19,989,315,584 bytes free
rd /s
use this parameter when your folder is not empty and has some files to remove them also, example;
G:\g>dir g:
Volume in drive G is 240GB-logical NTFS
Volume Serial Number is C611-2FFF
Directory of G:\g
10/12/2011 08:52 PM <DIR> .
10/12/2011 08:52 PM <DIR> ..
10/12/2011 08:52 PM 11 image.jpg
1 File(s) 11 bytes
2 Dir(s) 19,989,315,584 bytes free
G:\g>cd..
G:\>rd /s g
g, Are you sure (Y/N)? y
G:\>dir
Volume in drive G is 240GB-logical NTFS
Volume Serial Number is C611-2FFF
Directory of G:\
10/11/2011 12:59 AM <DIR> A_programmer's_biography
10/03/2011 03:10 AM <DIR> Java
0 File(s) 0 bytes
2 Dir(s) 19,989,315,584 bytes free
del
deletes the files you want, example;
G:\>dir
Volume in drive G is 240GB-logical NTFS
Volume Serial Number is C611-2FFF
Directory of G:\
10/12/2011 08:53 PM 8 ansdf.png
10/11/2011 12:59 AM <DIR> A_programmer's_biography
10/03/2011 03:10 AM <DIR> Java
1 File(s) 8 bytes
2 Dir(s) 19,989,315,584 bytes free
G:\>del ansdf.png
G:\>dir
Volume in drive G is 240GB-logical NTFS
Volume Serial Number is C611-2FFF
Directory of G:\
10/11/2011 12:59 AM <DIR> A_programmer's_biography
10/03/2011 03:10 AM <DIR> Java
0 File(s) 0 bytes
2 Dir(s) 19,989,315,584 bytes free
copy
copies what you want, example;
G:\>copy caffee.jpg H:
1 file(s) copied.
G:\>dir H:
Volume in drive H is 150GB-LOGIC
Volume Serial Number is AAAD-5978
Directory of H:\
10/12/2011 08:54 PM 6 caffee.jpg
1 File(s) 6 bytes
0 Dir(s) 617,660,416 bytes free
time
it's for viewing or modifying the system time, command syntax;
time hh:mm:ss
tree
showes the folders, files and subfolders in your desired path in some graphical schema
نظرات شما عزیزان:
نوشته شده توسط رامان (متفکر) |
لينک ثابت
|چهار شنبه 3 اسفند 1390برچسب:آموزش کامند,داس,آموزش داس,command prompt, dos,|