Skip to content

Commit 34535c1

Browse files
authored
v3.23.13 revision
v3.23.13 revision
2 parents c806363 + 43afe3c commit 34535c1

File tree

7 files changed

+31
-13
lines changed

7 files changed

+31
-13
lines changed

CHANGELOG.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,13 @@ All notable version changes will be recorded in this file.
66

77
***
88

9+
### [v3.23.13] revision
10+
11+
**Improve**:
12+
- `Create Project`: Miscellaneous things. (init project files, init project settings ... etc.)
13+
14+
***
15+
916
### [v3.23.12] revision
1017

1118
**Improve**:

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@
3636
"homepage": "https://em-ide.com",
3737
"license": "MIT",
3838
"description": "A mcu development environment for 8051/AVR/STM8/Cortex-M/MIPS/RISC-V",
39-
"version": "3.23.12",
39+
"version": "3.23.13",
4040
"preview": false,
4141
"engines": {
4242
"vscode": "^1.67.0"

res/data/.clang-format

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
BasedOnStyle: Microsoft
3-
Language: Cpp
3+
Language: C
44

55
###################################
66
# indent conf

src/EIDEProject.ts

Lines changed: 16 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -3620,6 +3620,14 @@ class EIDEProject extends AbstractProject {
36203620

36213621
// --- vscode settings
36223622

3623+
// 避免 msys bash 出现 cygpath 问题
3624+
if (SettingManager.instance().isEnableMsys())
3625+
settings['terminal.integrated.shellIntegration.enabled'] = false;
3626+
3627+
// 默认不要自动插入 header
3628+
if (settings["clangd.arguments"] == undefined)
3629+
settings["clangd.arguments"] = ["--header-insertion=never"];
3630+
36233631
if (settings['files.autoGuessEncoding'] === undefined) {
36243632
settings['files.autoGuessEncoding'] = true;
36253633
}
@@ -3731,13 +3739,13 @@ class EIDEProject extends AbstractProject {
37313739
GlobalEvent.emit('msg', ExceptionToMessage(error, 'Hidden'));
37323740
}
37333741

3734-
// gen default 'settings.json'
3735-
try {
3736-
const settingsFile = File.fromArray([this.GetRootDir().path, AbstractProject.vsCodeDir, 'settings.json']);
3737-
if (!settingsFile.IsFile()) { settingsFile.Write('{}'); }
3738-
} catch (error) {
3739-
// nothing todo
3740-
}
3742+
// // gen default 'settings.json'
3743+
// try {
3744+
// const settingsFile = File.fromArray([this.GetRootDir().path, AbstractProject.vsCodeDir, 'settings.json']);
3745+
// if (!settingsFile.IsFile()) { settingsFile.Write('{}'); }
3746+
// } catch (error) {
3747+
// // nothing todo
3748+
// }
37413749

37423750
// add extension recommendation
37433751
{
@@ -3750,8 +3758,7 @@ class EIDEProject extends AbstractProject {
37503758
"redhat.vscode-yaml",
37513759
"IBM.output-colorizer",
37523760
"cschlosser.doxdocgen",
3753-
"ms-vscode.vscode-serial-monitor",
3754-
"alefragnani.project-manager"
3761+
"ms-vscode.vscode-serial-monitor"
37553762
];
37563763

37573764
const prjInfo = this.GetConfiguration().config;

src/EIDEProjectExplorer.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1373,6 +1373,7 @@ class ProjectDataProvider implements vscode.TreeDataProvider<ProjTreeItem>, vsco
13731373
}
13741374
}
13751375
break;
1376+
// The edit setting value's callback is in @ref ModifyOtherSettings(...)
13761377
case TreeItemType.SETTINGS:
13771378
{
13781379
const config = project.GetConfiguration();
@@ -3986,7 +3987,7 @@ export class ProjectExplorer implements CustomConfigurationProvider {
39863987
//
39873988
cfg['CompileFlags']['CompilationDatabase'] = './' + File.ToUnixPath(prj.getOutputDir());
39883989
const toolchain = prj.getToolchain();
3989-
const gccLikePath = toolchain.getGccFamilyCompilerPathForCpptools('c++');
3990+
const gccLikePath = toolchain.getGccFamilyCompilerPathForCpptools('c');
39903991
if (gccLikePath) { // clangd 仅兼容gcc的编译器
39913992
cfg['CompileFlags']['Compiler'] = gccLikePath;
39923993
let clangdCompileFlags = <string[]>(cfg['CompileFlags']['Add']);

src/Platform.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -169,7 +169,7 @@ export function GetUUID(): string {
169169
const list = buf.match(/[a-zA-Z0-9]{8}-[a-zA-Z0-9]{4}-[a-zA-Z0-9]{4}-[a-zA-Z0-9]{4}-[a-zA-Z0-9]{12}/);
170170
uuid = list ? list[0] : UUID_NULL;
171171
} else {
172-
uuid = child_process.execSync(`cat /proc/sys/kernel/random/uuid`).toString().trim();
172+
uuid = 'machine-id-' + child_process.execSync(`cat /etc/machine-id`).toString().trim();
173173
}
174174
} catch (error) {
175175
uuid = UUID_NULL;

src/ResManager.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -259,6 +259,9 @@ export class ResManager extends events.EventEmitter {
259259
}
260260
}
261261

262+
/**
263+
* 按照文件名字,在 /tmp/EIDE 目录下寻找缓存的临时文件
264+
*/
262265
getCachedFileByName(name: string): File {
263266
return new File(this.GetTmpDir().path + File.sep + name);
264267
}

0 commit comments

Comments
 (0)