Created
          June 28, 2021 15:48 
        
      - 
      
- 
        Save noahpeltier/163f6139335b99b0f0586d1452f8db41 to your computer and use it in GitHub Desktop. 
    Organize files into folders by file type
  
        
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
  | (Get-ChildItem -file) | foreach { | |
| if (!$(Test-Path $_.Extension)) { | |
| mkdir "$($_.Extension)" | |
| } | |
| move-item $_.Name -Destination "$($_.Extension)" -Verbose | |
| } | 
  
    Sign up for free
    to join this conversation on GitHub.
    Already have an account?
    Sign in to comment