-
-
Notifications
You must be signed in to change notification settings - Fork 41
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add Content file deployment to internal storage #814
Conversation
if (contents.Any()) | ||
{ | ||
MessageCentre.InternalErrorWriteLine("Deploying content files to internal storage"); | ||
foreach(var file in contents) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
foreach(var file in contents) | |
foreach(var file in contents) |
MessageCentre.InternalErrorWriteLine($"Deploying {file.EvaluatedInclude}"); | ||
if(file.EvaluatedInclude.Contains(Path.DirectorySeparatorChar)) | ||
{ | ||
MessageCentre.InternalErrorWriteLine("File should not be a path, internal storage does not support folders. It will still try to deploy."); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
MessageCentre.InternalErrorWriteLine("File should not be a path, internal storage does not support folders. It will still try to deploy."); | |
MessageCentre.InternalErrorWriteLine("File is included as a path, but internal storage does not support folders. Note: It will still try to deploy."); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Suggested change is trying to convey the error rather than how to handle it (as convention), but if possible, an extra "suggestion" of how to handle the error would be advantagous.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Suggested change is trying to convey the error rather than how to handle it (as convention), but if possible, an extra "suggestion" of how to handle the error would be advantagous.
Yes, I was even thinking to replace the '' by a dash and write it. And also mention that in the docs. I'm open for any improvement on that side. Note that you can also have a look at the 2 other PR, the nf-interpreter one and the nf-debugger one where the core code is located.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actually, this depends on what are the target capabilities. For ORGPAL boards (and others that offer options other than internal storage) these can be stored in SDCard or USB MSD, for example.
I would suggest a warning message with a generic warning about that being a path and the target device may not support that. Or similar.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ok, so we need an additional setting on the nfproj file to specify which drive to use. By default, in this draft implementation, it's using the internal storage.
Now: what is the interest of being able to deploy on a SDCard or external storage when it's much easier to do it another way?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Considering that this is target related, I would argue that this should go into user prefs and not project.
Apart from that, as this is the 1st pass, its more than OK to default to internal storage.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
To your last question: that's, again, hardware dependent. The device may not have internal storage but may have an SDCard. That should be a perfectly valid storage for files being served to HTTP server or used as resources in any application...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
How about File is included as a path, but operation does not allow this. Note: It will still try to deploy.
ee690a8
to
f9880ed
Compare
f9880ed
to
a9319e2
Compare
351c4a6
to
486f70b
Compare
…/nf-Visual-Studio-extension into add-storage-option
…dio-extension into add-storage-option
Important Review skippedDraft detected. Please check the settings in the CodeRabbit UI or the You can disable this status message by setting the Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media? 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
Closing this PR to reopen a new one. This PR contains tests to add a custom property. This cannot be achieved like this. Further PR to come to fix this. |
Description
Add Content file deployment to internal storage
** A new version of Debug lib needs to be published first **
Motivation and Context
How Has This Been Tested?
With test extension
Screenshots
Types of changes
Checklist: