我在我的 Angular 8 项目上运行它:
ole@mkt:~/test$ ngh
index.html could not be copied to 404.html. This does not look like an angular-cli project?!
(Hint: are you sure that you have setup the directory correctly?)
Diagnostic info [Error: ENOENT: no such file or directory, stat '/home/ole/test/dist/index.html'] {
errno: -2,
code: 'ENOENT',
syscall: 'stat',
path: '/home/ole/test/dist/index.html'
}
Successfully published via angular-cli-ghpages! Have a nice day!
ole@mkt:~/test$ ls dist/
test
我得到了index.html
无法复制,看起来这是因为 Angular 生成构建文件dist/PROJECT_NAME
,在这种情况下,项目名称是test
.
我看起来 ngh 期望找到index.html
indist
而不是 in dist/test
。
关于如何解决这个问题的任何想法?