How to run unix oneliners

This is part of the Semicolon&Sons Code Diary - consisting of lessons learned on the job. You're in the python category.

Last Updated: 2024-10-12

The python big gets the directory of a module. This can make the script superbly portable across developer's machines

find "$(python -c 'import rest_framework as rf; print(rf.__path__[0])')"

The tick is - -c '' - with a call to print for any output (otherwise invisible)