Compare diff with local and deployed file?

I sometimes get the yellow drop-down bar above the code that says "Deployed file on [server] changed" with Merge and Download links on the right, but Merge will only let me see the differences if there's a conflict (including differences that aren't in conflict). However, if there's not a conflict, I may not want to merge everything locally, or at least I want to see the differences, but there's no "Compare" link to the left of Merge (which there should be), so is there some way to get that compare window up for both files? I know I can click View > Compare With but then I have to go select the file on the server which can be a pain each time.

5 comments

Hello,

If the file has been changed on remote side, you can simply right click it and select Deployment > Sync with Deployed to - it will show the Diff.

0

What's the easiest way to do this if the file isn't highlighted in the Project panel or the folder isn't open there? If I'm jumping through code (like using Ctrl+click on a function or whatever), PHPStorm doesn't highlight the file in the Project panel, and I have to double-click the parent folder and scroll through the dozens or hundreds of (sometimes similarly-named) files to find it to right-click it.

I found I can right-click the file's tab and click Deployment > Compare with Deployed Version, but there's no keyboard combination listed (which would work if I'm focused on the tab), and I'm not seeing any way to have the Project folder highlight the file, which I thought would happen by double-clicking the file's name after the parent folder in the breadcrumb path above the file tab.

0

>What's the easiest way to do this if the file isn't highlighted in the Project panel or the folder isn't open there?

"Navigate | Select In... | Project View" (Alt+F1, 1 using Default keymap)

Alternatively you can enable "Autoscroll from Source" option in Project View panel so that it will always track currently opened file.

 

>I found I can right-click the file's tab and click Deployment > Compare with Deployed Version, but there's no keyboard combination listed

"Settings/Preferences | Keymap" -- you can assign any shortcut you want to that particular action there.

0

Thanks. Both of these solutions I'm not sure are better than clicking the file tab then double-clicking the parent folder (unless there's a lot of files in the folder).

Could just a double-click be implemented on the file tab to highlight the file in the Project panel? That would be intuitive with double-clicking the parent folder in the breadcrumb path to highlight the folder.

 

0

Please sign in to leave a comment.