From 4806578c9b082126046fe066a5c824b5643dd6f5 Mon Sep 17 00:00:00 2001 From: Tobias Reiher Date: Tue, 7 Jan 2025 09:12:00 +0100 Subject: [PATCH] Fix display of message graphs in VS Code Ref. eng/recordflux/RecordFlux#1838, AdaCore/RecordFlux#1307 --- .gitlab/issue_templates/Release.md | 4 +++- CHANGELOG.md | 7 +++++++ rflx/ide/vscode/src/common/constants.ts | 3 +-- rflx/ide/vscode/src/server.ts | 2 +- 4 files changed, 12 insertions(+), 4 deletions(-) diff --git a/.gitlab/issue_templates/Release.md b/.gitlab/issue_templates/Release.md index f3cef3a56..0970e1b3b 100644 --- a/.gitlab/issue_templates/Release.md +++ b/.gitlab/issue_templates/Release.md @@ -1,5 +1,7 @@ - [ ] Test GNAT Studio plugin - - Check verification, generation and display of message graph for example apps + - Check verification of specification, code generation and display of message graph for example apps +- [ ] Test VS Code extension + - Check verification of specification and display of message graph for example apps - [ ] Add release to `CHANGELOG` - [ ] Check if any GitHub issues are not yet mentioned in `CHANGELOG` (especially issue numbers below #1288) - [ ] Bring changes to `main` branch diff --git a/CHANGELOG.md b/CHANGELOG.md index 519863c57..e0b3c3c7c 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,12 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +## [Unreleased] + +### Fixed + +- Display of message graphs in VS Code (AdaCore/RecordFlux#1307, eng/recordflux/RecordFlux#1838) + ## [0.26.0] - 2024-12-18 ### Added @@ -625,6 +631,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [0.1.0] - 2019-05-14 +[Unreleased]: https://github.com/AdaCore/RecordFlux/compare/v0.26.0...HEAD [0.26.0]: https://github.com/AdaCore/RecordFlux/compare/v0.25.0...v0.26.0 [0.25.0]: https://github.com/AdaCore/RecordFlux/compare/v0.24.0...v0.25.0 [0.24.0]: https://github.com/AdaCore/RecordFlux/compare/v0.23.0...v0.24.0 diff --git a/rflx/ide/vscode/src/common/constants.ts b/rflx/ide/vscode/src/common/constants.ts index 100b686ff..fe589be65 100644 --- a/rflx/ide/vscode/src/common/constants.ts +++ b/rflx/ide/vscode/src/common/constants.ts @@ -1,9 +1,8 @@ import * as path from "path"; -import { homedir } from "os"; const folderName = path.basename(__dirname); export const EXTENSION_ROOT_DIR = folderName === "common" ? path.dirname(path.dirname(__dirname)) : path.dirname(__dirname); -export const CACHE_DIR = path.join(homedir(), ".cache", "RecordFlux"); +export const CACHE_DIR = path.join(process.cwd(), ".rflx_cache"); diff --git a/rflx/ide/vscode/src/server.ts b/rflx/ide/vscode/src/server.ts index 7debc8d54..1e8d7aea8 100644 --- a/rflx/ide/vscode/src/server.ts +++ b/rflx/ide/vscode/src/server.ts @@ -125,7 +125,7 @@ async function createServer( initializationOptions: IInitOptions ): Promise { const command = settings.interpreter[0]; - const cwd = settings.cwd; + const cwd = process.cwd(); const newEnv = { ...process.env }; newEnv.USE_DEBUGPY = "False";