Skip to content

Instantly share code, notes, and snippets.

@Pierstoval
Created December 6, 2021 08:33
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Pierstoval/f66857f501568578fbd0fa5c3fde65e5 to your computer and use it in GitHub Desktop.
Save Pierstoval/f66857f501568578fbd0fa5c3fde65e5 to your computer and use it in GitHub Desktop.
_TITLE := "\033[32m[%s]\033[0m %s\n"
_ERROR := "\033[31m[%s]\033[0m %s\n"
obliterate:
@printf $(_ERROR) "WARNING" "This will remove EVERYTHING and result into a setup similar to a fresh \"git clone\"."
@printf $(_TITLE) "Project" "Stopping & deleting all containers, volumes, etc."
@docker-compose down --volumes --remove-orphans --rmi all
@printf $(_TITLE) "Project" "Removing non-versioned files"
@git clean -dx --force \
--exclude=".env*.local" \
--exclude="docker-compose.override.y*ml" \
--exclude=".idea"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment