LoginSignup
0
0

More than 1 year has passed since last update.

ASK CLI 環境構築

Posted at

 ゴール

  • ASK CLIのインストール
  • ASK CLIでプロジェクト作る
  • デプロイしてEcho Show 実機に反映

対象

スキル開発 基礎トレーニングシリーズを一通りやっていること。
nodeインストール済み

コンソールでやって慣れたので、そろそろCLIでやろうかなって人

環境

mac
ask version 2.22.4
node 14.15.1
Echo Show 5 実機

インストール

クイックスタート: Alexa Skills Kitコマンドラインインターフェース(ASK CLI)スタート
に沿って行う

$ npm install -g ask-cli
$ ask --version
2.22.4
$ ask configure
------------------------- Configuration Complete -------------------------
Here is the summary for the profile setup:
...

.ask/cli_config
っていうファイルができる

プロジェクト作成

ask newを使用

$ ask new
プロジェクト作成
? Choose the programming language you will use to code your skill:  NodeJS
? Choose a method to host your skill's backend resources:  Alexa-hosted skills
  Host your skill code by Alexa (free).
? Choose the default region for your skill:  us-east-1
? Please type in your skill name:  Hello World Skill
? Please type in your folder name for the skill project (alphanumeric):  HelloWo
rldSkill

作ったら言語が英語になった。最初から日本語で作りたいが、そのやり方がわからない。
とりあえず後からlocalesを変えている
https://qiita.com/makishy/items/52bd191e288c6b9dbe2f

作業ブランチ、デプロイ

スクリーンショット 2021-07-17 11.21.25.png

最初から3つのリモートブランチができている。

ブランチ名 概要
dev Alexa Consoleで見てる環境。masterにプッシュすると自動的に更新される
master stg環境。開発中はここにプッシュする。gitflowでいうところのdevelop
prod 本番反映用

基本的に作業するブランチはmaster。

反映、テストの流れ
1. masterで作業して、masterにプッシュ
2. 自動ビルドされて、devに反映されるのを待つ。(console側でみるのが早い)
3. consoleのテスト画面を使用

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0