mirror of
				https://gitea.com/actions/setup-node.git
				synced 2025-10-29 07:47:20 +00:00 
			
		
		
		
	Add auth support (#21)
* Updates * Update * Update * Update * Update * Yarn sometimes prefers npmrc, so use same token * Description * Update readme * Feedback * Add type * new toolkit and scoped registries * npmrc in RUNNER_TEMP * Dont always auth * Try exporting blank token * Get auth working for now pending runner changes * Fix string interpolation for auth token. * Don't export both userconfigs * Update authutil.js * Add single quotes for authString * Fix the registry string. * Use userconfig and append trailing slash * Keep in root of repo * Try just adding auth token * Remove auth token * Try changes again * Add tests * Npm and GPR samples * Add types
This commit is contained in:
		
							
								
								
									
										15
									
								
								node_modules/deprecation/LICENSE
									
									
									
										generated
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										15
									
								
								node_modules/deprecation/LICENSE
									
									
									
										generated
									
									
										vendored
									
									
										Normal file
									
								
							| @@ -0,0 +1,15 @@ | ||||
| The ISC License | ||||
|  | ||||
| Copyright (c) Gregor Martynus and contributors | ||||
|  | ||||
| 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 AUTHOR DISCLAIMS ALL WARRANTIES | ||||
| WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||||
| MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR 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. | ||||
							
								
								
									
										77
									
								
								node_modules/deprecation/README.md
									
									
									
										generated
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										77
									
								
								node_modules/deprecation/README.md
									
									
									
										generated
									
									
										vendored
									
									
										Normal file
									
								
							| @@ -0,0 +1,77 @@ | ||||
| # deprecation | ||||
|  | ||||
| > Log a deprecation message with stack | ||||
|  | ||||
|  | ||||
|  | ||||
| ## Usage | ||||
|  | ||||
| <table> | ||||
| <tbody valign=top align=left> | ||||
| <tr><th> | ||||
| Browsers | ||||
| </th><td width=100%> | ||||
|  | ||||
| Load `deprecation` directly from [cdn.pika.dev](https://cdn.pika.dev) | ||||
|  | ||||
| ```html | ||||
| <script type="module"> | ||||
|   import { Deprecation } from "https://cdn.pika.dev/deprecation/v2"; | ||||
| </script> | ||||
| ``` | ||||
|  | ||||
| </td></tr> | ||||
| <tr><th> | ||||
| Node | ||||
| </th><td> | ||||
|  | ||||
| Install with `npm install deprecation` | ||||
|  | ||||
| ```js | ||||
| const { Deprecation } = require("deprecation"); | ||||
| // or: import { Deprecation } from "deprecation"; | ||||
| ``` | ||||
|  | ||||
| </td></tr> | ||||
| </tbody> | ||||
| </table> | ||||
|  | ||||
| ```js | ||||
| function foo() { | ||||
|   bar(); | ||||
| } | ||||
|  | ||||
| function bar() { | ||||
|   baz(); | ||||
| } | ||||
|  | ||||
| function baz() { | ||||
|   console.warn(new Deprecation("[my-lib] foo() is deprecated, use bar()")); | ||||
| } | ||||
|  | ||||
| foo(); | ||||
| // { Deprecation: [my-lib] foo() is deprecated, use bar() | ||||
| //     at baz (/path/to/file.js:12:15) | ||||
| //     at bar (/path/to/file.js:8:3) | ||||
| //     at foo (/path/to/file.js:4:3) | ||||
| ``` | ||||
|  | ||||
| To log a deprecation message only once, you can use the [once](https://www.npmjs.com/package/once) module. | ||||
|  | ||||
| ```js | ||||
| const Deprecation = require("deprecation"); | ||||
| const once = require("once"); | ||||
|  | ||||
| const deprecateFoo = once(console.warn); | ||||
|  | ||||
| function foo() { | ||||
|   deprecateFoo(new Deprecation("[my-lib] foo() is deprecated, use bar()")); | ||||
| } | ||||
|  | ||||
| foo(); | ||||
| foo(); // logs nothing | ||||
| ``` | ||||
|  | ||||
| ## License | ||||
|  | ||||
| [ISC](LICENSE) | ||||
							
								
								
									
										20
									
								
								node_modules/deprecation/dist-node/index.js
									
									
									
										generated
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										20
									
								
								node_modules/deprecation/dist-node/index.js
									
									
									
										generated
									
									
										vendored
									
									
										Normal file
									
								
							| @@ -0,0 +1,20 @@ | ||||
| 'use strict'; | ||||
|  | ||||
| Object.defineProperty(exports, '__esModule', { value: true }); | ||||
|  | ||||
| class Deprecation extends Error { | ||||
|   constructor(message) { | ||||
|     super(message); // Maintains proper stack trace (only available on V8) | ||||
|  | ||||
|     /* istanbul ignore next */ | ||||
|  | ||||
|     if (Error.captureStackTrace) { | ||||
|       Error.captureStackTrace(this, this.constructor); | ||||
|     } | ||||
|  | ||||
|     this.name = 'Deprecation'; | ||||
|   } | ||||
|  | ||||
| } | ||||
|  | ||||
| exports.Deprecation = Deprecation; | ||||
							
								
								
									
										14
									
								
								node_modules/deprecation/dist-src/index.js
									
									
									
										generated
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										14
									
								
								node_modules/deprecation/dist-src/index.js
									
									
									
										generated
									
									
										vendored
									
									
										Normal file
									
								
							| @@ -0,0 +1,14 @@ | ||||
| export class Deprecation extends Error { | ||||
|   constructor(message) { | ||||
|     super(message); // Maintains proper stack trace (only available on V8) | ||||
|  | ||||
|     /* istanbul ignore next */ | ||||
|  | ||||
|     if (Error.captureStackTrace) { | ||||
|       Error.captureStackTrace(this, this.constructor); | ||||
|     } | ||||
|  | ||||
|     this.name = 'Deprecation'; | ||||
|   } | ||||
|  | ||||
| } | ||||
							
								
								
									
										3
									
								
								node_modules/deprecation/dist-types/index.d.ts
									
									
									
										generated
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										3
									
								
								node_modules/deprecation/dist-types/index.d.ts
									
									
									
										generated
									
									
										vendored
									
									
										Normal file
									
								
							| @@ -0,0 +1,3 @@ | ||||
| export class Deprecation extends Error { | ||||
|   name: "Deprecation"; | ||||
| } | ||||
							
								
								
									
										16
									
								
								node_modules/deprecation/dist-web/index.js
									
									
									
										generated
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										16
									
								
								node_modules/deprecation/dist-web/index.js
									
									
									
										generated
									
									
										vendored
									
									
										Normal file
									
								
							| @@ -0,0 +1,16 @@ | ||||
| class Deprecation extends Error { | ||||
|   constructor(message) { | ||||
|     super(message); // Maintains proper stack trace (only available on V8) | ||||
|  | ||||
|     /* istanbul ignore next */ | ||||
|  | ||||
|     if (Error.captureStackTrace) { | ||||
|       Error.captureStackTrace(this, this.constructor); | ||||
|     } | ||||
|  | ||||
|     this.name = 'Deprecation'; | ||||
|   } | ||||
|  | ||||
| } | ||||
|  | ||||
| export { Deprecation }; | ||||
							
								
								
									
										65
									
								
								node_modules/deprecation/package.json
									
									
									
										generated
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										65
									
								
								node_modules/deprecation/package.json
									
									
									
										generated
									
									
										vendored
									
									
										Normal file
									
								
							| @@ -0,0 +1,65 @@ | ||||
| { | ||||
|   "_from": "deprecation@^2.0.0", | ||||
|   "_id": "deprecation@2.3.1", | ||||
|   "_inBundle": false, | ||||
|   "_integrity": "sha512-xmHIy4F3scKVwMsQ4WnVaS8bHOx0DmVwRywosKhaILI0ywMDWPtBSku2HNxRvF7jtwDRsoEwYQSfbxj8b7RlJQ==", | ||||
|   "_location": "/deprecation", | ||||
|   "_phantomChildren": {}, | ||||
|   "_requested": { | ||||
|     "type": "range", | ||||
|     "registry": true, | ||||
|     "raw": "deprecation@^2.0.0", | ||||
|     "name": "deprecation", | ||||
|     "escapedName": "deprecation", | ||||
|     "rawSpec": "^2.0.0", | ||||
|     "saveSpec": null, | ||||
|     "fetchSpec": "^2.0.0" | ||||
|   }, | ||||
|   "_requiredBy": [ | ||||
|     "/@octokit/request", | ||||
|     "/@octokit/request-error", | ||||
|     "/@octokit/rest" | ||||
|   ], | ||||
|   "_resolved": "https://registry.npmjs.org/deprecation/-/deprecation-2.3.1.tgz", | ||||
|   "_shasum": "6368cbdb40abf3373b525ac87e4a260c3a700919", | ||||
|   "_spec": "deprecation@^2.0.0", | ||||
|   "_where": "C:\\Users\\Administrator\\Documents\\setup-node\\node_modules\\@octokit\\request", | ||||
|   "bugs": { | ||||
|     "url": "https://github.com/gr2m/deprecation/issues" | ||||
|   }, | ||||
|   "bundleDependencies": false, | ||||
|   "dependencies": {}, | ||||
|   "deprecated": false, | ||||
|   "description": "Log a deprecation message with stack", | ||||
|   "devDependencies": { | ||||
|     "@pika/pack": "^0.3.7", | ||||
|     "@pika/plugin-build-node": "^0.4.0", | ||||
|     "@pika/plugin-build-types": "^0.4.0", | ||||
|     "@pika/plugin-build-web": "^0.4.0", | ||||
|     "@pika/plugin-standard-pkg": "^0.4.0", | ||||
|     "semantic-release": "^15.13.3" | ||||
|   }, | ||||
|   "esnext": "dist-src/index.js", | ||||
|   "files": [ | ||||
|     "dist-*/", | ||||
|     "bin/" | ||||
|   ], | ||||
|   "homepage": "https://github.com/gr2m/deprecation#readme", | ||||
|   "keywords": [ | ||||
|     "deprecate", | ||||
|     "deprecated", | ||||
|     "deprecation" | ||||
|   ], | ||||
|   "license": "ISC", | ||||
|   "main": "dist-node/index.js", | ||||
|   "module": "dist-web/index.js", | ||||
|   "name": "deprecation", | ||||
|   "pika": true, | ||||
|   "repository": { | ||||
|     "type": "git", | ||||
|     "url": "git+https://github.com/gr2m/deprecation.git" | ||||
|   }, | ||||
|   "sideEffects": false, | ||||
|   "types": "dist-types/index.d.ts", | ||||
|   "version": "2.3.1" | ||||
| } | ||||
		Reference in New Issue
	
	Block a user
	 Danny McCormick
					Danny McCormick