repository-provider 27.0.4 → 27.0.5
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 +11 -4
- package/package.json +3 -3
- package/src/ref.mjs +6 -2
- package/src/repository.mjs +15 -12
package/README.md
CHANGED
|
@@ -250,6 +250,7 @@ console.log(await readme.getString());
|
|
|
250
250
|
* [fullName](#fullname-3)
|
|
251
251
|
* [fullCondensedName](#fullcondensedname)
|
|
252
252
|
* [identifier](#identifier-1)
|
|
253
|
+
* [toString](#tostring)
|
|
253
254
|
* [issuesURL](#issuesurl)
|
|
254
255
|
* [homePageURL](#homepageurl-1)
|
|
255
256
|
* [isLocked](#islocked)
|
|
@@ -1416,7 +1417,7 @@ Returns **[boolean](https://developer.mozilla.org/docs/Web/JavaScript/Reference/
|
|
|
1416
1417
|
|
|
1417
1418
|
### ref
|
|
1418
1419
|
|
|
1419
|
-
ref
|
|
1420
|
+
Full ref path.
|
|
1420
1421
|
|
|
1421
1422
|
Returns **[string](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String)** git ref of the Ref
|
|
1422
1423
|
|
|
@@ -1470,7 +1471,7 @@ Returns **[Promise](https://developer.mozilla.org/docs/Web/JavaScript/Reference/
|
|
|
1470
1471
|
|
|
1471
1472
|
* **See**: [Repository#owner](Repository#owner)
|
|
1472
1473
|
|
|
1473
|
-
|
|
1474
|
+
Ref owner.
|
|
1474
1475
|
By default we provide the repository owner
|
|
1475
1476
|
|
|
1476
1477
|
Returns **[string](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String)**
|
|
@@ -1494,6 +1495,12 @@ Short human readable identifier with provider and branch.
|
|
|
1494
1495
|
|
|
1495
1496
|
Returns **[string](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String)**
|
|
1496
1497
|
|
|
1498
|
+
### toString
|
|
1499
|
+
|
|
1500
|
+
Same as identifier.
|
|
1501
|
+
|
|
1502
|
+
Returns **[string](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String)**
|
|
1503
|
+
|
|
1497
1504
|
### issuesURL
|
|
1498
1505
|
|
|
1499
1506
|
* **See**: [Repository#issuesURL](#repositoryissuesurl)
|
|
@@ -1618,7 +1625,7 @@ Returns **[string](https://developer.mozilla.org/docs/Web/JavaScript/Reference/G
|
|
|
1618
1625
|
|
|
1619
1626
|
### slug
|
|
1620
1627
|
|
|
1621
|
-
|
|
1628
|
+
Name of the repo as used in the URL.
|
|
1622
1629
|
|
|
1623
1630
|
Returns **[string](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String)**
|
|
1624
1631
|
|
|
@@ -1689,7 +1696,7 @@ Returns **[string](https://developer.mozilla.org/docs/Web/JavaScript/Reference/G
|
|
|
1689
1696
|
|
|
1690
1697
|
### cloneURL
|
|
1691
1698
|
|
|
1692
|
-
The url used
|
|
1699
|
+
The url used for cloning the repo.
|
|
1693
1700
|
|
|
1694
1701
|
Returns **[string](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String)**
|
|
1695
1702
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "repository-provider",
|
|
3
|
-
"version": "27.0.
|
|
3
|
+
"version": "27.0.5",
|
|
4
4
|
"publishConfig": {
|
|
5
5
|
"access": "public"
|
|
6
6
|
},
|
|
@@ -36,9 +36,9 @@
|
|
|
36
36
|
"ava": "^4.1.0",
|
|
37
37
|
"c8": "^7.11.0",
|
|
38
38
|
"documentation": "^13.2.5",
|
|
39
|
-
"repository-provider-test-support": "^1.12.
|
|
39
|
+
"repository-provider-test-support": "^1.12.11",
|
|
40
40
|
"semantic-release": "^19.0.2",
|
|
41
|
-
"typescript": "^4.6.
|
|
41
|
+
"typescript": "^4.6.3"
|
|
42
42
|
},
|
|
43
43
|
"engines": {
|
|
44
44
|
"node": ">=14.18.3"
|
package/src/ref.mjs
CHANGED
|
@@ -43,7 +43,7 @@ export class Ref extends NamedObject {
|
|
|
43
43
|
}
|
|
44
44
|
|
|
45
45
|
/**
|
|
46
|
-
* ref
|
|
46
|
+
* Full ref path.
|
|
47
47
|
* @return {string} git ref of the Ref
|
|
48
48
|
*/
|
|
49
49
|
get ref() {
|
|
@@ -97,7 +97,7 @@ export class Ref extends NamedObject {
|
|
|
97
97
|
}
|
|
98
98
|
|
|
99
99
|
/**
|
|
100
|
-
*
|
|
100
|
+
* Ref owner.
|
|
101
101
|
* By default we provide the repository owner
|
|
102
102
|
* @see {@link Repository#owner}
|
|
103
103
|
* @return {string}
|
|
@@ -137,6 +137,10 @@ export class Ref extends NamedObject {
|
|
|
137
137
|
return `${this.provider.name}:${this.fullCondensedName}`;
|
|
138
138
|
}
|
|
139
139
|
|
|
140
|
+
/**
|
|
141
|
+
* Same as identifier.
|
|
142
|
+
* @return {string}
|
|
143
|
+
*/
|
|
140
144
|
toString() {
|
|
141
145
|
return this.identifier;
|
|
142
146
|
}
|
package/src/repository.mjs
CHANGED
|
@@ -84,7 +84,7 @@ export class Repository extends NamedObject {
|
|
|
84
84
|
}
|
|
85
85
|
|
|
86
86
|
/**
|
|
87
|
-
*
|
|
87
|
+
* Name of the repo as used in the URL.
|
|
88
88
|
* @return {string}
|
|
89
89
|
*/
|
|
90
90
|
get slug() {
|
|
@@ -166,7 +166,7 @@ export class Repository extends NamedObject {
|
|
|
166
166
|
}
|
|
167
167
|
|
|
168
168
|
/**
|
|
169
|
-
* The url used
|
|
169
|
+
* The url used for cloning the repo.
|
|
170
170
|
* @return {string}
|
|
171
171
|
*/
|
|
172
172
|
get cloneURL() {
|
|
@@ -229,6 +229,15 @@ export class Repository extends NamedObject {
|
|
|
229
229
|
return false;
|
|
230
230
|
}
|
|
231
231
|
|
|
232
|
+
/**
|
|
233
|
+
* Delete the repository from the {@link Provider}.
|
|
234
|
+
* {@link Provider#deleteRepository}
|
|
235
|
+
* @return {Promise<any>}
|
|
236
|
+
*/
|
|
237
|
+
async delete() {
|
|
238
|
+
return this.owner.deleteRepository(this.name);
|
|
239
|
+
}
|
|
240
|
+
|
|
232
241
|
/**
|
|
233
242
|
* Lookup the default branch.
|
|
234
243
|
* @return {Promise<Branch>} branch named after defaultBranchName
|
|
@@ -340,15 +349,6 @@ export class Repository extends NamedObject {
|
|
|
340
349
|
this._tags.set(tag.name, tag);
|
|
341
350
|
}
|
|
342
351
|
|
|
343
|
-
/**
|
|
344
|
-
* Delete the repository from the {@link Provider}.
|
|
345
|
-
* {@link Provider#deleteRepository}
|
|
346
|
-
* @return {Promise<any>}
|
|
347
|
-
*/
|
|
348
|
-
async delete() {
|
|
349
|
-
return this.owner.deleteRepository(this.name);
|
|
350
|
-
}
|
|
351
|
-
|
|
352
352
|
/**
|
|
353
353
|
* Create a pull request (or deliver an already present for thefiven name).
|
|
354
354
|
* @param {string} name of the pr
|
|
@@ -487,9 +487,12 @@ export class Repository extends NamedObject {
|
|
|
487
487
|
* @return {Promise<string>} sha of the ref
|
|
488
488
|
*/
|
|
489
489
|
async refId(ref) {
|
|
490
|
-
return undefined;
|
|
491
490
|
}
|
|
492
491
|
|
|
492
|
+
/**
|
|
493
|
+
* full name.
|
|
494
|
+
* @returns {string}
|
|
495
|
+
*/
|
|
493
496
|
toString() {
|
|
494
497
|
return this.fullName;
|
|
495
498
|
}
|