HTML5 样板构建脚本 - .htaccess 不存在

发布于 2024-10-24 19:32:34 字数 707 浏览 1 评论 0原文

我想我应该尝试一下 HTML5 Boilerplate 的构建脚本 - 它针对的是前端设计师和开发人员,所以这应该相当简单,对吧?

Paul 说,我用的是 Mac 跑步,所以我应该拥有我需要的一切。

在一个空白项目上尝试过,但立即碰壁了。

  1. 我运行 cd build 命令,将其指向我的本地文件夹
  2. 然后运行 ​​ant build。看起来一切顺利,有一堆关于如何构建生产环境的胡言乱语,但在寻找 htaccess 文件时陷入困境......

构建失败 /Users/jaygeorge/Dropbox/Websites/Clients/HTML-Sandbox/build/build.xml:137: 时发生以下错误 执行这一行: /Users/jaygeorge/Dropbox/Websites/Clients/HTML-Sandbox/build/build.xml:673: 替换:源文件 /Users/jaygeorge/Dropbox/Websites/Clients/HTML-Sandbox/publish/.htaccess 不存在

当然,.htaccess 文件不存在,因为它没有随 Boilerplate 下载一起提供。我是否需要从我的网站下载 htaccess 文件以便将其保存在本地?我不太明白这些东西 - 希望 Paul Irish 能让他的指示更全面:-(。

I thought I'd try out the Build Script for HTML5 Boilerplate - it's aimed at front-end designers and developers so this should be fairly straightforward right?

I'm running with a Mac so I should have all I need according to Paul.

Tried it on a blank project and immediately hit a brick wall.

  1. I ran the cd build command, pointing it to my local folder
  2. Then I ran ant build. It seemed to go OK, with a load of jibberish about how it was Building a Production environment but got stuck when looking for the htaccess file...

BUILD FAILED
/Users/jaygeorge/Dropbox/Websites/Clients/HTML-Sandbox/build/build.xml:137:
The following error occurred while
executing this line:
/Users/jaygeorge/Dropbox/Websites/Clients/HTML-Sandbox/build/build.xml:673:
Replace: source file
/Users/jaygeorge/Dropbox/Websites/Clients/HTML-Sandbox/publish/.htaccess
doesn't exist

Well of course the .htaccess file doesn't exist because it didn't come with the Boilerplate download. Do I need to download the htaccess file from my website so that it sits locally? I don't really understand this stuff - Was hoping Paul Irish would make his instructions more comprehensive :-(.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

你是暖光i 2024-10-31 19:32:34

您下载的 ZIP 文件的根文件夹中应该有一个 .htaccess 文件。请注意,您可能必须在文件资源管理器中打开“查看隐藏文件”或类似功能才能看到它。

There should be an .htaccess file in the root folder of the ZIP file you downloaded. Note that you may have to turn on 'view hidden files' or similar in your File Explorer to see it.

不再见 2024-10-31 19:32:34

尝试创建空的 .htaccess 文件并从以下位置复制/粘贴代码: http://html5boilerplate.com/

Try to make empty .htaccess file and copy/paste code from: http://html5boilerplate.com/

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文