Closed allevo closed 3 years ago
what happen when a files doesn't exists: sort ignores it or fails?
It should fail if I'm not mistaken
which flags should we implement? No one is implemented here.
All tools should be POSIX compatible, that means that for a tool to be considered complete, it has to implement all POSIX flags.
Since it's not always that people have the time to implement all flags and options or understand what all flags and options do, so when that happens, just let me know updating the PR message with what flags were implemented so we can open issues and update the tracker issue about it status.
Regardless if POSIX-complete or not, remember to update the README tool status table.
You can find the POSIX standard for sort here
for the time being, the implementation is in memory and no temp file technique is implemented shall we support stdin as input?
Yes, if I remember the standard correctly, it is specified that stdin has to be supported and is the default if no FILE is given
for test purpose, use println! macro is not a good choice: what we can use instead?
I think you can use write!
macro instead, you can use it specifying anything that implements io::Write
trait
I'll link to uniq
for reference in some of the questions:
Hi!
sorry for the delay.
I've updated the code using Read
and Write
trait for better test. I have also added some tests.
for time being I have implemented only -m
and -o
flags and the stdin support.
If for you is ok I would like to merge this before going to add other feature.
Can you add the hacktoberfest-accepted
label too?
Bors r+
Build succeeded:
In this PR there's the first implementation of
sort
command ( #46 )We need to discuss about:
sort
ignores it or fails?println!
macro is not a good choice: what we can use instead?