---
title: "Discussion on \"Get (Git) the last commit files into a zip file with folder structure\" | Hashnode"
description: "Discussion on \"Get (Git) the last commit files into a zip file with folder structure\". This is a handy command when working with Git.  \ngit diff-tree -r --no-commit-id --name-only --diff-filter=ACMRT HEAD~1 HEAD | xargs tar -rf /d/temp/changes.tar\nIt basically takes all the changes from your last commit including the folder structure.\n..."
url: "https://hashnode.com/posts/get-git-the-last-commit-files-into-a-zip-file-with-folder-structure/6326f3b67ae3b59ef00656c0"
---

[Feed](https://hashnode.com/feed) /

Discussion

# [Get (Git) the last commit files into a zip file with folder structure](https://emmti.com/get-git-the-last-commit-files-into-a-zip-file-with-folder-structure?utm_source=hashnode&utm_medium=feed)

This is a handy command when working with Git. git diff-tree -r --no-commit-id --name-only --diff-filter=ACMRT HEAD~1 HEAD | xargs tar -rf /d/temp/changes.tar It basically takes all the changes from your last commit including the folder structure. ...

Feb 9, 2016 · 1 min read · emmti.com  
Read the article

-   [#git](https://hashnode.com/tag/git)
-   [#snippets](https://hashnode.com/tag/snippets)
-   [#zip](https://hashnode.com/tag/zip)

## Written by

[Emmanuel Tissera](https://hashnode.com/@emmti)

@emmti · Melbourne, Australia

  
[View profile](https://hashnode.com/@emmti)

Nuts about .NET, CMS, DXP & Headless.

Technical Director at Luminary. Umbraco 3x MVP.

## Responses

Markdown supported · ⌘↵ to post

No responses yet.
