I have recently implemented readline in my code and I'm having a problem with write_history()
If I run write_history(NULL) it will save the information in ~/.history as mentioned in the documentation.
I'm trying to save it to my own file, i'm just a bit confued about what is meant to happen.
My code compiles when I do
I've also done
int write_history(char *fname)
They both compile and appear to work. I'm just confused about where exactly fname should be?
Does it appear as .fname, fname.history, fname.txt?
Does it get saved in ~/. or current directory? How could I set this?
Thank you for your help