-
Notifications
You must be signed in to change notification settings - Fork 7k
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
Port fs commands to the new shell #10103
Conversation
Codecov Report
@@ Coverage Diff @@
## master #10103 +/- ##
=======================================
Coverage 53.18% 53.18%
=======================================
Files 210 210
Lines 25816 25816
Branches 5682 5682
=======================================
Hits 13731 13731
Misses 9780 9780
Partials 2305 2305 Continue to review full report at Codecov.
|
subsys/fs/shell.c
Outdated
buf[i] > 127 ? '.' : buf[i]); | ||
} | ||
|
||
printk("\n"); | ||
shell_fprintf(shell, SHELL_NORMAL, "\n"); |
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.
I think it shall be \r\n
subsys/fs/shell.c
Outdated
return res; | ||
shell_fprintf(shell, SHELL_ERROR, | ||
"Error creating dir[%d]\r\n", res); | ||
return; |
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.
obsolete return
30be5d6
to
e93d9ba
Compare
@nvlsianpu can you take a look at this? |
sure |
subsys/fs/shell.c
Outdated
@@ -147,20 +265,24 @@ static int cmd_read(int argc, char *argv[]) | |||
|
|||
err = fs_stat(path, &dirent); | |||
if (err) { | |||
printk("Failed to stat %s (%d)\n", path, err); | |||
return err; | |||
shell_fprintf(shell, SHELL_ERROR, "Failed to stat %s (%d)\r\n", |
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.
error message: "Failed to obtain/get file/file-system object status"
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.
I understand that message was inherited :D
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.
yes, i didn't touch messages but i fixed that one on your request :)
@nordic-krch : May you plesae rebase to this PR:#10322? |
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.
Please rebase to PR#10322.
Port existing commands to the new shell subsystem. Signed-off-by: Krzysztof Chruscinski <krzysztof.chruscinski@nordicsemi.no>
rebased on master (including #10322 |
Post shell fs commands to the new shell.
It has changes on top of #9362
Fixes #8874.