Skip to content

Instantly share code, notes, and snippets.

@willsantos
Last active May 14, 2024 21:43
Show Gist options
  • Save willsantos/6dd880eef94757b10948d83b38da128a to your computer and use it in GitHub Desktop.
Save willsantos/6dd880eef94757b10948d83b38da128a to your computer and use it in GitHub Desktop.
Coloca um gitkeep nas pastas vazias

Gitkeep

#Coloca o .gitkeep em todos os subdiretorios vazios

Get-ChildItem -Path . -Recurse -Directory | Where-Object { -not ( $_ | Get-ChildItem ) } | ForEach-Object { New-Item "$($_.FullName)/.gitkeep" -ItemType "file" }
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment