为什么dart pub突然尝试在我的css文件夹中安装软件包? [英] Why is dart pub suddenly trying to install packages in my css folder?

查看:149
本文介绍了为什么dart pub突然尝试在我的css文件夹中安装软件包?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

Running pub update ...
Pub update failed, [1] Resolving dependencies...
DirectoryIOException: Directory listing failed, path = <longpath>/web/css/packages (OS Error: No such file or directory, errno = 2)

将会在pub突然尝试在我的css文件夹中寻找包。

Why would pub suddenly try to look for packages in my css folder?

推荐答案

您可以在deployable目录的任何子目录中的任何Dart文件中使用 package:

The short answer, pub puts symlinks into subdirectories to ensure that you can use package: in any Dart file in any subdirectory of a "deployable" directory.

c $ c> web 是可部署的,因为你可能会把所有的东西放到web服务器上,pub想让dart文件容易工作。

Because web is deployable in the sense that you'll likely take everything in web and throw it up on a web server, pub wants to make it easy for Dart files to work.

现在没有公约,所以pub采取乐观的方法,因为它不能预测你可能放置Dart文件的位置。

There are no conventions right now, so pub takes the optimistic approach because it can't anticipate where you might put Dart files.

无论如何,你不应该得到一个错误,所以这可能是一个错误。我只是试用一个全新的示例应用程序与 web / css pub install pub更新为我工作。

Regardless, you shouldn't get an error, so this might be a bug. I just tried it on a brand new sample app with a web/css and pub install and pub update worked for me.

您可以在 http://dartbug.com/new 您的操作系统的详细信息和 dart --version 的输出?非常感谢!

Can you please submit a bug at http://dartbug.com/new with details of your OS and the output of dart --version ? Many thanks!

这篇关于为什么dart pub突然尝试在我的css文件夹中安装软件包?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