Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.
Sign upImplement find / xargs in Python #85
Comments
andychu
added
the
help wanted
label
Mar 1, 2018
This comment has been minimized.
Show comment
Hide comment
This comment has been minimized.
Show comment
Hide comment
andychu
May 2, 2018
Contributor
Perhaps a start:
https://lobste.rs/s/gqgp6r/pure_python_gnu_find_like_utility_2013#c_xjbla2
I didn't look too closely.
|
Perhaps a start: https://lobste.rs/s/gqgp6r/pure_python_gnu_find_like_utility_2013#c_xjbla2 I didn't look too closely. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
andychu commentedMar 1, 2018
I'm marking this "help wanted" -- it could be a fun task for someone who's interested in contributing to Oil, but would rather write new code rather than wade into the existing code.
I haven't blogged about this, but
findshould be folded into the shell. It is almost its own shell -- it starts processes (-exec), has a recursive boolean predicate language, and has its own-printf, globs, and regexes! Some detail here:https://github.com/oilshell/oil/wiki/Unix-Tools
Lots of complex find expressions here:
https://github.com/oilshell/oil/blob/master/test/wild.sh
A couple old comments on the relationship between find and awk. You can think of both as predicate/action languages:
https://lobste.rs/s/jfarwh/find_is_beautiful_tool#c_rkmlpz
https://lobste.rs/s/kkre7i/find_1_revisited_2002#c_yyfqsk
To be consistent with the rest of the project I suppose it should be implemented in Python. I got the OPy compiler running on all of Oil recently, so hopefully that will speed things up and eventually break the dependence on the CPython interpreter.