Skip to content
Merged
69 changes: 69 additions & 0 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,69 @@
version: 2.1
orbs:
node: circleci/node@5
commands:
deploy_npm:
steps:
- run:
# This assumes the git user info is already configured
name: Deploy to NPM
command: |
export RELEASE_VERSION="0.11.$(date +%Y%m%d%H%M%S)"
if [[ "$CIRCLE_BRANCH" == hotfix/* ]]; then
export NPM_TAG=hotfix
else
export NPM_TAG=latest
fi
echo "Deploying version $RELEASE_VERSION to $NPM_TAG"
npm --no-git-tag-version version $RELEASE_VERSION
npm set //registry.npmjs.org/:_authToken=$NPM_TOKEN
npm publish --tag $NPM_TAG
if npm info | grep -q $RELEASE_VERSION; then
git tag $RELEASE_VERSION
git push \
https://${GH_TOKEN}@github.com/${CIRCLE_PROJECT_USERNAME}/${CIRCLE_PROJECT_REPONAME}.git \
$RELEASE_VERSION
fi

jobs:
default:
docker:
- image: circleci/node:10-browsers # TODO: switch to cimg/node:* after upgrading gulp
steps:
- checkout
- run: git submodule update --init --recursive
- run:
name: Setup
command: |
sudo apt update
sudo apt install libgif-dev
TRAVIS_BRANCH="${CIRCLECI_BRANCH}" travis/setup-git.sh # Configure git user info
travis/install-assets.sh
npm set progress=false
which gulp || sudo npm install -g gulp-cli
- node/install-packages
- run: gulp jshint
- run: gulp minify
- run: gulp test
- run: gulp zip
- when:
condition:
or:
- equal: [ master, <<pipeline.git.branch>> ]
- equal: [ develop, <<pipeline.git.branch>> ]
- matches: { pattern: "^hotfix.*", value: <<pipeline.git.branch>> }
- matches: { pattern: "^release.*", value: <<pipeline.git.branch>> }
steps:
- run:
name: travis/deploy-prebuilt.sh
command: |
TRAVIS_TAG="${CIRCLE_TAG}" TRAVIS_COMMIT="${CIRCLE_SHA1}" travis/deploy-prebuilt.sh
- deploy_npm
workflows:
version: 2
default:
jobs:
- default:
context:
- dockerhub-credentials
- scratch-npm-creds
58 changes: 0 additions & 58 deletions .travis.yml

This file was deleted.

8 changes: 7 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,10 @@
# Paper.js - The Swiss Army Knife of Vector Graphics Scripting [![Build Status](https://travis-ci.org/paperjs/paper.js.svg?branch=develop)](https://travis-ci.org/paperjs/paper.js) [![NPM](https://img.shields.io/npm/v/paper.svg)](https://www.npmjs.com/package/paper)
# Scratch's fork of Paper.js [![Build Status](https://circleci.com/gh/LLK/paper.js.svg?style=shield)](https://app.circleci.com/pipelines/github/LLK/paper.js?branch=develop) [![NPM](https://img.shields.io/npm/v/@scratch/paper.svg)](https://www.npmjs.com/package/@scratch/paper)

This is a fork of Paper.js for use in Scratch. Please do not contact the Paper.js authors to support this fork.

_Original README.md below_

# Paper.js - The Swiss Army Knife of Vector Graphics Scripting

If you want to work with Paper.js, simply download the latest "stable" version
from [http://paperjs.org/download/](http://paperjs.org/download/)
Expand Down
Loading