Closed ddalcino closed 3 years ago
Merging #21 (09e0524) into master (d418a2e) will decrease coverage by
1.76%
. The diff coverage is75.00%
.:exclamation: Current head 09e0524 differs from pull request most recent head daa37e4. Consider uploading reports for the commit daa37e4 to get more accurate results
@@ Coverage Diff @@
## master #21 +/- ##
==========================================
- Coverage 98.14% 96.38% -1.77%
==========================================
Files 1 1
Lines 485 525 +40
==========================================
+ Hits 476 506 +30
- Misses 9 19 +10
Impacted Files | Coverage Δ | |
---|---|---|
src/cwalk.c | 96.38% <75.00%> (-1.77%) |
:arrow_down: |
Continue to review full report at Codecov.
Legend - Click here to learn more
Δ = absolute <relative> (impact)
,ø = not affected
,? = missing data
Powered by Codecov. Last update d418a2e...daa37e4. Read the comment docs.
Closing this because there is already a well tested library that has this function: https://github.com/gpakosz/whereami
Thanks to @kampeador for the comment in https://github.com/likle/cwalk/issues/20#issuecomment-927348444
This is my first attempt at an implementation for Linux, Mac, Windows, FreeBSD, NetBSD, DragonFlyBSD, and Solaris. I wrote it based on the man pages and developer documentation for these platforms; links to the docs and summaries of relevant functions are included in the code. I'm opening this as a draft primarily to show what this code could look like, so you can decide it you really want something like this in cwalk or not.
The next steps would be to implement tests and get them running in CI on all platforms supported.
I think it would be worth it to add an implementation for OpenBSD. It's an odd OS to leave out, given that I have implementations for 3 other BSDs.
Closes #20.