awk commands for `union`, `intersect`, `except`, `extra`
awk commands for `union`, `intersect`, `except`, `extra`
I'm munging text and I wrote these awk commands that may be useful to other coders. Feedback welcome. union (https://github.com/sixarm/union): print lines in (A union B) intersect (https://github.com/sixarm/intersect): print lines in (A intersect B) except (https://github.com/sixarm/except): print lines in (A except B) a.k.a. (A - B) extra (https://github.com/sixarm/extra) : print lines in (A extra B) a.k.a. (B - A) Examples: $ cat 1.txt alpha bravo $ cat 2.txt alpha charlie $ union 1.txt 2.txt alpha bravo charlie $ intersect 1.txt 2.txt alpha $ except 1.txt 2.txt bravo $ extra 1.txt 2.txt charlie
Share cardActual performance
Launch Intel predictions
Analyze your own launch →Correct prediction on native model
Similar products
Httpies – httpie with extra headers
Re-reselect – Extra memoization for reselect selectors
Redis-GIS – Geospatial and Geofencing Commands for Redis
Wrapper for Executing Commands in Go
Vim-pnpm Bindings for pnpm commands in Vim
Extra intelligence by Extramarks
Get extra from your AI.
Generate Curl Commands in a Webapp
Bashfs – Run commands as your filesystem
Run synchronous and asynchronous commands in WebDrivers