cannot be loaded because running scripts is disabled on this system.

2024-05-10 09:48

本文主要是介绍cannot be loaded because running scripts is disabled on this system.,希望对大家解决编程问题提供一定的参考价值,需要的开发者们随着小编来一起学习吧!

问题:PowerShell:cannot be loaded because running scripts is disabled on this system.

情景

想建立个vue项目,执行vue create vueProg001时报错

在这里插入图片描述

解决

管理员PowerShell下输入

Set-ExecutionPolicy RemoteSigned

原因

如果使用Windows Server 2008 R2,则必须有x64和x86版本的PowerShell,这两个版本都必须设置其执行策略

作为管理员,您可以通过在PowerShell窗口中键入以下内容来设置执行策略:

Set-ExecutionPolicy RemoteSigned

有关更多信息,请参见使用Set-ExecutionPolicy Cmdlet。

在这里插入图片描述

PS

如果你不在管理员下输入的话,会报错
在这里插入图片描述
成功之后就可以打代码了
在这里插入图片描述

这篇关于cannot be loaded because running scripts is disabled on this system.的文章就介绍到这儿,希望我们推荐的文章对编程师们有所帮助!



http://www.chinasem.cn/article/976096

相关文章

Loaded plugins: fastestmirror, langpacks

https://blog.csdn.net/weixin_37282478/article/details/82152239

CS162 Operating System-lecture2

A tread is suspended or no longer executing when its state’s not loaded in registers the point states is pointed at some other thread .so the thread that’s suspended is actually siting in memory and

在WinCE的C#编程中,需要静态调用C++的动态库,需要添加using System.Runtime.InteropServices

using System.Runtime.InteropServices;         [DllImport("Win32DLL.dll", EntryPoint = "WriteREG_SZToRegTCHAR")]         private static extern bool WriteREG_SZToRegTCHAR(int iFlag, string regKeyP

c语言使用system函数后台运行python脚本

最近需要在c工程的mian函数中使用system函数调用一个shell脚本,shell脚本是用来将某些系统配置通过sock通信发送给主核进程,但是可能出现偶发性的配置失败情况,经过分析可以大概断定是由于sock通信的时候,主核进程正在忙于其他事物导致未能在expire之前将消息接受并处理,导致消息丢失,而发送方无法感知系统是否成功加载配置。         所以,需要在脚本的最后

java system.in问题

public static final InputStream in system关于in属性的定义InputStream是一个抽象类。抽象类本身是没有对象的,怎么可能用IN 属性调用reaad()方法?system.in.read();方法的解释 我想具体的知道是怎么得到这个 InputStream对象的。system方法中并没有给出定义。既然IN对象没有创建,有怎么可能调用IN方法?说起

JavaScripts数组里的对象排序的24个方法

1. 使用 Array.prototype.sort() 这是最基本、也是最常用的方法。sort() 方法会原地修改数组,并返回排序后的数组。你需要传入一个比较函数来定义排序逻辑。 const array = [{ name: 'Alice', age: 25 },{ name: 'Bob', age: 22 },{ name: 'Charlie', age: 30 }];// 按照年龄升序

MyEclipse:Errors occurred during the build. Errors running builder 'DeploymentBuilder' on project。

Errors occurred during the build. Errors running builder 'DeploymentBuilder' on project 'myf'. java.lang.NullPointerException 此问题一般发生在Myeclipse 保存文件并自动部署时候。 Errors occurred during the buil

JSP中System.out.println()与out.println()区别

out.println()输出到客户端。   在out.println()中,out是response的实例,是以response为对象进行流输出的,即将内容输出到客户端。如果在JSP页面中使用System.out.println(),在客户端只会输出一个空格。System.out.println()打印在控制台当中。    System.out.println()用的是标准输出流,这个是输出在

获取时间戳是使用System.currentTimeMillis()还是使用new Date().getTime()(阿里开发规范)?

1.阿里规范 在阿里的Java开发手册中强制要求使用System.currentTimeMillis() 2.为什么(源码详解) new Date().getTime()它实际上也是调用的System.currentTimeMillis(),源码分析。 这个fastTime是它的成员变量,在new Date()的时候就被赋值了。 扩展一下这个transient这个关键字,它是为了保护

IDEA 中 Maven 报错 Cannot resolve xxx(全网试完,亲测有效的方法汇总)

问题: pom中已经添加相关依赖,maven刷新也没有用,依旧是疯狂报错。 可能原因: 在IDEA中的pom文件中添加了依赖,并且正确加载了相应依赖,pom文件没有报红,看起来像是把所有依赖库全部加载进来了,但是代码中使用依赖的类库使报红。 在pom中添加了某个依赖,不会直接立刻马上将其下载并且添加到项目的external libraries中。只有在某个子模块的pom文件中也添加了