mirror of
https://github.com/arduino/arduino-ide.git
synced 2025-11-11 19:29:28 +00:00
Open Save as... dialog when saving sketches for the first time (#579)
* Properly recognize temporary sketches in macOS Without this fix, sketches report their URI path as /private/var/xxx whereas `os.tmpdir()` returns /var/xxx. The second path can be turned into the first by resolving symlinks, which gives a canonical path to compare against. * Open Save as... dialog when saving sketches for the first time
This commit is contained in:
@@ -387,7 +387,7 @@ void loop() {
|
||||
|
||||
async isTemp(sketch: Sketch): Promise<boolean> {
|
||||
let sketchPath = FileUri.fsPath(sketch.uri);
|
||||
let temp = os.tmpdir();
|
||||
let temp = await promisify(fs.realpath)(os.tmpdir());
|
||||
// Note: VS Code URI normalizes the drive letter. `C:` will be converted into `c:`.
|
||||
// https://github.com/Microsoft/vscode/issues/68325#issuecomment-462239992
|
||||
if (isWindows) {
|
||||
|
||||
Reference in New Issue
Block a user