23 Şubat 2023 Perşembe

Windows dir komutu

Giriş
Linux'taki find komutunun Windows'taki karşılığı dir komutudur.

Örnek
Şöyle yaparız:
dir *.cpp *.h *.java /b/s
Örnek
dir komutunda aranacak dizin seçeneklerden önce veya sonra gelebilir.
dir /s /b "D:\FOLDER\*"
a seçeneği
Belli attribute'lara sahip olan dosyaları gösterir. Örnekte sadece jpg olan dosyaların sayısı bulunur. Attribute olarak -d vererek dizinler atlanır.
Dir /b /a-d *.jpeg | find /c ".jpeg"
b seçeneği
bare format kullanır yani sadece dosya ismi+uzantısı veya dizin ismi şeklindedir.Çıktı da header yoktur. Eğer /s seçeneği ile kullanılırsa dizin ve dosyalar alt dizinler de dahil edildiği için full path olarak gösterilir.

s seçeneği
Bence recursive olarak adlandırılmalıydı.

15 Şubat 2023 Çarşamba

Powershell Get-PnpDevice - Plug And Play

Örnek
Şöyle yaparız
Get-PnpDevice -PresentOnly -Class Camera


Status     Class    FriendlyName      InstanceId
------     -----    ------------  ----------
OK         Camera   Integrated Webcam  USB\VID_0C45...
OK         Camera   Integrated Webcam  USB\VID_0C45...
OK         Camera   Elgato Facecam     


Windows pnputil komutu - Plug And Play

Örnek
Şöyle yaparız
pnputil /enum-devices /class Camera /connected
Çıktısı şöyle
Microsoft PnP Utility

Instance ID:                USB\VID_0C45&PID_672E&MI_02\6&3d846a0&0&0002
Device Description:         Integrated Webcam
Class Name:                 Camera
Class GUID:                 {ca3e7ab9-b4c3-4ae6-8251-579ef933890f}
Manufacturer Name:          Microsoft
Status:                     Started
Driver Name:                usbvideo.inf

Instance ID:                USB\VID_0C45&PID_672E&MI_00\6&3d846a0&0&0000
Device Description:         Integrated Webcam
Class Name:                 Camera
Class GUID:                 {ca3e7ab9-b4c3-4ae6-8251-579ef933890f}
Manufacturer Name:          Microsoft
Status:                     Started
Driver Name:                usbvideo.inf

Instance ID:                USB\VID_0FD9&PID_0078&MI_00\8&e3fc9d&0&0000
Device Description:         Elgato Facecam
Class Name:                 Camera
Class GUID:                 {ca3e7ab9-b4c3-4ae6-8251-579ef933890f}
Manufacturer Name:          Microsoft
Status:                     Started
Driver Name:                usbvideo.inf


20 Ekim 2022 Perşembe

Powershell Set-Location - Change Directory İçindir

Örnek
Şöyle yaparız
$currentDir = Get-Location # Save for setting back later
Set-Location ...
...
Set-Location $currentDir


4 Ekim 2022 Salı

Windows msiexec komutu

/i seçeneği
Örnek
Şöyle yaparız
C:\> msiexec.exe /i https://awscli.amazonaws.com/AWSCLIV2.msi

3 Ekim 2022 Pazartesi

Oturum Açma Seçenekleri

Giriş
How to Remove PIN and Password on Lock Screen with Local Account.Without Programs videosundan öğrendim. Ayarlar/Hesaplar veya Settings/Accounts menüsünden Parola veya Password kaldırılıyor






15 Eylül 2022 Perşembe

Windows mountvol komutu

/p seçeneği - remove the volume
Örnek
Şöyle yaparız
1. Enter mountvol to list all the volumes. D should look something like -
   \\?\Volume{b77a3ed1-0651-5gdf-90b1-d1a3672d96e4}\
        D:\
You should remember which one was D for later.

2. Enter mountvol D: /p which will unmount D.
3. Enter diskpart
4. Enter list volume and note volume D's index in the ### column. Let's say it's 1.
5. Enter sel vol 1 to select volume D.
6. Enter att vol set readonly yo make D read only.
7. Enter det vol to see the volume's info and confirm that D is now read only.
8. Enter exit to go back to the command prompt.
9. Enter mountvol D: \\?\Volume{b77a3ed1-0651-5gdf-90b1-d1a3672d96e4}\ to remount D. Of course, replace the gibberish address from this example with the one you have listed in mountvol.
10. reboot.