push all website files

This commit is contained in:
Jacob Levine
2019-01-06 13:14:45 -06:00
parent d7301e26c3
commit d2d5d4c04e
15662 changed files with 2166516 additions and 0 deletions

View File

@@ -0,0 +1,93 @@
# Change Log
All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.
<a name="2.1.0"></a>
# [2.1.0](https://github.com/zkat/npm-pick-manifest/compare/v2.0.1...v2.1.0) (2017-10-18)
### Features
* **selection:** allow manually disabling deprecation skipping ([0d239d3](https://github.com/zkat/npm-pick-manifest/commit/0d239d3))
<a name="2.0.1"></a>
## [2.0.1](https://github.com/zkat/npm-pick-manifest/compare/v2.0.0...v2.0.1) (2017-10-18)
<a name="2.0.0"></a>
# [2.0.0](https://github.com/zkat/npm-pick-manifest/compare/v1.0.4...v2.0.0) (2017-10-03)
### Bug Fixes
* **license:** relicense project according to npm policy (#3) ([ed743a0](https://github.com/zkat/npm-pick-manifest/commit/ed743a0))
### Features
* **selection:** Avoid matching deprecated packages if possible ([3fc6c3a](https://github.com/zkat/npm-pick-manifest/commit/3fc6c3a))
### BREAKING CHANGES
* **selection:** deprecated versions may be skipped now
* **license:** This moves the license from CC0 to ISC and properly documents the copyright as belonging to npm, Inc.
<a name="1.0.4"></a>
## [1.0.4](https://github.com/zkat/npm-pick-manifest/compare/v1.0.3...v1.0.4) (2017-06-29)
### Bug Fixes
* **npa:** bump npa version for bugfixes ([7cdaca7](https://github.com/zkat/npm-pick-manifest/commit/7cdaca7))
* **semver:** use loose semver parsing for *all* ops ([bbc0daa](https://github.com/zkat/npm-pick-manifest/commit/bbc0daa))
<a name="1.0.3"></a>
## [1.0.3](https://github.com/zkat/npm-pick-manifest/compare/v1.0.2...v1.0.3) (2017-05-04)
### Bug Fixes
* **semver:** use semver.clean() instead ([f4133b5](https://github.com/zkat/npm-pick-manifest/commit/f4133b5))
<a name="1.0.2"></a>
## [1.0.2](https://github.com/zkat/npm-pick-manifest/compare/v1.0.1...v1.0.2) (2017-05-04)
### Bug Fixes
* **picker:** spaces in `wanted` prevented match ([97a7d0a](https://github.com/zkat/npm-pick-manifest/commit/97a7d0a))
<a name="1.0.1"></a>
## [1.0.1](https://github.com/zkat/npm-pick-manifest/compare/v1.0.0...v1.0.1) (2017-04-24)
### Bug Fixes
* **deps:** forgot to add semver ([1876f4f](https://github.com/zkat/npm-pick-manifest/commit/1876f4f))
<a name="1.0.0"></a>
# 1.0.0 (2017-04-24)
### Features
* **api:** initial implementation. ([b086912](https://github.com/zkat/npm-pick-manifest/commit/b086912))
### BREAKING CHANGES
* **api:** ex nihilo

View File

@@ -0,0 +1,16 @@
ISC License
Copyright (c) npm, Inc.
Permission to use, copy, modify, and/or distribute this software for
any purpose with or without fee is hereby granted, provided that the
above copyright notice and this permission notice appear in all copies.
THE SOFTWARE IS PROVIDED "AS IS" AND THE COPYRIGHT HOLDER DISCLAIMS
ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED
WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE
COPYRIGHT HOLDER BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR
CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS
OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE
OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE
USE OR PERFORMANCE OF THIS SOFTWARE.

View File

@@ -0,0 +1,76 @@
# npm-pick-manifest [![npm version](https://img.shields.io/npm/v/npm-pick-manifest.svg)](https://npm.im/npm-pick-manifest) [![license](https://img.shields.io/npm/l/npm-pick-manifest.svg)](https://npm.im/npm-pick-manifest) [![Travis](https://img.shields.io/travis/zkat/npm-pick-manifest.svg)](https://travis-ci.org/zkat/npm-pick-manifest) [![AppVeyor](https://ci.appveyor.com/api/projects/status/github/zkat/npm-pick-manifest?svg=true)](https://ci.appveyor.com/project/zkat/npm-pick-manifest) [![Coverage Status](https://coveralls.io/repos/github/zkat/npm-pick-manifest/badge.svg?branch=latest)](https://coveralls.io/github/zkat/npm-pick-manifest?branch=latest)
[`npm-pick-manifest`](https://github.com/zkat/npm-pick-manifest) is a standalone
implementation of [npm](https://npmjs.com)'s semver range resolution algorithm.
## Install
`$ npm install --save npm-pick-manifest`
## Table of Contents
* [Example](#example)
* [Features](#features)
* [Contributing](#contributing)
* [API](#api)
* [`pickManifest()`](#pick-manifest)
### Example
```javascript
const pickManifest = require('npm-pick-manifest')
fetch('https://registry.npmjs.org/npm-pick-manifest').then(res => {
return res.json()
}).then(packument => {
return pickManifest(packument, '^1.0.0')
}) // get same manifest as npm would get if you `npm i npm-pick-manifest@^1.0.0`
```
### Features
* Uses npm's exact semver resolution algorithm
* Supports ranges, tags, and versions
### Contributing
The npm-pick-manifest team enthusiastically welcomes contributions and project participation!
There's a bunch of things you can do if you want to contribute! The [Contributor
Guide](CONTRIBUTING.md) has all the information you need for everything from
reporting bugs to contributing entire new features. Please don't hesitate to
jump in if you'd like to, or even ask us questions if something isn't clear.
### API
#### <a name="pick-manifest"></a> `> pickManifest(packument, selector, [opts]) -> manifest`
Returns the manifest that matches `selector`, or throws an error.
Packuments are anything returned by metadata URLs from the npm registry. That
is, they're objects with the following shape (only fields used by
`npm-pick-manifest` included):
```javascript
{
name: 'some-package',
'dist-tags': {
foo: '1.0.1'
},
versions: {
'1.0.0': { version: '1.0.0' },
'1.0.1': { version: '1.0.1' },
'1.0.2': { version: '1.0.2' },
'2.0.0': { version: '2.0.0' }
}
}
```
The algorithm will follow npm's algorithm for semver resolution, and only `tag`,
`range`, and `version` selectors are supported.
The function will throw `ETARGET` if there was no matching manifest, and
`ENOVERSIONS` if the packument object has no valid versions in `versions`.
If `opts.defaultTag` is provided, it will be used instead of `latest`. That is,
if that tag matches the selector, it will be used, even if a higher available
version matches the range.

View File

@@ -0,0 +1,79 @@
'use strict'
const npa = require('npm-package-arg')
const semver = require('semver')
module.exports = pickManifest
function pickManifest (packument, wanted, opts) {
opts = opts || {}
const spec = npa.resolve(packument.name, wanted)
const type = spec.type
if (type === 'version' || type === 'range') {
wanted = semver.clean(wanted, true) || wanted
}
const distTags = packument['dist-tags'] || {}
const versions = Object.keys(packument.versions || {}).filter(v => semver.valid(v, true))
const undeprecated = versions.filter(v => !packument.versions[v].deprecated)
let err
if (!versions.length) {
err = new Error(`No valid versions available for ${packument.name}`)
err.code = 'ENOVERSIONS'
err.name = packument.name
err.type = type
err.wanted = wanted
throw err
}
let target
if (type === 'tag') {
target = distTags[wanted]
} else if (type === 'version') {
target = wanted
} else if (type !== 'range') {
throw new Error('Only tag, version, and range are supported')
}
const tagVersion = distTags[opts.defaultTag || 'latest']
if (
!target &&
tagVersion &&
packument.versions[tagVersion] &&
semver.satisfies(tagVersion, wanted, true)
) {
target = tagVersion
}
if (!target && !opts.includeDeprecated) {
target = semver.maxSatisfying(undeprecated, wanted, true)
}
if (!target) {
target = semver.maxSatisfying(versions, wanted, true)
}
if (!target && wanted === '*') {
// This specific corner is meant for the case where
// someone is using `*` as a selector, but all versions
// are pre-releases, which don't match ranges at all.
target = tagVersion
}
const manifest = target && packument.versions[target]
if (!manifest) {
err = new Error(
`No matching version found for ${packument.name}@${wanted}`
)
err.code = 'ETARGET'
err.name = packument.name
err.type = type
err.wanted = wanted
err.versions = versions
err.distTags = distTags
err.defaultTag = opts.defaultTag
throw err
} else {
return manifest
}
}

View File

@@ -0,0 +1,85 @@
{
"_args": [
[
"npm-pick-manifest@2.1.0",
"/Users/rebecca/code/npm"
]
],
"_from": "npm-pick-manifest@2.1.0",
"_id": "npm-pick-manifest@2.1.0",
"_inBundle": true,
"_integrity": "sha512-q9zLP8cTr8xKPmMZN3naxp1k/NxVFsjxN6uWuO1tiw9gxg7wZWQ/b5UTfzD0ANw2q1lQxdLKTeCCksq+bPSgbQ==",
"_location": "/npm/npm-pick-manifest",
"_phantomChildren": {},
"_requested": {
"type": "version",
"registry": true,
"raw": "npm-pick-manifest@2.1.0",
"name": "npm-pick-manifest",
"escapedName": "npm-pick-manifest",
"rawSpec": "2.1.0",
"saveSpec": null,
"fetchSpec": "2.1.0"
},
"_requiredBy": [
"/npm",
"/npm/pacote"
],
"_resolved": "https://registry.npmjs.org/npm-pick-manifest/-/npm-pick-manifest-2.1.0.tgz",
"_spec": "2.1.0",
"_where": "/Users/rebecca/code/npm",
"author": {
"name": "Kat Marchán",
"email": "kzm@sykosomatic.org"
},
"bugs": {
"url": "https://github.com/zkat/npm-pick-manifest/issues"
},
"config": {
"nyc": {
"exclude": [
"node_modules/**",
"test/**"
]
}
},
"dependencies": {
"npm-package-arg": "^6.0.0",
"semver": "^5.4.1"
},
"description": "Resolves a matching manifest from a package metadata document according to standard npm semver resolution rules.",
"devDependencies": {
"nyc": "^11.2.1",
"standard": "^10.0.3",
"standard-version": "^4.2.0",
"tap": "^10.7.0",
"weallbehave": "^1.2.0",
"weallcontribute": "^1.0.8"
},
"files": [
"*.js"
],
"homepage": "https://github.com/zkat/npm-pick-manifest#readme",
"keywords": [
"npm",
"semver",
"package manager"
],
"license": "ISC",
"main": "index.js",
"name": "npm-pick-manifest",
"repository": {
"type": "git",
"url": "git+https://github.com/zkat/npm-pick-manifest.git"
},
"scripts": {
"postrelease": "npm publish && git push --follow-tags",
"prerelease": "npm t",
"pretest": "standard",
"release": "standard-version -s",
"test": "tap -J --100 --coverage test/*.js",
"update-coc": "weallbehave -o . && git add CODE_OF_CONDUCT.md && git commit -m 'docs(coc): updated CODE_OF_CONDUCT.md'",
"update-contrib": "weallcontribute -o . && git add CONTRIBUTING.md && git commit -m 'docs(contributing): updated CONTRIBUTING.md'"
},
"version": "2.1.0"
}