From b0720fae03710a91624fe229d2c782e1dec58877 Mon Sep 17 00:00:00 2001 From: Andrew Sliwinski Date: Fri, 18 Mar 2016 20:39:41 -0400 Subject: [PATCH 1/8] Update docs --- README.md | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 6242ffd9..ce2f5305 100644 --- a/README.md +++ b/README.md @@ -18,16 +18,18 @@ npm install scratch-parser #### Basic Use ```js var fs = require('fs'); -var scratchp = require('scratch-parser'); +var parser = require('scratch-parser'); var buffer = fs.readFileSync('/path/to/project.sb2'); -scratchp(buffer, function (err, project) { +parser(buffer, function (err, project) { if (err) // handle the error // do something interesting }); ``` ## Metadata +The `scratch-parser` module will append metadata about the project should validation and parsing be successful. The `_meta` object includes: + | Key | Attributes | | ----------------- | -------------------------------------------------------- | | `scripts` | `count` | From 3ebd5f662ca368b796a857dc2abf6db05881d8e4 Mon Sep 17 00:00:00 2001 From: Andrew Sliwinski Date: Mon, 19 Sep 2016 10:12:04 -0400 Subject: [PATCH 2/8] Update README to track travis-ci.org --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index ce2f5305..40d6eeb5 100644 --- a/README.md +++ b/README.md @@ -1,7 +1,7 @@ # scratch-parser #### Parser for Scratch projects -[![Build Status](https://travis-ci.com/LLK/scratch-parser.svg?token=xzzHj4ct3SyBTpeqxnx1&branch=master)](https://travis-ci.com/LLK/scratch-parser) +[![Build Status](https://travis-ci.org/LLK/scratch-parser.svg?branch=develop)](https://travis-ci.org/LLK/scratch-parser) [![Dependency Status](https://david-dm.org/llk/scratch-parser.svg)](https://david-dm.org/llk/scratch-parser) [![devDependency Status](https://david-dm.org/llk/scratch-parser/dev-status.svg)](https://david-dm.org/llk/scratch-parser#info=devDependencies) From b6479ca9cc5772fc959ced5fbbb715ba618c2e47 Mon Sep 17 00:00:00 2001 From: Andrew Sliwinski Date: Mon, 19 Sep 2016 10:16:16 -0400 Subject: [PATCH 3/8] Add license and trademark files for release --- LICENSE | 12 ++++++++++++ TRADEMARK | 7 +++++++ 2 files changed, 19 insertions(+) create mode 100644 LICENSE create mode 100644 TRADEMARK diff --git a/LICENSE b/LICENSE new file mode 100644 index 00000000..6d00c99e --- /dev/null +++ b/LICENSE @@ -0,0 +1,12 @@ +Copyright (c) 2016, Massachusetts Institute of Technology +All rights reserved. + +Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: + +1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. + +2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. + +3. Neither the name of the copyright holder nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. diff --git a/TRADEMARK b/TRADEMARK new file mode 100644 index 00000000..3e1ec5bf --- /dev/null +++ b/TRADEMARK @@ -0,0 +1,7 @@ +The Scratch trademarks, including the Scratch name, logo, the Scratch Cat, Gobo, Pico, Nano, Tera and Giga graphics (the "Marks"), are property of the Massachusetts Institute of Technology (MIT), and the use of the Marks is governed by this policy. + +You may use the Marks to refer to Scratch in Substantially Unmodified form. + +"Substantially Unmodified" means the source code provided by MIT, possibly with minor modifications including but not limited to: bug fixes (including security), changing the locations of files for better integration with the host operating system, adding documentation, and changes to the dynamic linking of libraries. + +A version is not "Substantially Unmodified" if it incorporates features not present in a release of Scratch by MIT. If you do make a substantial modification, to avoid confusion with versions of Scratch produced by MIT you must remove all Marks from your version of the software and refrain from using any of the Marks to refer to your version. From 688c9800d43d59dcb48371491df2f21849d1619f Mon Sep 17 00:00:00 2001 From: Andrew Sliwinski Date: Mon, 19 Sep 2016 10:19:24 -0400 Subject: [PATCH 4/8] Update david-dm badges --- README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 40d6eeb5..c03d04d5 100644 --- a/README.md +++ b/README.md @@ -2,8 +2,8 @@ #### Parser for Scratch projects [![Build Status](https://travis-ci.org/LLK/scratch-parser.svg?branch=develop)](https://travis-ci.org/LLK/scratch-parser) -[![Dependency Status](https://david-dm.org/llk/scratch-parser.svg)](https://david-dm.org/llk/scratch-parser) -[![devDependency Status](https://david-dm.org/llk/scratch-parser/dev-status.svg)](https://david-dm.org/llk/scratch-parser#info=devDependencies) +[![dependencies Status](https://david-dm.org/llk/scratch-parser/status.svg)](https://david-dm.org/llk/scratch-parser) +[![devDependencies Status](https://david-dm.org/llk/scratch-parser/dev-status.svg)](https://david-dm.org/llk/scratch-parser?type=dev) ## Overview The Scratch Parser is a [Node.js](https://nodejs.org) module that parses and validates [Scratch](https://scratch.mit.edu) projects. Internally, this utility is used for validation of Scratch projects as well as for extracting metadata from projects for research and search purposes. From cfb2b527c503155d7738cdd755a72126fa3a12f9 Mon Sep 17 00:00:00 2001 From: Andrew Sliwinski Date: Mon, 19 Sep 2016 10:19:32 -0400 Subject: [PATCH 5/8] Update dependencies --- package.json | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/package.json b/package.json index 394f40fb..399f14f6 100644 --- a/package.json +++ b/package.json @@ -15,14 +15,14 @@ }, "dependencies": { "adm-zip": "0.4.7", - "ajv": "3.4.0", - "async": "1.5.2" + "ajv": "4.7.0", + "async": "2.0.1" }, "devDependencies": { - "benchmark": "^2.0.0", - "eslint": "^1.10.3", - "glob": "^6.0.4", - "tap": "^5.1.1" + "benchmark": "^2.1.1", + "eslint": "^3.5.0", + "glob": "^7.0.6", + "tap": "^7.1.2" }, "engines": { "node": ">=4.0" From ddac1fdc015a59923353a95c38b1c063759176f9 Mon Sep 17 00:00:00 2001 From: Matthew Taylor Date: Tue, 21 Mar 2017 15:42:32 -0400 Subject: [PATCH 6/8] Configure semantic-release This adds and sets up the `semantic-release` package to use commits and travis to do automated semantic versioning and publishing to npm for scratch-parser. It also adds a readme section about committing, and using `git cz` to handle formatting of commits in a way that is parseable and deployable by `semantic-release`. This setup is based on the existing release setup in `eslint-config-scratch`. --- .travis.yml | 20 +++++++++++++++----- README.md | 49 +++++++++++++++++++++++++++++++++++++++++++++++++ package.json | 15 +++++++++++---- 3 files changed, 75 insertions(+), 9 deletions(-) diff --git a/.travis.yml b/.travis.yml index 00dd791d..62762659 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,8 +1,18 @@ -language: node_js -node_js: -- "4" -- "stable" sudo: false +language: node_js cache: directories: - - node_modules + - node_modules +notifications: + email: false +node_js: + - '4' +before_install: + - npm i -g npm@^2.0.0 +before_script: + - npm prune +after_success: + - npm run semantic-release +branches: + except: + - /^v\d+\.\d+\.\d+$/ diff --git a/README.md b/README.md index c03d04d5..5a12e07a 100644 --- a/README.md +++ b/README.md @@ -68,3 +68,52 @@ make coverage ```bash make benchmark ``` + +## Committing +This project uses [semantic release](https://github.com/semantic-release/semantic-release) +to ensure version bumps follow semver so that projects using the config don't +break unexpectedly. + +In order to automatically determine the type of version bump necessary, semantic +release expects commit messages to be formatted following +[conventional-changelog](https://github.com/bcoe/conventional-changelog-standard/blob/master/convention.md). +``` +(): + + + +