language: node_js sudo: required notifications: email: on_failure: always dist: xenial node_js: stable cache: - npm before_install: - export TZ='Asia/Shanghai' - openssl aes-256-cbc -K $encrypted_b7d8153e3775_key -iv $encrypted_b7d8153e3775_iv -in ./build/cxmooc-tools.pem.enc -out ./build/cxmooc-tools.pem -d - npm install script: - npm test - npm run docs:build - npm run build - npm run tampermonkey - npm run pack - cd build/cxmooc-tools && zip ../cxmooc-tools.zip -r ./ && cd ../../ deploy: - provider: releases api_key: $GITHUB_TOKEN file_glob: true file: - build/*.crx - build/*.zip skip_cleanup: true on: tags: true - provider: pages skip_cleanup: true committer-from-gh: true github_token: $GITHUB_TOKEN local_dir: docs/.vuepress/dist keep-history: true target-branch: gh-pages on: branch: master - provider: script script: node_modules/.bin/tsc src/internal/tg-bot.ts && node src/internal/tg-bot.js skip_cleanup: true on: branch: develop - provider: script script: node_modules/.bin/tsc src/internal/tg-bot.ts && node src/internal/tg-bot.js skip_cleanup: true on: tags: true - provider: npm email: $NPM_EMAIL api_key: $NPM_KEY on: tags: true