Ember-CLI无法解析Ember 2.0

时间:2015-08-24 17:10:19

标签: ember.js bower ember-cli

我使用ember-cli v1.13.8创建了一个全新的项目。

我创建了一个新项目,然后为Ember 2.0调整了bower.json文件(它目前配置为Ember 1.13.8)。运行bower install ember@2.0.0

后,我收到以下错误消息
bower ember-data#2.0.0          cached https://github.com/components/ember-data.git#2.0.0
bower ember-data#2.0.0        validate 2.0.0 against https://github.com/components/ember-data.git#2.0.0
bower                        ENOTFOUND Package ember@2.0.0 not found

我也尝试bower install ember#2.0.0并收到此错误(此处发布了部分消息):

bower ember#2.0.0              extract archive.tar.gz
bower ember#2.0.0              extract archive.tar.gz
bower ember#2.0.0         invalid-meta ember is missing "ignore" entry in bower. json
bower ember#2.0.0             resolved https://github.com/components/ember.git#2 .0.0
bower ember#2.0.0         invalid-meta ember is missing "ignore" entry in bower. json
bower ember#2.0.0             resolved https://github.com/components/ember.git#2 .0.0
bower                        ECONFLICT Unable to find suitable version for ember

知道我的配置有什么问题吗?令人失望的是,它开箱即用。

安德鲁

以下是我的配置文件....

package.xml中

   {
      "name": "ars-app",
      "version": "0.0.0",
      "description": "Small description for ars-app goes here",
      "private": true,
      "directories": {
        "doc": "doc",
        "test": "tests"
      },
      "scripts": {
        "build": "ember build",
        "start": "ember server",
        "test": "ember test"
      },
      "repository": "",
      "engines": {
        "node": ">= 0.10.0"
      },
      "author": "",
      "license": "MIT",
      "devDependencies": {
        "broccoli-asset-rev": "^2.1.2",
        "ember-cli": "1.13.8",
        "ember-cli-app-version": "0.5.0",
        "ember-cli-babel": "^5.1.3",
        "ember-cli-content-security-policy": "0.4.0",
        "ember-cli-dependency-checker": "^1.0.1",
        "ember-cli-htmlbars": "0.7.9",
        "ember-cli-htmlbars-inline-precompile": "^0.2.0",
        "ember-cli-ic-ajax": "0.2.1",
        "ember-cli-inject-live-reload": "^1.3.1",
        "ember-cli-qunit": "^1.0.0",
        "ember-cli-release": "0.2.3",
        "ember-cli-sri": "^1.0.3",
        "ember-cli-uglify": "^1.2.0",
        "ember-data": "2.0.0",
        "ember-disable-proxy-controllers": "^1.0.0",
        "ember-export-application-global": "^1.0.3"
      }
    }

bower.json

{
  "name": "ars-app",
  "dependencies": {
    "ember": "2.0.0",
    "ember-cli-shims": "ember-cli/ember-cli-shims#0.0.4",
    "ember-cli-test-loader": "ember-cli-test-loader#0.1.3",
    "ember-data": "2.0.0",
    "ember-load-initializers": "ember-cli/ember-load-initializers#0.1.5",
    "ember-qunit": "0.4.9",
    "ember-qunit-notifications": "0.0.7",
    "ember-resolver": "~0.1.18",
    "jquery": "^1.11.3",
    "loader.js": "ember-cli/loader.js#3.2.1",
    "qunit": "~1.18.0"
  }
}

以下是运行bower info ember

的结果
$ bower info ember
bower ember#*                   cached https://github.com/components/ember.git#2.0.1
bower ember#*                 validate 2.0.1 against https://github.com/components/ember.git#*

{
  name: 'ember',
  version: '2.0.1',
  main: [
    './ember.debug.js',
    './ember-template-compiler.js'
  ],
  dependencies: {
    jquery: '>= 1.7.0 < 2.2.0'
  },
  homepage: 'https://github.com/components/ember'
}

