Integrate semgrep into CI pipeline

Merged Brian St. Pierre requested to merge better-ci into main

This adds semgrep rules, adds a Makefile rule to run it, adds a job in the pipeline, and also fixes warnings.