initial commit

This commit is contained in:
Zoe
2023-01-03 09:29:04 -06:00
commit 7851137d88
12889 changed files with 2557443 additions and 0 deletions

22
node_modules/std-env/LICENCE generated vendored Normal file
View File

@@ -0,0 +1,22 @@
MIT License
Copyright (c) Pooya Parsa <pooya@pi0.io>
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.

52
node_modules/std-env/README.md generated vendored Normal file
View File

@@ -0,0 +1,52 @@
# std-env
[![npm](https://img.shields.io/npm/dm/std-env.svg?style=flat-square)](http://npmjs.com/package/std-env)
[![npm](https://img.shields.io/npm/v/std-env.svg?style=flat-square)](http://npmjs.com/package/std-env)
[![bundlephobia](https://img.shields.io/bundlephobia/min/std-env/latest.svg?style=flat-square)](https://bundlephobia.com/result?p=std-env)
> Detect current Javascript environment
## Installation
```sh
# Using Yarn
yarn add std-env
# Using npm
npm i std-env
```
## Usage
```js
// ESM
import { isWindows } from 'std-env'
// CommonJS
const { isCI } = require('std-env')
```
Available exports:
- `hasTTY`
- `hasWindow`
- `isCI`
- `isDebug`
- `isDevelopment`
- `isLinux`
- `isMacOS`
- `isMinimal`
- `isProduction`
- `isTest`
- `isWindows`
- `platform`
- `provider`
You can read more about how each flag works from [./src/index.ts](./src/index.ts).
List of well known providers can be found from [./src/providers.ts](./src/providers.ts).
## License
MIT

103
node_modules/std-env/dist/index.cjs generated vendored Normal file
View File

@@ -0,0 +1,103 @@
'use strict';
const providers = [
["APPVEYOR"],
["AZURE_PIPELINES", "SYSTEM_TEAMFOUNDATIONCOLLECTIONURI"],
["AZURE_STATIC", "INPUT_AZURE_STATIC_WEB_APPS_API_TOKEN"],
["APPCIRCLE", "AC_APPCIRCLE"],
["BAMBOO", "bamboo_planKey"],
["BITBUCKET", "BITBUCKET_COMMIT"],
["BITRISE", "BITRISE_IO"],
["BUDDY", "BUDDY_WORKSPACE_ID"],
["BUILDKITE"],
["CIRCLE", "CIRCLECI"],
["CIRRUS", "CIRRUS_CI"],
["CLOUDFLARE_PAGES", "CF_PAGES", { ci: true }],
["CODEBUILD", "CODEBUILD_BUILD_ARN"],
["CODEFRESH", "CF_BUILD_ID"],
["DRONE"],
["DRONE", "DRONE_BUILD_EVENT"],
["DSARI"],
["GITHUB_ACTIONS"],
["GITLAB", "GITLAB_CI"],
["GITLAB", "CI_MERGE_REQUEST_ID"],
["GOCD", "GO_PIPELINE_LABEL"],
["LAYERCI"],
["HUDSON", "HUDSON_URL"],
["JENKINS", "JENKINS_URL"],
["MAGNUM"],
["NETLIFY"],
["NETLIFY", "NETLIFY_LOCAL", { ci: false }],
["NEVERCODE"],
["RENDER"],
["SAIL", "SAILCI"],
["SEMAPHORE"],
["SCREWDRIVER"],
["SHIPPABLE"],
["SOLANO", "TDDIUM"],
["STRIDER"],
["TEAMCITY", "TEAMCITY_VERSION"],
["TRAVIS"],
["VERCEL", "NOW_BUILDER"],
["APPCENTER", "APPCENTER_BUILD_ID"],
["CODESANDBOX", "CODESANDBOX_SSE", { ci: false }],
["STACKBLITZ"],
["STORMKIT"],
["CLEAVR"]
];
function detectProvider(env) {
for (const provider of providers) {
const envName = provider[1] || provider[0];
if (env[envName]) {
return {
name: provider[0].toLowerCase(),
...provider[2]
};
}
}
if (env.SHELL && env.SHELL === "/bin/jsh") {
return {
name: "stackblitz",
ci: false
};
}
return {
name: "",
ci: false
};
}
const processShim = typeof process !== "undefined" ? process : {};
const envShim = processShim.env || {};
const providerInfo = detectProvider(envShim);
const nodeENV = envShim.NODE_ENV || "";
const platform = processShim.platform;
const provider = providerInfo.name;
const isCI = toBoolean(envShim.CI) || providerInfo.ci !== false;
const hasTTY = toBoolean(processShim.stdout && processShim.stdout.isTTY);
const hasWindow = typeof window !== "undefined";
const isDebug = toBoolean(envShim.DEBUG);
const isTest = toBoolean(envShim.TEST);
const isProduction = nodeENV === "production";
const isDevelopment = nodeENV === "dev" || nodeENV === "development";
const isMinimal = toBoolean(envShim.MINIMAL) || isCI || isTest || !hasTTY;
const isWindows = /^win/i.test(platform);
const isLinux = /^linux/i.test(platform);
const isMacOS = /^darwin/i.test(platform);
function toBoolean(val) {
return val ? val !== "false" : false;
}
exports.hasTTY = hasTTY;
exports.hasWindow = hasWindow;
exports.isCI = isCI;
exports.isDebug = isDebug;
exports.isDevelopment = isDevelopment;
exports.isLinux = isLinux;
exports.isMacOS = isMacOS;
exports.isMinimal = isMinimal;
exports.isProduction = isProduction;
exports.isTest = isTest;
exports.isWindows = isWindows;
exports.platform = platform;
exports.provider = provider;

34
node_modules/std-env/dist/index.d.ts generated vendored Normal file
View File

@@ -0,0 +1,34 @@
declare type ProviderName = "" | "appveyor" | "azure_pipelines" | "azure_static" | "appcircle" | "bamboo" | "bitbucket" | "bitrise" | "buddy" | "buildkite" | "circle" | "cirrus" | "cloudflare_pages" | "codebuild" | "codefresh" | "drone" | "drone" | "dsari" | "github_actions" | "gitlab" | "gocd" | "layerci" | "hudson" | "jenkins" | "magnum" | "netlify" | "nevercode" | "render" | "sail" | "semaphore" | "screwdriver" | "shippable" | "solano" | "strider" | "teamcity" | "travis" | "vercel" | "appcenter" | "codesandbox" | "stackblitz" | "stormkit" | "cleavr";
declare type ProviderInfo = {
name: ProviderName;
[meta: string]: any;
};
/** Value of process.platform */
declare const platform: NodeJS.Platform;
/** Current provider name */
declare const provider: ProviderName;
/** Detect if `CI` environment variable is set or a provider CI detected */
declare const isCI: boolean;
/** Detect if stdout.TTY is available */
declare const hasTTY: boolean;
/** Detect if global `window` object is available */
declare const hasWindow: boolean;
/** Detect if `DEBUG` environment variable is set */
declare const isDebug: boolean;
/** Detect if `NODE_ENV` environment variable is `test` */
declare const isTest: boolean;
/** Detect if `NODE_ENV` environment variable is `production` */
declare const isProduction: boolean;
/** Detect if `NODE_ENV` environment variable is `dev` or `development` */
declare const isDevelopment: boolean;
/** Detect if MINIMAL environment variable is set, running in CI or test or TTY is unavailable */
declare const isMinimal: boolean;
/** Detect if process.platform is Windows */
declare const isWindows: boolean;
/** Detect if process.platform is Linux */
declare const isLinux: boolean;
/** Detect if process.platform is macOS (darwin kernel) */
declare const isMacOS: boolean;
export { ProviderInfo, ProviderName, hasTTY, hasWindow, isCI, isDebug, isDevelopment, isLinux, isMacOS, isMinimal, isProduction, isTest, isWindows, platform, provider };

89
node_modules/std-env/dist/index.mjs generated vendored Normal file
View File

@@ -0,0 +1,89 @@
const providers = [
["APPVEYOR"],
["AZURE_PIPELINES", "SYSTEM_TEAMFOUNDATIONCOLLECTIONURI"],
["AZURE_STATIC", "INPUT_AZURE_STATIC_WEB_APPS_API_TOKEN"],
["APPCIRCLE", "AC_APPCIRCLE"],
["BAMBOO", "bamboo_planKey"],
["BITBUCKET", "BITBUCKET_COMMIT"],
["BITRISE", "BITRISE_IO"],
["BUDDY", "BUDDY_WORKSPACE_ID"],
["BUILDKITE"],
["CIRCLE", "CIRCLECI"],
["CIRRUS", "CIRRUS_CI"],
["CLOUDFLARE_PAGES", "CF_PAGES", { ci: true }],
["CODEBUILD", "CODEBUILD_BUILD_ARN"],
["CODEFRESH", "CF_BUILD_ID"],
["DRONE"],
["DRONE", "DRONE_BUILD_EVENT"],
["DSARI"],
["GITHUB_ACTIONS"],
["GITLAB", "GITLAB_CI"],
["GITLAB", "CI_MERGE_REQUEST_ID"],
["GOCD", "GO_PIPELINE_LABEL"],
["LAYERCI"],
["HUDSON", "HUDSON_URL"],
["JENKINS", "JENKINS_URL"],
["MAGNUM"],
["NETLIFY"],
["NETLIFY", "NETLIFY_LOCAL", { ci: false }],
["NEVERCODE"],
["RENDER"],
["SAIL", "SAILCI"],
["SEMAPHORE"],
["SCREWDRIVER"],
["SHIPPABLE"],
["SOLANO", "TDDIUM"],
["STRIDER"],
["TEAMCITY", "TEAMCITY_VERSION"],
["TRAVIS"],
["VERCEL", "NOW_BUILDER"],
["APPCENTER", "APPCENTER_BUILD_ID"],
["CODESANDBOX", "CODESANDBOX_SSE", { ci: false }],
["STACKBLITZ"],
["STORMKIT"],
["CLEAVR"]
];
function detectProvider(env) {
for (const provider of providers) {
const envName = provider[1] || provider[0];
if (env[envName]) {
return {
name: provider[0].toLowerCase(),
...provider[2]
};
}
}
if (env.SHELL && env.SHELL === "/bin/jsh") {
return {
name: "stackblitz",
ci: false
};
}
return {
name: "",
ci: false
};
}
const processShim = typeof process !== "undefined" ? process : {};
const envShim = processShim.env || {};
const providerInfo = detectProvider(envShim);
const nodeENV = envShim.NODE_ENV || "";
const platform = processShim.platform;
const provider = providerInfo.name;
const isCI = toBoolean(envShim.CI) || providerInfo.ci !== false;
const hasTTY = toBoolean(processShim.stdout && processShim.stdout.isTTY);
const hasWindow = typeof window !== "undefined";
const isDebug = toBoolean(envShim.DEBUG);
const isTest = toBoolean(envShim.TEST);
const isProduction = nodeENV === "production";
const isDevelopment = nodeENV === "dev" || nodeENV === "development";
const isMinimal = toBoolean(envShim.MINIMAL) || isCI || isTest || !hasTTY;
const isWindows = /^win/i.test(platform);
const isLinux = /^linux/i.test(platform);
const isMacOS = /^darwin/i.test(platform);
function toBoolean(val) {
return val ? val !== "false" : false;
}
export { hasTTY, hasWindow, isCI, isDebug, isDevelopment, isLinux, isMacOS, isMinimal, isProduction, isTest, isWindows, platform, provider };

36
node_modules/std-env/package.json generated vendored Normal file
View File

@@ -0,0 +1,36 @@
{
"name": "std-env",
"version": "3.3.1",
"description": "Detect current Javascript environment",
"repository": "unjs/std-env",
"license": "MIT",
"sideEffects": false,
"exports": {
"import": "./dist/index.mjs",
"require": "./dist/index.cjs"
},
"main": "./dist/index.cjs",
"types": "./dist/index.d.ts",
"files": [
"dist"
],
"devDependencies": {
"@types/node": "^18.11.9",
"c8": "^7.12.0",
"eslint": "^8.27.0",
"eslint-config-unjs": "^0.0.2",
"jiti": "^1.16.0",
"standard-version": "^9.5.0",
"typescript": "^4.8.4",
"unbuild": "^0.9.4",
"vitest": "^0.25.2"
},
"packageManager": "pnpm@7.13.4",
"scripts": {
"build": "unbuild",
"dev": "vitest",
"lint": "eslint --ext .ts .",
"release": "pnpm test && standard-version && git push --follow-tags && pnpm publish",
"test": "pnpm lint && vitest run"
}
}