3 ms·
Xcode comes with a very rudimantary but feature complete and free graphical diff util called FileMerge. You can call it from the terminal as 'opendiff'[0]. It w
by aequitas 6y ago
Xcode comes with a very rudimantary but feature complete and free graphical diff util called FileMerge. You can call it from the terminal as 'opendiff'[0]. It works great with Git as difftool or mergetool and it even supports diffing entire directories.
[0] https://www.unix.com/man-page/osx/1/opendiff/ https://www.unix.com/man-page/osx/1/opendiff/
- lukifer 6y agoI had no idea that FileMerge had a CLI (which apparently also supports `opendiff file1 file2`). That's quite helpful, thanks for the tip!
- aequitas 6y agoAlmost all graphical applications and tools for macOS have a CLI counterpart. Often they are not as intuitive or well thought out as most GNU CLI tools, but they get the job done and enable a lot of automation without using the mouse. Things like: networksetup/systemsetup, tmutil (timemachine), open (open files in application, I often use 'open .' to open de current dir in Finder), screencapture, defaults (edit application setting), security (keychain interaction), diskutil, osascript (applescript) and many more.
- thechao 6y ago‘open -a <app name> <path>’ to open a file with a given app.