Help us understand the problem. What is going on with this article?

Travis CIを利用したnpmライブラリの継続的運用

Travis ログイン

$ travis login 

GitHubアカウントでログイン

npmログイン

$ npm login

npmjs.comのアカウントでログイン

.travis.yml

.travis.yml
language: node_js
node_js:
- 9.3.0
script:
- npm run build
deploy:
  provider: npm
  email: test@gmail.com
  on:
    tags: true
  api_key:
    secure: [暗号化された認証トークン]

Building a JavaScript and Node.js project

タグのコミットの場合のみデプロイが発火

  on:
    tags: true

トークンの暗号化

$ travis encrypt YOUR_API_KEY --add deploy.api_key
$ npm version patch
$ git push origin v1.0.1

package.jsonversionがインクリメントされ同時にコミットもされる。
pushすればデプロイ完了となる。

はまったところ

packaege.json

packaege.jsonnameに大文字が含まれているとpublishされない。
npm publish failed put 400; is invalid for new packages #15787

Why not register and get more from Qiita?
  1. We will deliver articles that match you
    By following users and tags, you can catch up information on technical fields that you are interested in as a whole
  2. you can read useful information later efficiently
    By "stocking" the articles you like, you can search right away
Comments
No comments
Sign up for free and join this conversation.
If you already have a Qiita account
Why do not you register as a user and use Qiita more conveniently?
You need to log in to use this function. Qiita can be used more conveniently after logging in.
You seem to be reading articles frequently this month. Qiita can be used more conveniently after logging in.
  1. We will deliver articles that match you
    By following users and tags, you can catch up information on technical fields that you are interested in as a whole
  2. you can read useful information later efficiently
    By "stocking" the articles you like, you can search right away
ユーザーは見つかりませんでした