Skip to content
This repository has been archived by the owner on Aug 18, 2020. It is now read-only.

Shizuoka-Oden/kuro-hanpen

Repository files navigation

kuro-hanpen

Circle CI

Setup

OS X

(Check OS X 10.11)

  1. Install Xcode

  2. Install Xcode Command Line Tools

  3. Install Node.js (4.2 or later)

Windows

(Check Windows 10 64bit)

  1. Install Download Microsoft Visual C++ Build Tools 2015 Technical Preview from Official Microsoft Download Center

    • Install both Windows 8.1 SDK & Windows 10 SDK
  2. Install Python 2.7 (recommend 2.7.10 or later)

  3. Install Node.js (4.2 or later, recommend 5.3 or later)

  4. Install Java Runtime

  5. Install & Run npm-windows-upgrade

    1. Launch Command Prompt

      npm install –g npm-windows-upgrade
    2. Launch Command Prompt as Administrator

      powershell
      Set-ExecutionPolicy Unrestricted -Scope CurrentUser -Force
      exit
      npm-windows-upgrade

      (Select latest version)

    3. Modify node-gyp (Japanese OS only?)

      diff -u "C:\Program Files\nodejs\node_modules\npm\node_modules\node-gyp\gyp\pylib\gyp\MSVSProject.py~" "C:\Program Files\nodejs\node_modules\npm\node_modules\node-gyp\gyp\pylib\gyp\MSVSProject.py"
      --- C:\Program Files\nodejs\node_modules\npm\node_modules\node-gyp\gyp\pylib\gyp\MSVSProject.py~	2015-12-29 12:24:00.794675900 +0900
      +++ C:\Program Files\nodejs\node_modules\npm\node_modules\node-gyp\gyp\pylib\gyp\MSVSProject.py	2015-12-29 12:24:11.192867300 +0900
      @@ -205,4 +205,4 @@
               ['Globals']  # empty section
           ]
           easy_xml.WriteXmlIfChanged(content, self.project_path,
      -                               encoding="Windows-1252")
      +                               encoding="ms932")
      diff -u "C:\Program Files\nodejs\node_modules\npm\node_modules\node-gyp\gyp\pylib\gyp\easy_xml.py~" "C:\Program Files\nodejs\node_modules\npm\node_modules\node-gyp\gyp\pylib\gyp\easy_xml.py"
      --- C:\Program Files\nodejs\node_modules\npm\node_modules\node-gyp\gyp\pylib\gyp\easy_xml.py~	2015-12-29 12:28:39.797529200 +0900
      +++ C:\Program Files\nodejs\node_modules\npm\node_modules\node-gyp\gyp\pylib\gyp\easy_xml.py	2015-12-29 12:28:43.738387400 +0900
      @@ -119,7 +119,7 @@
         try:
           xml_string = xml_string.encode(encoding)
         except Exception:
      -    xml_string = unicode(xml_string, 'latin-1').encode(encoding)
      +    xml_string = unicode(xml_string, 'shift_jis').encode(encoding)
       
         # Get the old content
         try:
  6. Launch Command Prompt (NOT as Administrator) and configure npm

    npm config set msvs_version 2015 --global

install

npm install

AWS 関連のアクセス情報設定ファイル作成 アクセスキーはIAM

cp aws.json.sample aws.json && vi $_

Gulp Tasks

task description
default ビルドを行い、dist に実行モジュールをコピーする
serve ローカル実行( dist にはコピーしない)
serve:dist dist にコピーしてローカル実行
upload dist 配下のファイルを全てS3へアップロード
es:regist data 配下のファイルを全てESへアップロード
test Karma でユニットテスト
test:auto Karma でユニットテスト in watch mode
protractor Protractor で E2E テスト
protractor:dist Protractor で E2E テスト on the dist files