6

我正在关注Trigger.io Forge 教程,但无法从 OSX 10.8 上的命令行正常工作。

使用终端和 Forge 教程,我转到 forge-workspace 文件夹并将其输入到终端中:

$HOME/Library/Trigger\ Toolkit/forge create 

把这个拿回来:

Matts-MacBook-Pro:forge-workspace mattm$ $HOME/Library/Trigger\ Toolkit/forge create
[   INFO] Forge tools running at version 3.3.17
[   INFO] Update result: you already have the latest tools

This name is what your application will be called on devices. You can change it later     through config.json.
App Name: Weather App
[   INFO] Registering new app "Weather App" with trigger.io...
[   INFO] Fetching initial project template
[   INFO] Building app for the first time...
[   INFO] Update result: you already have the latest tools
[   INFO] App structure created. To proceed:
[   INFO] 1) Put your code in the "src" folder
[   INFO] 2) Run forge build to make a build
[   INFO] 3) Run forge run to test out your build
Matts-MacBook-Pro:forge-workspace mattm$ 

教程说:

此时,您应该打开一个命令终端,如下所示:

(forge-environment)

但这并没有出现。另外,当我查看我的库目录(并进行系统范围的搜索)时,我没有看到任何标记为 Trigger 的文件夹。

当我尝试按照教程指导并执行诸如使用 forge create 命令之类的操作时,什么也没有发生:

Matts-MacBook-Pro:hello-world mattm$ forge create</p>
-bash: forge: command not found

Matts-MacBook-Pro:hello-world mattm$ $forge create</p>
-bash: create: command not found

在你问之前,是的,我安装了 Python,并且能够使用 Forge 浏览器界面构建和运行应用程序。

知道我错过了什么吗?

4

2 回答 2

10

在 Mac OS X 上,将以下内容添加到您的 bash 配置文件中

export PATH=$PATH:/Applications/TriggerToolkit.app/Contents/MacOS/
于 2013-01-07T00:03:16.513 回答
2

我已将更新推送到入门文档以澄清这一点: http: //docs.trigger.io/en/v1.4/getting-started.html#getting-started-with-the-command-line-tools

不再需要寻找“(伪造环境)”。如果您将 forge 可执行文件的路径添加到您的 PATH 中,那么您将能够按照您的尝试运行这些命令。

于 2012-10-03T01:29:25.120 回答