Available versions:
  - 2.1.0-beta.2
  - 2.1.0-beta.1
  - 2.0.1
  - 2.0.0
  - 2.0.0-beta.5
  - 2.0.0-beta.4
  - 2.0.0-beta.3
  - 2.0.0-beta.2
  - 2.0.0-beta.1
  - 1.13.9
  - 1.13.8
  - 1.13.7
  - 1.13.6
  - 1.13.5
  - 1.13.4
  - 1.13.3
  - 1.13.2
  - 1.13.1
  - 1.13.0
  - 1.13.0-beta.2
  - 1.13.0-beta.1
  - 1.12.1
  - 1.12.0
  - 1.12.0-beta.3
  - 1.12.0-beta.2
  - 1.12.0-beta.1
  - 1.11.3
  - 1.11.2
  - 1.11.1
  - 1.11.0
  - 1.11.0-beta.5
  - 1.11.0-beta.4
  - 1.11.0-beta.3
  - 1.11.0-beta.2
  - 1.11.0-beta.1
  - 1.10.1
  - 1.10.0
  - 1.10.0-beta.4
  - 1.10.0-beta.3
  - 1.10.0-beta.2
  - 1.10.0-beta.1
  - 1.9.1
  - 1.9.0
  - 1.9.0-beta.4
  - 1.9.0-beta.3
  - 1.9.0-beta.1
  - 1.8.1
  - 1.8.0
  - 1.8.0-beta.5
  - 1.8.0-beta.4
  - 1.8.0-beta.3
  - 1.8.0-beta.2
  - 1.8.0-beta.1
  - 1.7.1
  - 1.7.0
  - 1.7.0-beta.5
  - 1.7.0-beta.4
  - 1.7.0-beta.3
  - 1.7.0-beta.2
  - 1.7.0-beta.1
  - 1.6.1
  - 1.6.0
  - 1.6.0-beta.5
  - 1.6.0-beta.4
  - 1.6.0-beta.3
  - 1.6.0-beta.2
  - 1.6.0-beta.1
  - 1.5.1
  - 1.5.0
  - 1.5.0-beta.4
  - 1.5.0-beta.3
  - 1.5.0-beta.2
  - 1.5.0-beta.1
  - 1.4.0
  - 1.4.0-beta.6
  - 1.4.0-beta.5
  - 1.4.0-beta.4
  - 1.4.0-beta.3
  - 1.4.0-beta.2
  - 1.4.0-beta.1
  - 1.3.2
  - 1.3.1
  - 1.3.0
  - 1.3.0-beta.4
  - 1.3.0-beta.3
  - 1.3.0-beta.2
  - 1.3.0-beta.1
  - 1.2.2
  - 1.2.1
  - 1.2.0
  - 1.2.0-beta.4
  - 1.2.0-beta.3
  - 1.2.0-beta.2
  - 1.2.0-beta.1
  - 1.1.3
  - 1.1.2
  - 1.1.1
  - 1.1.0
  - 1.1.0-beta.4
  - 1.1.0-beta.2
  - 1.1.0-beta.1
  - 1.0.1
  - 1.0.0
  - 1.0.0-rc.8
  - 1.0.0-rc.7
  - 1.0.0-rc.6.1
  - 1.0.0-rc.6
  - 1.0.0-rc.5
  - 1.0.0-rc.4
  - 1.0.0-rc.3
  - 1.0.0-rc.2
  - 1.0.0-rc.1
  - 1.0.0-pre.4
  - 1.0.0-pre.2
  - 1.0.0-pre

更新:删除一些条目以查看条目之间是否存在依赖性冲突后,我发现了一些有趣的内容。如果我只删除这个单一条目"ember-load-initializers": "ember-cli/ember-load-initializers#0.1.5",那么bower就能成功安装ember#2.0.0。有谁知道ember-load-initializer依赖关系定义的问题?它似乎是ember-cli的一部分,仍然是版本1.13.8(截至今天)。

1 个答案:

答案 0 :(得分:0)

bower命令中存在语法错误。要指定版本,请使用#

bower install ember#2.0.0