Skip to content
GitLab
    • GitLab: the DevOps platform
    • Explore GitLab
    • Install GitLab
    • How GitLab compares
    • Get started
    • GitLab docs
    • GitLab Learn
  • Pricing
  • Talk to an expert
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
    • Switch to GitLab Next
    Projects Groups Topics Snippets
  • Register
  • Sign in
  • TortoiseGit TortoiseGit
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributor statistics
    • Graph
    • Compare revisions
    • Locked files
  • Issues 380
    • Issues 380
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 16
    • Merge requests 16
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
    • Test cases
  • Deployments
    • Deployments
    • Releases
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Code review
    • Insights
    • Issue
    • Repository
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • TortoiseGitTortoiseGit
  • TortoiseGitTortoiseGit
  • Issues
  • #2541
Closed
Open
Issue created Aug 02, 2015 by Sven Strickroth@mrtuxOwner

Patches created from "Create patch file" in diff view/TortoiseGitMerge has invalid filepath

By magnesan... on July 21, 2015 18:02 (imported from Google Code)


What steps will reproduce the problem?

  1. Make som change to a file, don't commit
  2. Rightclick file: TortoiseGit -> Diff
  3. Click "Create patch file"
  4. Rightclick file: TortoiseGit -> Revert
  5. Save the file in the same folder as the diff'ed file
  6. Rightclick patch file: TortoiseGit -> Review/apply single patch...

What is the expected output? What do you see instead?

I'd expect the patch to reapply the reverted changes. Instead I get an error "file not found" and applying the patch does nothing.

What version of TortoiseGit and msysgit are you using? On
what operating system?

TortoiseGit 1.8.14.0
Git: 1.9.5.msysgit.0
Windows 7 all updates

Please provide any additional information below.

It seems TortoiseGit isn't aware of which context it's being used, and only looks at the two files as any two files. The problem is that the "source" file in that case is a temporary file created by the diff process which doesn't exist later, and a/ and b/ should probably be what b/ is today. I also see when comparing with a working patch file created by Eclipse that TortoiseGitMerge uses \ instead of / in the path and that TortoiseGitMerge uses absolute paths instead of repository relative as Eclipse does.

To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information
Assignee
Assign to
Time tracking