Skip to content

Instantly share code, notes, and snippets.

@alexsorokoletov
Last active October 1, 2019 12:13
Show Gist options
  • Save alexsorokoletov/3aa685c0d731d8f8eea44fc6cf0f6872 to your computer and use it in GitHub Desktop.
Save alexsorokoletov/3aa685c0d731d8f8eea44fc6cf0f6872 to your computer and use it in GitHub Desktop.
Clear bin/obj folders for Xamarin projects, as well as other temporary Xamarin files. Developer lifesaver
#!/bin/bash
# based on http://stackoverflow.com/questions/755382/i-want-to-delete-all-bin-and-obj-folders-to-force-all-projects-to-rebuild-everyt
find . -iname "bin" -type d | xargs rm -rf
find . -iname "obj" -type d | xargs rm -rf
# clear VS4Mac temporary downloads
echo ~/Library/Caches/VisualStudio/7.0/TempDownload/
for f in ~/Library/Caches/VisualStudio/7.0/TempDownload/* ; do
sudo rm -rf $f
done
#optionally you can run folowing to clear NuGet cache: nuget locals all -clear
@alexsorokoletov
Copy link
Author

Very nice, @scriptam!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment