-
-
Notifications
You must be signed in to change notification settings - Fork 5.9k
Add support to import repository data from an exported data of Github #18165
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Draft
lunny
wants to merge
72
commits into
go-gitea:main
Choose a base branch
from
lunny:lunny/import_github_export_data
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Draft
Changes from 1 commit
Commits
Show all changes
72 commits
Select commit
Hold shift + click to select a range
87f508e
Add support to import repository data from an exported data of Github
lunny 69ef887
Review comments
lunny 9baecbf
add asset supports
lunny ca66095
Add more tests
lunny e026523
some improvements
lunny 4fb0a78
fix dump
lunny b41f533
Add version check
lunny 7d31829
more tests
lunny 14a9677
Fix some bugs
lunny 8ddde32
Fix bug
lunny 6adb90f
improve get reviews
lunny 3e7f20d
Fix lint
lunny acf3985
Fix review
lunny e5726ed
Improve some comments
lunny 1c77daf
Fix label and milestone comments
lunny 5d7577e
Fix close comment
lunny 392f1f1
Fix bug
lunny 712145f
Fix bugs when importing
lunny daca6ee
Fix bugs when importing
lunny e874444
Fix opened pull request
lunny d2bce40
Ignore reference comments
lunny 0d6a1ea
improve pull view
lunny 426effb
Fix bug
lunny 81fe056
Fix bug
lunny ae8fe0c
add trace log
lunny 0ca2dab
Improve some missed review
lunny 95aa21c
Fix build
lunny f70f7d2
Fix lint
lunny 1241095
Fix bug
lunny d52c8f1
Fix bug
lunny 8ee93ed
Fix bug
lunny c201d75
Fix comment
lunny 473ca7c
Some improvements
lunny 4a7505e
rename getID to parseGitHubResID
lunny 549230c
Some improvements
lunny 1c99455
Use regex to replace commit hash and issue/pull
lunny 8e7d9a3
upload assets and replace the links in issue/comment/pullrequest
lunny 20f30f1
Fix lint
lunny cc964e7
fix upload attachment
lunny 2e516b5
Fix lint
lunny cc2d527
Fix bug
lunny d76ff4f
Fix bug
lunny e806f19
Ignore unsupported event
lunny 46d8251
Merge
lunny f10b3de
Fix lint
lunny eef99f6
Merge
lunny b78ad20
Revert changes on updateGitForPullRequest
lunny 0ab78e9
Improve pr check
lunny d52fac0
Fix test
lunny 98065f8
Fix test
lunny fd9fdf7
Merge main branch
lunny dbed616
Merge branch 'main' into lunny/import_github_export_data
lunny a15d33f
Fix lint
lunny 8f37261
Merge branch 'main' into lunny/import_github_export_data
lunny 6ef5aa4
Merge branch 'main' into lunny/import_github_export_data
lunny 2f31ed5
Merge main branch
lunny 44b3ee6
Merge branch 'main' into lunny/import_github_export_data
6543 171aa9b
Merge branch 'main' into lunny/import_github_export_data
6543 893085d
Merge branch 'main' into lunny/import_github_export_data
lunny 1d45f83
Merge branch 'main' into lunny/import_github_export_data
lunny cb691fa
Merge branch 'lunny/import_github_export_data' of github.com:lunny/gi…
lunny 7596f9b
Merge branch 'main' into lunny/import_github_export_data
lunny 80f225e
Merge branch 'main' into lunny/import_github_export_data
6543 73e1a93
Merge main branch
lunny 77b40c9
Merge branch 'lunny/import_github_export_data' of github.com:lunny/gi…
lunny 5fc7a6e
Merge branch 'main' into lunny/import_github_export_data
6543 468fe45
Fix check
lunny 8cbf15b
Merge branch 'main' into lunny/import_github_export_data
lunny 6688205
Merge branch 'lunny/import_github_export_data' of github.com:lunny/gi…
lunny 201aae0
Merge branch 'main' into lunny/import_github_export_data
wolfogre f2ed8b1
chore: lint codes
wolfogre 61c6403
chore: revert intended rm
wolfogre File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
upload assets and replace the links in issue/comment/pullrequest
- Loading branch information
commit 8e7d9a3289afeb1bc663b58ea063ca33d95edecf
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
// Copyright 2022 The Gitea Authors. All rights reserved. | ||
// Use of this source code is governed by a MIT-style | ||
// license that can be found in the LICENSE file. | ||
|
||
package migration | ||
|
||
import ( | ||
"io" | ||
"time" | ||
) | ||
|
||
// Asset represents an asset for issue, comment, release | ||
type Asset struct { | ||
ID int64 | ||
Name string | ||
ContentType *string `yaml:"content_type"` | ||
Size *int | ||
DownloadCount *int `yaml:"download_count"` | ||
Created time.Time | ||
Updated time.Time | ||
DownloadURL *string `yaml:"download_url"` | ||
OriginalURL string | ||
// if DownloadURL is nil, the function should be invoked | ||
DownloadFunc func() (io.ReadCloser, error) `yaml:"-"` | ||
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.