I have a bunch of folders and files within a Git repo. I want to just list the directories and not the files.
Currently if I do
git ls-files --directory
It gives the following result
src/main/java/com/ttg/ewq/servicetemp/ReleaseOrder_Service.java
src/main/java/com/ttg/ewq/servicetemp/ReleaseOrder_Test.java
src/main/java/com/ttg/ewq/servicetemp/Shipment_servicetemp_Service.java
src/main/java/com/ttg/ewq/servicetemp/Shipment_servicetemp_Service_test.java
src/main/java/com/ttg/ewq/servicetemp/DepositeService_Service.java
src/main/java/com/ttg/ewq/servicetemp/DepositeService_Test.java
src/main/java/com/ttg/ewq/servicetemp/servicetemp_Service.java
src/main/java/com/ttg/ewq/servicetemp/sservicetemp_Test.java
I don't want to see the java files and other text files inside the folders. I just need the folder names
答案 0 :(得分:1)
I found the answer. It's
git ls-tree -d -r master --name-only