Skip to content

Commit

Permalink
- 允许在非信任工作区使用该插件
Browse files Browse the repository at this point in the history
- Gist文件使用自身文件类型图标
- 修复某些情况下无法打开Gist文件
  • Loading branch information
itldg committed Apr 29, 2022
1 parent 9e05b0a commit 6654114
Show file tree
Hide file tree
Showing 4 changed files with 21 additions and 4 deletions.
12 changes: 11 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,15 @@

- 列表搜索代码片段

## [0.0.6] - 2022-04-29

### Changed
- 允许在非信任工作区使用该插件
- Gist文件使用自身文件类型图标

### Fixed
- 修复某些情况下无法打开Gist文件

## [0.0.5] - 2022-04-28

### Changed
Expand Down Expand Up @@ -57,7 +66,8 @@
- 修改评论
- 删除评论

[unreleased]: https://github.com/wanglong126/vscode-ldggist/compare/v0.0.5...HEAD
[unreleased]: https://github.com/wanglong126/vscode-ldggist/compare/v0.0.6...HEAD
[0.0.6]: https://github.com/wanglong126/vscode-ldggist/compare/v0.0.5...v0.0.6
[0.0.5]: https://github.com/wanglong126/vscode-ldggist/compare/v0.0.4...v0.0.5
[0.0.4]: https://github.com/wanglong126/vscode-ldggist/compare/v0.0.3...v0.0.4
[0.0.3]: https://github.com/wanglong126/vscode-ldggist/compare/v0.0.2...v0.0.3
Expand Down
8 changes: 7 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"displayName": "LdgGist",
"publisher": "itldg",
"description": "基于Gitee和GitHub的代码片段管理工具",
"version": "0.0.5",
"version": "0.0.6",
"icon": "resources/logo.png",
"engines": {
"vscode": "^1.65.0"
Expand Down Expand Up @@ -244,6 +244,12 @@
}
}
},
"capabilities": {
"untrustedWorkspaces": {
"supported": true
},
"virtualWorkspaces": true
},
"scripts": {
"vscode:prepublish": "npm run compile",
"compile": "tsc -p ./",
Expand Down
2 changes: 1 addition & 1 deletion src/api/gistServer.ts
Original file line number Diff line number Diff line change
Expand Up @@ -498,7 +498,7 @@ export default class GistServer {
try {
// 检测文件是否已存在
fs.accessSync(filePath);
agreement = "file://";
agreement = "file:";
} catch (error) {
agreement = "untitled:";
}
Expand Down
3 changes: 2 additions & 1 deletion src/tree/gistTreeItem.ts
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@ export class GistFileTreeItem extends TreeItem {
constructor(info: GistFile, filename:string, gist: Gist) {
super(filename, TreeItemCollapsibleState.None);
this.description = info.language ? info.language :Util.byteConvert( <number>info.size);
this.resourceUri=Uri.parse(filename);
this.gist=gist;
this.command={
title: String(filename),
Expand All @@ -54,7 +55,7 @@ export class GistFileTreeItem extends TreeItem {
]
};
}
iconPath = new ThemeIcon('file-code');
iconPath = ThemeIcon.File;
contextValue = "gistFile";
}

Expand Down

0 comments on commit 6654114

Please sign in to comment.