2016-04-05 6 views
0

私は様々な回答を見てきましたが、私の特定の問題の解決方法を判断できないようです。私はMacBook Air(10.7.5)にnode.jsをインストールしました。私はバワーを設置しました。すべて成功した。ブートストラップをインストールしようとすると、次のエラーが表示されます。Mac OSでbower install -g(gitをインストール済み)でブートストラップをインストールする際に問題が発生する

$ bower install -g bootstrap 

bower not-cached git://github.com/twbs/bootstrap.git#* 

bower resolve  git://github.com/twbs/bootstrap.git#* 

bower ENORESTARGET Tag/branch master does not exist 

Additional error details: 

No tags found in git://github.com/twbs/bootstrap.git 

No branches found in git://github.com/twbs/bootstrap.git 


# The following command works: 

$ which git 

/usr/local/bin/git 


# I tried this (some suggestion from another post): 

$ git clone https://github.com/git/git 

Illegal instruction: 4 

何か助けてください。ありがとう

答えて

0

通常、プロジェクトのディレクトリ内にバウアーをインストールします。あなたはすでに完了しているバワーをインストールすることから始めます。次に、bower initを使用してプロジェクトで初期化します。

$ bower init 
? name test 
? description bla bla some 
? main file 
? what types of modules does this package expose? 
? keywords 
? authors Haroen Viaene <[email protected]> 
? license MIT 
? would you like to mark this package as private which prevents it from being accidentally published to the registry? (y/N) y 
{ 
    name: 'test',y? (y/N) 
    authors: [ 
    'Haroen Viaene <[email protected]>' 
    ], 
    description: 'bla bla some', 
    main: '', 
    moduleType: [], 
    license: 'MIT', 
    homepage: '', 
    ignore: [ 
    '**/.*', 
    'node_modules', 
    'bower_components', 
    'test', 
    'tests' 
    ] 
} 

? Looks good? Yes 

次にあなたがbower install --save bootstrapを行うことによってbootstrapをインストールすることができます。これは次のようになります。今bootstrapがあなたのbower_componentsフォルダにインストールする必要があります

$ bower install --save bootstrap 
bower cached  git://github.com/twbs/bootstrap.git#3.3.6 
bower validate  3.3.6 against git://github.com/twbs/bootstrap.git#* 
bower cached  git://github.com/jquery/jquery-dist.git#2.2.2 
bower validate  2.2.2 against git://github.com/jquery/jquery-dist.git#1.9.1 - 2 
bower install  bootstrap#3.3.6 
bower install  jquery#2.2.2 

bootstrap#3.3.6 bower_components/bootstrap 
└── jquery#2.2.2 

jquery#2.2.2 bower_components/jquery 

:これは次のようになります。

+0

私はプロジェクトのディレクトリにbowerをインストールし、bower initを実行しました。すべてうまくいった。それから私はバウアーでブートストラップをインストールしようとしました。だから私はgitをインストールし、再試行し、上記のエラーを持っています。その後、別の投稿を見て、私はbowerをアンインストールしました(gitの前にインストールされていたので)。その後、私はバワーを再インストールし、初期化を行った。その後、再びブートストラップのインストールを試みましたが、同じメッセージが表示されます。 –

+0

これは試しましたか? http://stackoverflow.com/q/24234063/3185307( '.git /'、 '.gitignore'と' .gitattributes'の内容を削除します –

関連する問題