我试图按照https://github.com/enricosada/fsharp-dotnet-cli-samples/wiki/Getting-Started#hello-world在我的 Mac 上开始使用 f# 和 dotnet core。
% mkdir helloworld % cd helloworld % dotnet new --lang "f#" 在 /Users/User/dotnet/helloworld 中创建了新的 F# 项目。 %ls Program.fs 项目.json
在这里,我已经可以看出,没有我遵循的教程中概述的 NuGet.Config。然后
% dotnet 还原 日志:恢复 /Users/User/dotnet/helloworld/project.json 的包... 日志:在 /Users/User/dotnet/helloworld/project.json 中恢复工具 'dotnet-compile-fsc' 的包... log :将锁定文件写入磁盘。路径:/Users/User/dotnet/helloworld/project.lock.json 日志:/Users/User/dotnet/helloworld/project.json log : 恢复在 2148 毫秒内完成。 % 点网运行 项目 helloworld (.NETCoreApp,Version=v1.1) 将被编译,因为缺少预期的输出 为 .NETCoreApp 编译 helloworld,Version=v1.1 找不到指定的框架“Microsoft.NETCore.App”,版本“1.0.0”。 - 检查应用程序依赖项并定位安装在以下位置的框架版本: /usr/local/share/dotnet/shared/Microsoft.NETCore.App - 安装了以下版本: 1.1.0 - 或者,安装框架版本“1.0.0”。 /usr/local/share/dotnet/dotnet compile-fsc @/Users/User/dotnet/helloworld/obj/Debug/netcoreapp1.1/dotnet-compile.rsp 返回退出代码 131 编译失败。 0 个警告 0 错误 经过时间 00:00:00.4439997
点网信息 说
% dotnet --info .NET 命令行工具 (1.0.0-preview2-1-003177) 产品信息: 版本:1.0.0-preview2-1-003177 提交 SHA-1 哈希:a2df9c2576 运行环境: 操作系统名称:Mac OS X 操作系统版本:10.12 操作系统平台:达尔文 RID:osx.10.12-x64