---
title: "Copy changes without the commit: git cherry-pick --no-commit · Ihab Khattab"
description: "--no-commit applies a commit's changes to your working tree and index without creating a commit. Super handy when I want the changes from another branch but…"
url: "https://ihabkhattab.com/til/git-cherry-pick-no-commit/"
---

# Copy changes without the commit: git cherry-pick --no-commit

Nov 4, 2024 · [Also on X](https://x.com/HO_BA/status/1853516079126966548)

`--no-commit` applies a commit’s changes to your working tree and index without creating a commit. Super handy when I want the changes from another branch but not the commit itself.

```sh
git cherry-pick <commit-hash> --no-commit
```

The short form is `-n`, and it works with ranges too: `git cherry-pick -n A..B` stages the combined changes so you can commit them as one.

[← All TILs](https://ihabkhattab.com/til/)
