عند تحديث أو استبدال جهاز كمبيوتر منزلي ، أستخدم Windows Deployment Services (WDS) لإعادة تثبيت Windows. هذا يعني أنه يجب علي فقط الاحتفاظ بمصدر واحد محدث لجميع التطبيقات المجانية الصغيرة التي أستخدمها (النار الثعلب, 7الرمز البريدي, فهرس, إلخ) ويجعل الإعداد الجديد أكثر إيلاما. أحد الأخطاء القليلة التي أغضبتني للأعمار هو أن خريطة محرك الشبكة التي أنشأتها كان يجب دائمًا إعادة تسميتها يدويًا.
I think the problem stems from the need for admin rights when renaming a drive. Whilst I can run the rename command as an administrator this seems to fail as the share isn’t present for the admin account, فقط لحساب المستخدم. What I would need to do is run the command as the user and then elevate it. I don’t know of any scripting way to do this, so the normal rename command seems a dead loss.
والخبر السار هو أن هناك طريقة للقيام إعادة تسمية عبر التسجيل, and registry changes can easily be made from the command line. لتعيين وتسمية حصة يتطلب فقط 2 الأوامر
ريج إضافة HKCU برامج مايكروسوفت ويندوز اكسبلورر MountPoints2 ##server-name#شارك الاسم /v _LabelFromReg /t REG_SZ /f /d “الاسم لاستخدامه للحصول على حصة"
استخدام صافي ذ: \\server-name\شارك الاسم /المستعمل:server-name\اسم المستخدم كلمة المرور /مستمر:نعم فعلا
This can be put in a simple batch file and duplicate for each share you want to map. Viola — no more ugly names for network shares


“Hi James I realise it has been a long while, but I just checked this on windows 11 (build 23H2)…”