Would you like to react to this message? Create an account in a few clicks or log in to continue.

You are not connected. Please login or register

R1853 Auto save/restore compiler for code file in config file.

2 posters

Go down  Message [Page 1 of 1]

royqh1979



It seems that simulIDE can read compiler settings from the first line of code file. But I think it's not intuitive for users and prone for spelling errors. And it might conflict with other IDE/Compilers.

This patch auto save/restore compiler in a seperate config file.





arcachofo

arcachofo

There is some plan about config file, but not completely defined:
Currently breakpoints are saved to a file: EditorWidget::saveBreakpoints
We need to discuss and define how the whole thing will work.

Some point to think about:
- Link to a circuit file?
- Keep a list of other files related (to be opened along the main one)
- open the config file (project file) willl open all Editor and Circuit files.
- Any other ideas...

In simulide most of the configuration files use xml format, so I guess that we should go with xml.

royqh1979



arcachofo wrote:There is some plan about config file, but not completely defined:
Currently breakpoints are saved to a file: EditorWidget::saveBreakpoints
We need to discuss and define how the whole thing will work.

Some point to think about:
- Link to a circuit file?
- Keep a list of other files related (to be opened along the main one)
- open the config file (project file) willl open all Editor and Circuit files.
- Any other ideas...

In simulide most of the configuration files use xml format, so I guess that we should go with xml.

Project is good. But it needs a lot of work to do:
- make support?
- import other IDE project file?
- Project Explore?
- Toolbar/menu design
- ...

So any plan / roadmap for the next release?

arcachofo

arcachofo

Note that Compiler settings from the first line of code is just a hidden trick to use while this is defined.

Project is good. But it needs a lot of work to do:
- make support?
- import other IDE project file?
- Project Explore?
- Toolbar/menu design

So any plan / roadmap for the next release?
My idea is always keep it as simple as posible.
So no actual projects like in other IDEs where you need to go through many steps just to blink a led.

The idea is to have a configuration file linked to a source file, with same name, and an extension to be defined.
As a first step this file should contain:
- Main source file name.
- Compiler settings.
- Breakpoint list.

There is plan and some work done to debug through several files (currently only main file is posible).
So breakpoint list should be per file.

Later some other features could be added, for example I have these in mind:
- Add a list of files currently opened in the Editor and Circuit (how? automatically? on demand?).
- Add the capability to open the config file, this will open all files in that list.

So by now there is no plan for actual "Project".
A "project" would be just a set of files somehow linked to a main source file.
"Project Explore" can be done in file explorer panel: just add a bookmark with the folder containing the files.
Make support, import other IDE project file and Toolbar/menu design is not planned at all by now.

royqh1979



I mean, is there any plan/roadmap/schedule for the next release?

royqh1979




arcachofo wrote:
My idea is always keep it as simple as posible.
So no actual projects like in other IDEs where you need to go through many steps just to blink a led.

The idea is to have a configuration file linked to a source file, with same name, and an extension to be defined.
As a first step this file should contain:
- Main source file name.
- Compiler settings.
- Breakpoint list.

I think that's good.

For single file debug, one config per source file is enough.

And maybe custom compiler options support?

arcachofo wrote:
There is plan and some work done to debug through several files (currently only main file is posible).
So breakpoint list should be per file.


To compile multiple source files, make support might be a must?

arcachofo wrote:
Later some other features could be added, for example I have these in mind:
- Add a list of files currently opened in the Editor and Circuit (how? automatically? on demand?).
- Add the capability to open the config file, this will open all files in that list.

Most IDEs support autosave/restore files openned on exit. So I think it should be implemented.

arcachofo

arcachofo

I mean, is there any plan/roadmap/schedule for the next release?
There is plan to release 1.1.0-RC1 very soon.
I don't have exact dates, just when I think is a good moment. But as a general idea in September
This is just a "release candidate" in the wide sense of the term, basically meaning something to try, test, report bugs, etc.

Then maybe around March will be the first "Stable Release".

And maybe custom compiler options support?
To add a custom compiler just add an xml file to the compiler folder.

For single file debug, one config per source file is enough.
To compile multiple source files, make support might be a must?
The idea is to debug single compile units with multiple files in the same folder (or subfolders).
In cases where the code is spread through several files and included in the main source file.

To compile more complex projects maybe better use some other app.
Or create your own makefile and configure a compiler xml file that calls make as build step.

Most IDEs support autosave/restore files openned on exit. So I think it should be implemented.
Yes, but that only opens the files in the last session, which could be implemented as well.

The idea with this config file is that it has a file list for each main source file.
So if you open the config file, you can also open related files and circuit for that main file.

arcachofo

arcachofo

Configuration file basic implementation at Rev 1856.
Note that this is still very raw and could change.

When a source file is saved a configuration file is created with name source.cfg with:.
- Compiler name.
- Compiler settings: device, family, board, etc.
- Breakpoints.

When the source file is opened these settings are loaded.

royqh1979 likes this post

arcachofo

arcachofo

Added "Restore files" option at Rev 1858.
If selected, when opening the source file, it will restore circuit and other files in the Editor.
This property is saved when the source file is saved, maybe this is not optimal.

royqh1979



Rev 1859. It seems that the compiler option dialog will be messed if switch from one compiler to another. such from "sdcc" to "sdas51(sdcc)"

royqh1979



patch to fix compiler option dialog issues:
- toolpath & includepath are not displayed
- dialog messed up after compilers switched.

It seems that QVBoxLayout  can't correctly layout after remove widgets. So I have to set the widgets invisible manually.
Attachments
R1853 Auto save/restore compiler for code file in config file. Attachmentcompilercfg.zip
You don't have permission to download attachments.
(1 Kb) Downloaded 1 times

arcachofo

arcachofo

Thanks. Patch applied at Rev 1860.

Sponsored content



Back to top  Message [Page 1 of 1]

Permissions in this forum:
You cannot reply to topics in this forum