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

feat: support Git actionButton and improve style #1702

Merged
merged 10 commits into from
Oct 14, 2022

Conversation

erha19
Copy link
Member

@erha19 erha19 commented Sep 21, 2022

Types

  • 🎉 New Features
  • 🐛 Bug Fixes
  • 💄 Style Changes

Background or solution

close #1700.
close #1684.
close #1688.
close #1365.
close #378.
close #1389.

解决了 Git 面板提交失败后提交信息被清空的问题, 支持了 vscode.git 插件 1.62.3 以上版本对 actionButton 的处理,如果升级到该变更版本,需要同时升级 Git 插件至 1.62.3 +

针对空仓库的 Publish Change 功能,插件代码还依赖 GitHub 账号能力已实现创建仓库功能,该功能目前框架下会不可用,但暂时不会影响产品功能。

image

同时,目前由于 OpenVSX 市场不再更新内置插件的原因,无法支持最新版本的 Git 插件安装,得等后续插件市场上线。

Changelog

  • support Git actionButton and improve style

@erha19
Copy link
Member Author

erha19 commented Sep 22, 2022

新版本 Git 插件对于 GitHub 鉴权接口有强依赖,如果集成侧不实现会有如下报错:
image

[extHost:error] [error] get session had a error No authentication provider 'github' is currently registered. 

可以在集成侧通过关闭 Action 配置项的方式关闭该功能:

1.62.3, 设置 git.showUnpublishedCommitsButton=false , 在该提交后修改,暂时无法确认对应 Git 插件哪个版本 extensions/git/src/repository.ts

1.65.0+, 设置 git.showActionButton={commit: false, sync: false, push: false}, 见 actionButton.ts#L73

@erha19
Copy link
Member Author

erha19 commented Sep 22, 2022

支持了 actionButton.enabled 属性:
image

@codecov
Copy link

codecov bot commented Sep 22, 2022

Codecov Report

Base: 57.59% // Head: 57.56% // Decreases project coverage by -0.02% ⚠️

Coverage data is based on head (df697d1) compared to base (4906df1).
Patch coverage: 33.84% of modified lines in pull request are covered.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1702      +/-   ##
==========================================
- Coverage   57.59%   57.56%   -0.03%     
==========================================
  Files        1283     1283              
  Lines       80035    80058      +23     
  Branches    16774    16773       -1     
==========================================
- Hits        46093    46087       -6     
- Misses      30873    30900      +27     
- Partials     3069     3071       +2     
Flag Coverage Δ
jsdom 52.43% <33.84%> (-0.03%) ⬇️
node 15.79% <1.53%> (-0.01%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
...n/src/browser/vscode/api/main.thread.decoration.ts 45.16% <0.00%> (ø)
...xtension/src/browser/vscode/api/main.thread.scm.ts 6.72% <0.00%> (-0.03%) ⬇️
packages/extension/src/common/vscode/scm.ts 57.14% <ø> (ø)
...es/extension/src/hosted/api/vscode/ext.host.scm.ts 4.03% <0.00%> (-0.15%) ⬇️
.../src/hosted/api/vscode/ext.host.window.api.impl.ts 12.40% <ø> (-2.22%) ⬇️
packages/scm/src/common/scm.ts 100.00% <ø> (ø)
packages/utils/src/arrays.ts 75.15% <11.11%> (-3.70%) ⬇️
...nsion/src/hosted/api/vscode/ext.host.decoration.ts 80.00% <63.63%> (-1.82%) ⬇️
...tension/src/hosted/api/vscode/env/envApiFactory.ts 78.26% <0.00%> (-4.35%) ⬇️
packages/utils/src/buffer.ts 33.13% <0.00%> (-1.75%) ⬇️
... and 4 more

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

☔ View full report at Codecov.
📢 Do you have feedback about the report comment? Let us know in this issue.

@Ricbet
Copy link
Member

Ricbet commented Sep 22, 2022

/publish

1 similar comment
@Ricbet
Copy link
Member

Ricbet commented Sep 26, 2022

/publish

@erha19
Copy link
Member Author

erha19 commented Sep 26, 2022

对于 Auth 鉴权依赖那块,有个想法,是否可以通过集成侧的服务实现方式,绕开对于完整 Auth 校验链路的要求,例如集成侧准备好用户 GitHub 信息,通过覆盖逻辑的方式绕开需要与 github.com 交互的内容

@Ricbet
Copy link
Member

Ricbet commented Sep 26, 2022

对于 Auth 鉴权依赖那块,有个想法,是否可以通过集成侧的服务实现方式,绕开对于完整 Auth 校验链路的要求,例如集成侧准备好用户 GitHub 信息,通过覆盖逻辑的方式绕开需要与 github.com 交互的内容

啥意思?是指集成方不需要实现 authentication provider 了吗

@erha19
Copy link
Member Author

erha19 commented Sep 26, 2022

啥意思?是指集成方不需要实现 authentication provider 了吗

应该还是要实现 authentication provider,只是把相应逻辑支持一下集成侧定制

@erha19
Copy link
Member Author

erha19 commented Sep 27, 2022

/publish

@github-actions
Copy link
Contributor

🎉 PR Next version 2.20.3-next-1664271328.0 publish successful! You can install prerelease version via npm install package@2.20.3-next-1664271328.0 @erha19

2.20.3-next-1664271328.0

@erha19 erha19 mentioned this pull request Oct 12, 2022
55 tasks
@erha19 erha19 force-pushed the feat/scm/support-action-button branch from a633e1e to 85a42e1 Compare October 13, 2022 09:32
Copy link
Member

@Ricbet Ricbet left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@erha19 erha19 merged commit 9261550 into main Oct 14, 2022
@erha19 erha19 deleted the feat/scm/support-action-button branch October 14, 2022 02:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment