本文介绍了清除 IISExpress 缓存的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试从 powershell 中清除 IISExpress 缓存.使用此代码它会抱怨列表.

"C:Program Files (x86)IIS Expressappcmd.exe" 列出站点/xml |appcmd 删除站点/in

如何清除站点和 IIS Express 缓存?

在行:1 字符:50+ "C:Program Files (x86)IIS Expressappcmd.exe" 列出站点/xml |应用程序 ...+ ~~~~表达式或语句中出现意外标记列表".+ CategoryInfo : ParserError: (:) [], ParentContainsErrorRecordException+ FullQualifiedErrorId : UnexpectedToken
解决方案

打开 CMD prompt &导航到 IIS express - 键入以下内容

cd "C:Program Files (x86)IIS Express";

运行这个appcmd.exe 列出站点/xml |appcmd 删除站点/in

这将删除所有网站,尽情享受吧!

更新PowerShell 版本 感谢@sibbij

cd "C:Program Files (x86)IIS Express";

运行这个./appcmd.exe 列出站点/xml |./appcmd 删除站点/in

I am trying to clear up the IISExpress Cache from the powershell. Using this code it complains about the list.

"C:Program Files (x86)IIS Expressappcmd.exe" list site /xml | appcmd delete site /in

How can I clear up the sites and the IIS Express cache?

At line:1 char:50
+ "C:Program Files (x86)IIS Expressappcmd.exe"  list site /xml | app ...
+                                                  ~~~~
Unexpected token 'list' in expression or statement.
    + CategoryInfo          : ParserError: (:) [], ParentContainsErrorRecordException
    + FullyQualifiedErrorId : UnexpectedToken
解决方案

Open CMD prompt & Navigate to IIS express - by typing the following

This will delete all the sites, enjoy!

Update for PowerShell Version Thanks to @sibbij

这篇关于清除 IISExpress 缓存的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

06-09 19:50