zoukankan      html  css  js  c++  java
  • 基于Node.js的ghost开源博客平台

    Ghost 是一套基于Node.js 构建的开源博客平台(Open source blogging platform),具有易用的书写界面和体验。

    1、安装node

    windows 下安装npm:http://blog.csdn.net/yczz/article/details/6938260

    第一步: 下载node.js的windows版
    当前最新版本是http://nodejs.org/dist/v0.5.10/node.exe

    第二步:设置环境变量
    把node.exe所在目录加入到PATH环境变量中。
    配置成功后可以在CMD中通过node --version 看到node.js对应的版本号
    C:Usersfn>node --version
    v0.5.10

    第三步: 安装git
    直接到以下地址(http://code.google.com/p/msysgit/downloads/list)下载git windows安装文,目前最新版是Git-1.7.7-preview20111014.exe,按照提示一步步安装即可。安装完成后把git安装bin目录加入PATH环境变量

    CMD中运行 git --version 确认安装是否成功

    C:Usersfn>git --version
    git version 1.7.7.msysgit.1
    第四步: 安装 npm
    在确保node.exe和git都在PATH环境变量中后执行以下命令:

    git config --system http.sslcainfo /bin/curl-ca-bundle.crt

    git clone --recursive git://github.com/isaacs/npm.git

    cd npm

    node cli.js install npm -gf
    下面来测试一下是否成功,一切OK开始Node.JS之旅
    D:develop odejshello>npm install -d
    npm info it worked if it ends with ok
    npm info using npm@1.0.103
    npm info using node@v0.5.10
    npm info preinstall application-name@0.0.1
    npm info addNamed [ 'jade', '>= 0.0.1' ]
    npm info addNamed [ 'express', '2.5.0' ]

    最好设置下国内镜像要不然下载会很慢
    github npm 撞墙的解决方案。

    github:
    代理服务器是必须的,我用的是本地的astrill
    给curl设置代理
    export http_proxy="127.0.0.1:3213"
    export https_proxy="127.0.0.1:3213"
    ok了

    npm:
    设置国内镜像 npm config set registry http://registry.npmjs.vitecho.com

    2、安装ghost

    参考地址:Installing Ghost on Windows

    Install and Run Ghost

    • In your start menu, find ‘Node.js’ and then choose ‘Node.js Command Prompt’
    • In the Node command prompt, you need to change directory to where you extracted Ghost. Type: cd Downloads/ghost-#.#.# (replace hashes with the version of Ghost you downloaded).
    • Next, in the command prompt type npm install --production note the two dashes
    • When npm is finished installing, type npm start to start Ghost in development mode
    • In a browser, navigate to 127.0.0.1:2368 to see your newly setup Ghost blog
    • Change the url to 127.0.0.1:2368/ghost and create your admin user to login to the Ghost admin.

    本人测试博客:https://halfwater.ghost.io/

  • 相关阅读:
    自动控制中的泛函分析(一)
    自动控制中的泛函分析(一)
    Andrew Ng机器学习课程15
    Andrew Ng机器学习课程14(补)
    Andrew Ng机器学习课程14(补)
    关于PADS的一些概念和实用技巧(一)
    关于PADS的一些概念和实用技巧(一)
    Andrew Ng机器学习课程14
    Andrew Ng机器学习课程14
    《数学之美》之计算复杂度
  • 原文地址:https://www.cnblogs.com/sdgf/p/4770737.html
Copyright © 2011-2022 走看看