Skip to content

Instantly share code, notes, and snippets.

@snelson82
Last active April 18, 2024 23:42
Show Gist options
  • Save snelson82/4cafaa6a6fbcac7a91df28adf10e5938 to your computer and use it in GitHub Desktop.
Save snelson82/4cafaa6a6fbcac7a91df28adf10e5938 to your computer and use it in GitHub Desktop.
Alias to run various tasks in preparation for opening a pull request
alias pr-prep='
(time (
echo "==> Fetching deps" && \
time mix deps.get && \
echo "==> Running mix format" && \
time mix format && \
echo "==> Checking if formatted" && \
time mix format --check-formatted && \
echo "==> Cleaning unused deps" && \
time mix deps.clean --unlock --unused && \
echo "==> Checking for unused deps" && \
time mix deps.unlock --check-unused && \
echo "==> Running Credo" && \
time mix credo --strict && \
echo "==> Compiling with warnings as errors" && \
time mix compile --warnings-as-errors --force && \
echo "==> Running doctor" && \
time mix doctor && \
echo "==> Running tests" && \
time mix test
))
'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment