从github克隆后编译Twitter Bootstrap-输出在哪里? [英] Compiling Twitter Bootstrap after cloning from github - where is the output?
问题描述
Possible Duplicate:
twitter bootstrap make from source
我试图了解如何构建Twitter Bootstrap.似乎有两种方法可以访问Twitter Bootstrap.
I am trying to understand how to build Twitter Bootstrap. It seems that there are two ways to access Twitter Bootstrap.
The first is to download a bootstrap.zip
, available from http://twitter.github.com/bootstrap/assets/bootstrap.zip and then unzip it, which results in the following directory structure:
.
└── bootstrap/
├── css/
│ ├── bootstrap-responsive.css
│ ├── bootstrap-responsive.min.css
│ ├── bootstrap.css
│ └── bootstrap.min.css
├── img/
│ ├── glyphicons-halflings-white.png
│ └── glyphicons-halflings.png
└── js/
├── bootstrap.js
└── bootstrap.min.js
4 directories, 8 files
如果我理解正确,我所要做的就是将bootstrap
目录及其下的所有文件拖放到我的项目目录中,然后在我的HTML文件中包含一个类似于以下内容的标记:<link type="text/css" rel="stylesheet" href="location_of_my_twitter_bootstrap_file" />
If I understand correctly, all I would have to do is drop the bootstrap
directory and all the files underneath it, into my project directory and then, in my HTML file include a tag something like the following: <link type="text/css" rel="stylesheet" href="location_of_my_twitter_bootstrap_file" />
获取Twitter Bootstrap的第二方法是克隆github项目,然后使用make
进行构建.我已经安装了Node.js
,并且已经使用npm
安装了几个软件包,例如less
jshint
recess
uglify-js
和connect
.当我从引导目录运行make
命令时,它似乎可以正常工作,并且得到以下输出:
The second way to get Twitter Bootstrap is to clone the github project and then to use make
to build it. I have installed Node.js
and I have used npm
to install several packages, such as less
jshint
recess
uglify-js
and connect
. When I run the make
command from the bootstrap directory it seems to work and I get the following output:
##################################################
Building Bootstrap...
##################################################
Running JSHint on javascript... ✔ Done
Compiling LESS with Recess... ✔ Done
Compiling documentation... ✔ Done
Compiling and minifying javascript... ✔ Done
##################################################
Bootstrap successfully built at 09:36AM.
##################################################
Thanks for using Bootstrap,
<3 @mdo and @fat
但是,我没有一个具有与解压缩zip文件一样的目录结构的引导目录.而是更新了bootstrap/docs/assets
下的一堆文件,它们似乎与我从bootstrap.zip中获得的文件相对应(例如,还有更多).
However, I don't get a bootstrap directory with the same directory structure that unzipping the zip files gives me. Instead, a bunch of files under bootstrap/docs/assets
are updated, and they don't seem to correspond to the files I get from bootstrap.zip (there are many more of them, for instance).
我的问题是:克隆github项目提供了什么好处,像我一样使用make
的目的是什么,以及如何从Twitter Bootstrap源文件中干净地生成CSS和JS文件,我可以从中链接到该文件我的项目?
My question is: what advantage does cloning the github project offer, what is the purpose of using make
as I did, and how can I cleanly generate CSS and JS files from Twitter Bootstrap source files that I can link to from my project?
谢谢.
推荐答案
我知道了.问题是我只是在运行make
命令.仔细查看Makefile
之后,我意识到我需要运行make bootstrap
. (运行make
本身默认为make build
.)我运行make bootstrap
后,将创建一个包含所需文件的bootstrap
目录.
I figured it out. The problem was that I was just running the make
command. After looking closely at the Makefile
I realized that I needed to run make bootstrap
. (Running make
by itself defaults to make build
.) Once I ran make bootstrap
, a bootstrap
directory was created that contained the expected files.
这篇关于从github克隆后编译Twitter Bootstrap-输出在哪里?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!