ado-npm-auth 0.0.2 → 0.0.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +14 -2
- package/dist/ado-npm-auth.cjs +22493 -22491
- package/lib/.tsbuildinfo +1 -1
- package/lib/npmrc/{checkADO.d.ts → check-tokens.d.ts} +3 -2
- package/lib/npmrc/check-tokens.d.ts.map +1 -0
- package/lib/npmrc/{checkADO.js → check-tokens.js} +7 -6
- package/lib/npmrc/check-tokens.js.map +1 -0
- package/lib/npmrc/get-repo-npmrc-ado-orgs.js +1 -1
- package/lib/npmrc/get-repo-npmrc-ado-orgs.js.map +1 -1
- package/lib/npmrc/{getUserPAT.d.ts → get-user-pat.d.ts} +3 -2
- package/lib/npmrc/get-user-pat.d.ts.map +1 -0
- package/lib/npmrc/{getUserPAT.js → get-user-pat.js} +4 -3
- package/lib/npmrc/get-user-pat.js.map +1 -0
- package/lib/npmrc/is-valid-pat.js +3 -3
- package/lib/npmrc/is-valid-pat.js.map +1 -1
- package/lib/npmrc/{makeADORequest.d.ts → make-ado-request.d.ts} +1 -1
- package/lib/npmrc/make-ado-request.d.ts.map +1 -0
- package/lib/npmrc/{makeADORequest.js → make-ado-request.js} +2 -2
- package/lib/npmrc/make-ado-request.js.map +1 -0
- package/lib/npmrc/pat.js +1 -1
- package/lib/npmrc/pat.js.map +1 -1
- package/lib/npmrc/set-npmrc-pat.js +1 -1
- package/lib/npmrc/set-npmrc-pat.js.map +1 -1
- package/lib/{npmrc/getFeedWithoutProtocol.d.ts → utils/get-feed-without-protocol.d.ts} +1 -1
- package/lib/utils/get-feed-without-protocol.d.ts.map +1 -0
- package/lib/{npmrc/getFeedWithoutProtocol.js → utils/get-feed-without-protocol.js} +1 -1
- package/lib/utils/get-feed-without-protocol.js.map +1 -0
- package/lib/{npmrc/getOrganizationFromFeedUrl.d.ts → utils/get-organization-from-feed-url.d.ts} +1 -1
- package/lib/utils/get-organization-from-feed-url.d.ts.map +1 -0
- package/lib/{npmrc/getOrganizationFromFeedUrl.js → utils/get-organization-from-feed-url.js} +1 -1
- package/lib/utils/get-organization-from-feed-url.js.map +1 -0
- package/lib/{npmrc/makeRequest.d.ts → utils/request.d.ts} +1 -1
- package/lib/utils/request.d.ts.map +1 -0
- package/lib/{npmrc/makeRequest.js → utils/request.js} +1 -1
- package/lib/utils/request.js.map +1 -0
- package/package.json +3 -1
- package/static/image.png +0 -0
- package/static/preinstall.png +0 -0
- package/lib/npmrc/checkADO.d.ts.map +0 -1
- package/lib/npmrc/checkADO.js.map +0 -1
- package/lib/npmrc/getFeedWithoutProtocol.d.ts.map +0 -1
- package/lib/npmrc/getFeedWithoutProtocol.js.map +0 -1
- package/lib/npmrc/getOrganizationFromFeedUrl.d.ts.map +0 -1
- package/lib/npmrc/getOrganizationFromFeedUrl.js.map +0 -1
- package/lib/npmrc/getUserPAT.d.ts.map +0 -1
- package/lib/npmrc/getUserPAT.js.map +0 -1
- package/lib/npmrc/makeADORequest.d.ts.map +0 -1
- package/lib/npmrc/makeADORequest.js.map +0 -1
- package/lib/npmrc/makeRequest.d.ts.map +0 -1
- package/lib/npmrc/makeRequest.js.map +0 -1
package/README.md
CHANGED
|
@@ -18,6 +18,18 @@ The main difference between the two is how they function, and where they can run
|
|
|
18
18
|
|
|
19
19
|
`ado-npm-auth` uses the `node-azureauth` library, to wrap the [azureauth-cli](https://github.com/AzureAD/microsoft-authentication-cli), which itself is a cross platform MSAL wrapper.
|
|
20
20
|
|
|
21
|
-

|
|
21
|
+

|
|
22
22
|
|
|
23
|
-
Since the `azureauth-cli` is cross-platform, `ado-npm-auth` will also run cross-platform as well
|
|
23
|
+
Since the `azureauth-cli` is cross-platform, `ado-npm-auth` will also run cross-platform as well!
|
|
24
|
+
|
|
25
|
+
One of the easiest ways to use the tool is to add it to your `"preinstall"` script in your repo like this...
|
|
26
|
+
|
|
27
|
+
```json
|
|
28
|
+
"scripts": {
|
|
29
|
+
"preinstall": "npm exec ado-npm-auth"
|
|
30
|
+
},
|
|
31
|
+
```
|
|
32
|
+
|
|
33
|
+
It will then perform a quick "pre-flight" check to assess if the token is valid, and generate a new one if it has expired.
|
|
34
|
+
|
|
35
|
+

|