added ~ support and error handling#3
Conversation
|
Would be better to have this inside the saveSettings function so that the main function remains small and tidy. |
This reverts commit ce33dba.
|
i didnt get it |
|
to move your error handling inside the saveSettings function, so that it doesn't clutter main(). |
|
so the saveSettings function is located in settings.h file, right? |
|
Yes |
|
I'm going to rewrite that later to allow for key/value pairs but could use that error checking anyway. |
|
this work c97b1fb |
now only i see this i created a function inside the cue.c |
|
I would prefer if the main function was just calls to other functions and no code. so put everything in saveSettings please. Btw, thanks for helping out, @jothi-prasath. |
|
Best would be to put expandPath in dir.c and #include "dir.h" in settings.h. Then call expandPath from within the saveSettings function, instead of doing it in main(). |
|
Thanks! However, I must admit that I currently have limited knowledge and experience with header files and c. While I am eager to learn and improve my skills, I might require some guidance or assistance to correctly implement the changes you proposed. I would be grateful if you or other experienced contributors could provide some direction or collaborate with me on this matter. |
|
Sure, no problem. I'll merge your commit and then do the required changes. But not today. |
|
The way header files work is they contain the signature of the functions. so the settings.h should contain the line:
Like that, with a semicolon at the end. When that is done any file that contains #include <settings.h> can call expandPath, and it will execute the function in <settings.c> provided you put the expandPath function there. |
|
I had to add some stuff to expandPath. |
…ut album art when in landscape mode' (#3) from hartalex/kew:fix-2 into develop Reviewed-on: https://codeberg.org/ravachol/kew/pulls/3
Description
This PR adds ~ support and error handling
Changes Made