Skip to content
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

gitee #16

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions github_client_app/.flutter-plugins-dependencies
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
{"info":"This is a generated file; do not edit or check into version control.","plugins":{"ios":[{"name":"fluttertoast","path":"/Users/yiliang/installation/flutter/.pub-cache/hosted/pub.flutter-io.cn/fluttertoast-3.1.3/","dependencies":[]},{"name":"path_provider","path":"/Users/yiliang/installation/flutter/.pub-cache/hosted/pub.flutter-io.cn/path_provider-1.6.11/","dependencies":[]},{"name":"shared_preferences","path":"/Users/yiliang/installation/flutter/.pub-cache/hosted/pub.flutter-io.cn/shared_preferences-0.5.8/","dependencies":[]},{"name":"sqflite","path":"/Users/yiliang/installation/flutter/.pub-cache/hosted/pub.flutter-io.cn/sqflite-1.3.1/","dependencies":[]}],"android":[{"name":"fluttertoast","path":"/Users/yiliang/installation/flutter/.pub-cache/hosted/pub.flutter-io.cn/fluttertoast-3.1.3/","dependencies":[]},{"name":"path_provider","path":"/Users/yiliang/installation/flutter/.pub-cache/hosted/pub.flutter-io.cn/path_provider-1.6.11/","dependencies":[]},{"name":"shared_preferences","path":"/Users/yiliang/installation/flutter/.pub-cache/hosted/pub.flutter-io.cn/shared_preferences-0.5.8/","dependencies":[]},{"name":"sqflite","path":"/Users/yiliang/installation/flutter/.pub-cache/hosted/pub.flutter-io.cn/sqflite-1.3.1/","dependencies":[]}],"macos":[{"name":"path_provider_macos","path":"/Users/yiliang/installation/flutter/.pub-cache/hosted/pub.flutter-io.cn/path_provider_macos-0.0.4+3/","dependencies":[]},{"name":"shared_preferences_macos","path":"/Users/yiliang/installation/flutter/.pub-cache/hosted/pub.flutter-io.cn/shared_preferences_macos-0.0.1+10/","dependencies":[]},{"name":"sqflite","path":"/Users/yiliang/installation/flutter/.pub-cache/hosted/pub.flutter-io.cn/sqflite-1.3.1/","dependencies":[]}],"linux":[{"name":"path_provider_linux","path":"/Users/yiliang/installation/flutter/.pub-cache/hosted/pub.flutter-io.cn/path_provider_linux-0.0.1+2/","dependencies":[]},{"name":"shared_preferences_linux","path":"/Users/yiliang/installation/flutter/.pub-cache/hosted/pub.flutter-io.cn/shared_preferences_linux-0.0.2+1/","dependencies":["path_provider_linux"]}],"windows":[],"web":[{"name":"shared_preferences_web","path":"/Users/yiliang/installation/flutter/.pub-cache/hosted/pub.flutter-io.cn/shared_preferences_web-0.1.2+7/","dependencies":[]}]},"dependencyGraph":[{"name":"fluttertoast","dependencies":[]},{"name":"path_provider","dependencies":["path_provider_macos","path_provider_linux"]},{"name":"path_provider_linux","dependencies":[]},{"name":"path_provider_macos","dependencies":[]},{"name":"shared_preferences","dependencies":["shared_preferences_linux","shared_preferences_macos","shared_preferences_web"]},{"name":"shared_preferences_linux","dependencies":["path_provider_linux"]},{"name":"shared_preferences_macos","dependencies":[]},{"name":"shared_preferences_web","dependencies":[]},{"name":"sqflite","dependencies":[]}],"date_created":"2020-07-28 13:21:09.002757","version":"1.17.5"}
8 changes: 8 additions & 0 deletions github_client_app/README.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,11 @@
# 将登录不了的git客户端修改为了gitee客户端
1、文字国际化修改为gitee
2、修改json、实体更换为gitee用户、repo改为gitee返回格式
3、新增 giteeClient.json、access.json
4、在登录时,填写gitee 应用数据。并且持久化处理
# 需要自己的码云创建一个第三应用登录的授权
- [https://gitee.com/api/v5/oauth_doc#/list-item-3](https://gitee.com/api/v5/oauth_doc#/list-item-3)

# github_client_app

A Github client APP built with Flutter
Expand Down
9 changes: 4 additions & 5 deletions github_client_app/ios/Flutter/flutter_export_environment.sh
Original file line number Diff line number Diff line change
@@ -1,12 +1,11 @@
#!/bin/sh
# This is a generated file; do not edit or check into version control.
export "FLUTTER_ROOT=/Users/duwen/Documents/flutter"
export "FLUTTER_APPLICATION_PATH=/Users/duwen/Documents/code/flutter_in_action/github_client_app"
export "FLUTTER_TARGET=/Users/duwen/Documents/code/flutter_in_action/github_client_app/lib/main.dart"
export "FLUTTER_ROOT=/Users/yiliang/installation/flutter"
export "FLUTTER_APPLICATION_PATH=/Users/yiliang/AndroidStudioProjects/git_demo/flutter_in_action_source_code/github_client_app"
export "FLUTTER_TARGET=lib/main.dart"
export "FLUTTER_BUILD_DIR=build"
export "SYMROOT=${SOURCE_ROOT}/../build/ios"
export "OTHER_LDFLAGS=$(inherited) -framework Flutter"
export "FLUTTER_FRAMEWORK_DIR=/Users/duwen/Documents/flutter/bin/cache/artifacts/engine/ios"
export "FLUTTER_FRAMEWORK_DIR=/Users/yiliang/installation/flutter/bin/cache/artifacts/engine/ios"
export "FLUTTER_BUILD_NAME=1.0.0"
export "FLUTTER_BUILD_NUMBER=1"
export "TRACK_WIDGET_CREATION=true"
8 changes: 8 additions & 0 deletions github_client_app/jsons/access.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
{
"access_token": "",
"token_type": "",
"expires_in": 86400,
"refresh_token": "",
"scope": "projects user_info issues notes",
"created_at": 1595902217
}
4 changes: 4 additions & 0 deletions github_client_app/jsons/giteeClient.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"client_id": "",
"client_secret": ""
}
1 change: 1 addition & 0 deletions github_client_app/jsons/profile.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
{
"user":"$user",
"giteeClient": "$giteeClient",
"token":"",
"theme":5678,
"cache":"$cacheConfig",
Expand Down
106 changes: 67 additions & 39 deletions github_client_app/jsons/repo.json
Original file line number Diff line number Diff line change
@@ -1,46 +1,74 @@
{
"id": 1296269,
"name": "Hello-World",
"full_name": "octocat/Hello-World",
"id": 123,
"full_name": "",
"human_name": "",
"url": "",
"namespace": {
"id": 123,
"type": "",
"name": "",
"path": "",
"html_url": ""
},
"path": "",
"name": "",
"owner": "$user",
"parent":"$repo",
"private": false,
"html_url": "https://github.com/octocat/Hello-World",
"description": "This your first repo!",
"description": "",
"private": true,
"public": false,
"internal": false,
"fork": false,
"homepage": "https://github.com",
"language": "JavaScript",
"forks_count": 9,
"stargazers_count": 80,
"watchers_count": 80,
"size": 108,
"default_branch": "master",
"open_issues_count": 0,
"topics": [
"octocat",
"atom",
"electron",
"API"
],
"html_url": "",
"ssh_url": "",
"forks_url": "",
"keys_url": "",
"collaborators_url": "",
"hooks_url": "",
"branches_url": "",
"tags_url": "",
"blobs_url": "",
"stargazers_url": "",
"contributors_url": "",
"commits_url": "",
"comments_url": "",
"issue_comment_url": "",
"issues_url": "",
"pulls_url": "",
"milestones_url": "",
"notifications_url": "",
"labels_url": "",
"releases_url": "",
"recommend": false,
"homepage": "",
"language": "",
"forks_count": 0,
"stargazers_count": 0,
"watchers_count": 3,
"default_branch": "",
"open_issues_count": 1,
"has_issues": true,
"has_projects": true,
"has_wiki": true,
"has_pages": false,
"has_downloads": true,
"pushed_at": "2011-01-26T19:06:43Z",
"created_at": "2011-01-26T19:01:12Z",
"updated_at": "2011-01-26T19:14:43Z",
"permissions": {
"admin": false,
"push": false,
"pull": true
"issue_comment": false,
"can_comment": true,
"pull_requests_enabled": true,
"has_page": false,
"license": null,
"outsourced": false,
"project_creator": "",
"members": [
"SUNbrightness"
],
"pushed_at": "",
"created_at": "",
"updated_at": "",
"parent": null,
"paas": null,
"stared": false,
"watched": true,
"permission": {
"pull": true,
"push": true,
"admin": false
},
"subscribers_count": 42,
"license": {
"key": "mit",
"name": "MIT License",
"spdx_id": "MIT",
"url": "https://api.github.com/licenses/mit",
"node_id": "MDc6TGljZW5zZW1pdA=="
}
"relation": ""
}
47 changes: 27 additions & 20 deletions github_client_app/jsons/user.json
Original file line number Diff line number Diff line change
@@ -1,23 +1,30 @@
{
"login": "octocat",
"id": 1,
"avatar_url": "https://github.com/images/error/octocat_happy.gif",
"url": "https://api.github.com/users/octocat",
"id": 123,
"login": "SUNbrightness",
"name": "sunshine",
"avatar_url": "",
"url": "",
"html_url": "",
"followers_url": "",
"following_url": "",
"gists_url": "",
"starred_url": "",
"subscriptions_url": "",
"organizations_url": "",
"repos_url": "",
"events_url": "",
"received_events_url": "",
"type": "User",
"site_admin": false,
"name": "monalisa octocat",
"company": "GitHub",
"blog": "https://github.com/blog",
"location": "San Francisco",
"email": "[email protected]",
"hireable": false,
"bio": "There once was...",
"public_repos": 2,
"public_gists": 1,
"followers": 20,
"blog": null,
"weibo": null,
"bio": null,
"public_repos": 5,
"public_gists": 0,
"followers": 0,
"following": 0,
"created_at": "2008-01-14T04:33:35Z",
"updated_at": "2008-01-14T04:33:35Z",
"total_private_repos": 100,
"owned_private_repos": 100
}
"stared": 7,
"watched": 35,
"created_at": "2018-06-03T09:12:18+08:00",
"updated_at": "2020-07-28T09:46:36+08:00",
"email": null
}
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
{
"@@last_modified": "2019-08-11T18:39:59.060353",
"@@last_modified": "2020-07-28T10:49:02.499268",
"title": "Flutter APP",
"@title": {
"description": "Title for the Demo application",
"type": "text",
"placeholders": {}
},
"home": "Github",
"home": "Gitee",
"@home": {
"type": "text",
"placeholders": {}
Expand Down Expand Up @@ -61,6 +61,16 @@
"type": "text",
"placeholders": {}
},
"clientIdRequired": "clientId required!",
"@clientIdRequired": {
"type": "text",
"placeholders": {}
},
"clientSecretRequired": "clientSecret required!",
"@clientSecretRequired": {
"type": "text",
"placeholders": {}
},
"userNameOrPasswordWrong": "User name or password is not correct!",
"@userNameOrPasswordWrong": {
"type": "text",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
"type": "text",
"placeholders": {}
},
"home": "Github客户端",
"home": "码云客户端",
"@home": {
"type": "text",
"placeholders": {}
Expand Down Expand Up @@ -61,6 +61,16 @@
"type": "text",
"placeholders": {}
},
"clientIdRequired": "clientId 不能为空!",
"@clientIdRequired": {
"type": "text",
"placeholders": {}
},
"clientSecretRequired": "clientSecret 不能为空!",
"@clientSecretRequired": {
"type": "text",
"placeholders": {}
},
"userNameOrPasswordWrong": "用户名或密码不正确",
"@userNameOrPasswordWrong": {
"type": "text",
Expand Down
Loading