Skip to content

Instantly share code, notes, and snippets.

@claptimes5
Created June 25, 2021 18:59
Show Gist options
  • Save claptimes5/3892c2995abe268ffbfecfe4a25ad306 to your computer and use it in GitHub Desktop.
Save claptimes5/3892c2995abe268ffbfecfe4a25ad306 to your computer and use it in GitHub Desktop.
WSL common .bashrc
# Clear cache when WSL uses too much memory
alias drop_cache="sudo sh -c \"echo 3 >'/proc/sys/vm/drop_caches' && swapoff -a && swapon -a && printf '\n%s\n' 'Ram-cache and Swap Cleared'\""
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment