Skip to content
This repository was archived by the owner on Apr 1, 2024. It is now read-only.

Commit 3b6d8dc

Browse files
authored
Merge pull request #31 from Code-Hex/fix/28
fixed #28
2 parents ce8b84c + fb4a8fd commit 3b6d8dc

File tree

9 files changed

+16021
-6579
lines changed

9 files changed

+16021
-6579
lines changed

example/github/enums.md

Lines changed: 639 additions & 4 deletions
Large diffs are not rendered by default.

example/github/input_objects.md

Lines changed: 1621 additions & 62 deletions
Large diffs are not rendered by default.

example/github/interfaces.md

Lines changed: 556 additions & 2 deletions
Large diffs are not rendered by default.

example/github/mutations.md

Lines changed: 662 additions & 8 deletions
Large diffs are not rendered by default.

example/github/objects.md

Lines changed: 12469 additions & 6486 deletions
Large diffs are not rendered by default.

example/github/queries.md

Lines changed: 8 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -248,6 +248,7 @@ Lookup a given repository by the owner and repository name.
248248

249249
| Name | Description |
250250
|------|-------------|
251+
| followRenames ([Boolean](scalars.md#boolean)) | <p>Follow repository renames. If disabled, a repository referenced by its old name will return an error.</p> |
251252
| name ([String!](scalars.md#string)) | <p>The name of the repository</p> |
252253
| owner ([String!](scalars.md#string)) | <p>The login field of a user or organization</p> |
253254

@@ -370,6 +371,13 @@ Users and organizations who can be sponsored via GitHub Sponsors.
370371
| before ([String](scalars.md#string)) | <p>Returns the elements in the list that come before the specified cursor.</p> |
371372
| dependencyEcosystem ([SecurityAdvisoryEcosystem](enums.md#securityadvisoryecosystem)) | <p>Optional filter for which dependencies should be checked for sponsorable
372373
owners. Only sponsorable owners of dependencies in this ecosystem will be
374+
included. Used when onlyDependencies = true.</p>
375+
376+
<p><strong>Upcoming Change on 2022-07-01 UTC</strong>
377+
<strong>Description:</strong> <code>dependencyEcosystem</code> will be removed. Use the ecosystem argument instead.
378+
<strong>Reason:</strong> The type is switching from SecurityAdvisoryEcosystem to DependencyGraphEcosystem.</p> |
379+
| ecosystem ([DependencyGraphEcosystem](enums.md#dependencygraphecosystem)) | <p>Optional filter for which dependencies should be checked for sponsorable
380+
owners. Only sponsorable owners of dependencies in this ecosystem will be
373381
included. Used when onlyDependencies = true.</p> |
374382
| first ([Int](scalars.md#int)) | <p>Returns the first <em>n</em> elements from the list.</p> |
375383
| last ([Int](scalars.md#int)) | <p>Returns the last <em>n</em> elements from the list.</p> |
@@ -385,20 +393,6 @@ public repositories will be considered.</p> |
385393

386394
---
387395

388-
### sponsorsListing
389-
390-
#### Type: [SponsorsListing](objects.md#sponsorslisting)
391-
392-
Look up a single Sponsors Listing
393-
394-
#### Arguments
395-
396-
| Name | Description |
397-
|------|-------------|
398-
| slug ([String!](scalars.md#string)) | <p>Select the Sponsors listing which matches this slug</p> |
399-
400-
---
401-
402396
### topic
403397

404398
#### Type: [Topic](objects.md#topic)

example/github/scalars.md

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,12 @@
66

77
When calling the GraphQL API, you must specify nested subfields until you return only scalars.
88

9+
### Base64String
10+
11+
<p>A (potentially binary) string encoded using base64.</p>
12+
13+
---
14+
915
### Boolean
1016

1117
<p>The <code>Boolean</code> scalar type represents <code>true</code> or <code>false</code>.</p>
@@ -62,7 +68,7 @@ When calling the GraphQL API, you must specify nested subfields until you return
6268

6369
### ID
6470

65-
<p>The <code>ID</code> scalar type represents a unique identifier, often used to refetch an object or as key for a cache. The ID type appears in a JSON response as a String; however, it is not intended to be human-readable. When expected as an input type, any string (such as <code>&quot;4&quot;</code>) or integer (such as <code>4</code>) input value will be accepted as an ID.</p>
71+
<p>The <code>ID</code> scalar type represents a unique identifier, often used to refetch an object or as key for a cache. The ID type appears in a JSON response as a String; however, it is not intended to be human-readable. When expected as an input type, any string (such as &ldquo;4&rdquo;) or integer (such as 4) input value will be accepted as an ID.</p>
6672

6773
---
6874

@@ -80,7 +86,7 @@ When calling the GraphQL API, you must specify nested subfields until you return
8086

8187
### String
8288

83-
<p>The <code>String</code> scalar type represents textual data, represented as UTF-8 character sequences. The String type is most often used by GraphQL to represent free-form human-readable text.</p>
89+
<p>The <code>String</code>scalar type represents textual data, represented as UTF-8 character sequences. The String type is most often used by GraphQL to represent free-form human-readable text.</p>
8490

8591
---
8692

example/github/unions.md

Lines changed: 54 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,18 @@ A [union](https://graphql.github.io/graphql-spec/June2018/#sec-Unions) is a type
3131

3232
---
3333

34+
### BranchActorAllowanceActor
35+
36+
<p>Types which can be actors for <code>BranchActorAllowance</code> objects.</p>
37+
38+
### Possible types
39+
40+
41+
- [Team](objects.md#team)
42+
- [User](objects.md#user)
43+
44+
---
45+
3446
### Closer
3547

3648
<p>The object which triggered a <code>ClosedEvent</code>.</p>
@@ -79,6 +91,18 @@ A [union](https://graphql.github.io/graphql-spec/June2018/#sec-Unions) is a type
7991

8092
---
8193

94+
### DeploymentReviewer
95+
96+
<p>Users and teams.</p>
97+
98+
### Possible types
99+
100+
101+
- [Team](objects.md#team)
102+
- [User](objects.md#user)
103+
104+
---
105+
82106
### EnterpriseMember
83107

84108
<p>An object that is a member of an enterprise.</p>
@@ -98,6 +122,7 @@ A [union](https://graphql.github.io/graphql-spec/June2018/#sec-Unions) is a type
98122
### Possible types
99123

100124

125+
- [App](objects.md#app)
101126
- [Enterprise](objects.md#enterprise)
102127
- [Organization](objects.md#organization)
103128

@@ -157,6 +182,7 @@ A [union](https://graphql.github.io/graphql-spec/June2018/#sec-Unions) is a type
157182
- [CommentDeletedEvent](objects.md#commentdeletedevent)
158183
- [ConnectedEvent](objects.md#connectedevent)
159184
- [ConvertedNoteToIssueEvent](objects.md#convertednotetoissueevent)
185+
- [ConvertedToDiscussionEvent](objects.md#convertedtodiscussionevent)
160186
- [CrossReferencedEvent](objects.md#crossreferencedevent)
161187
- [DemilestonedEvent](objects.md#demilestonedevent)
162188
- [DisconnectedEvent](objects.md#disconnectedevent)
@@ -309,6 +335,18 @@ A [union](https://graphql.github.io/graphql-spec/June2018/#sec-Unions) is a type
309335
### Possible types
310336

311337

338+
- [Issue](objects.md#issue)
339+
- [PullRequest](objects.md#pullrequest)
340+
341+
---
342+
343+
### ProjectNextItemContent
344+
345+
<p>Types that can be inside Project Items.</p>
346+
347+
### Possible types
348+
349+
312350
- [Issue](objects.md#issue)
313351
- [PullRequest](objects.md#pullrequest)
314352

@@ -380,6 +418,7 @@ A [union](https://graphql.github.io/graphql-spec/June2018/#sec-Unions) is a type
380418
- [ConnectedEvent](objects.md#connectedevent)
381419
- [ConvertToDraftEvent](objects.md#converttodraftevent)
382420
- [ConvertedNoteToIssueEvent](objects.md#convertednotetoissueevent)
421+
- [ConvertedToDiscussionEvent](objects.md#convertedtodiscussionevent)
383422
- [CrossReferencedEvent](objects.md#crossreferencedevent)
384423
- [DemilestonedEvent](objects.md#demilestonedevent)
385424
- [DeployedEvent](objects.md#deployedevent)
@@ -435,6 +474,20 @@ A [union](https://graphql.github.io/graphql-spec/June2018/#sec-Unions) is a type
435474

436475
---
437476

477+
### Reactor
478+
479+
<p>Types that can be assigned to reactions.</p>
480+
481+
### Possible types
482+
483+
484+
- [Bot](objects.md#bot)
485+
- [Mannequin](objects.md#mannequin)
486+
- [Organization](objects.md#organization)
487+
- [User](objects.md#user)
488+
489+
---
490+
438491
### ReferencedSubject
439492

440493
<p>Any referencable object</p>
@@ -492,6 +545,7 @@ A [union](https://graphql.github.io/graphql-spec/June2018/#sec-Unions) is a type
492545

493546

494547
- [App](objects.md#app)
548+
- [Discussion](objects.md#discussion)
495549
- [Issue](objects.md#issue)
496550
- [MarketplaceListing](objects.md#marketplacelisting)
497551
- [Organization](objects.md#organization)

internal/markdown/markdown.go

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,10 @@ type Config struct {
2424
}
2525

2626
func (m *Config) Create(filename string) (*os.File, error) {
27-
dest := filepath.Join(m.BaseDir, filename)
27+
dest, err := filepath.Abs(filepath.Join(m.BaseDir, filename))
28+
if err != nil {
29+
return nil, errors.WithStack(err)
30+
}
2831
return os.Create(dest)
2932
}
3033

0 commit comments

Comments
 (0)