Author Topic: applying a diff patch on avidemux git  (Read 437 times)

Jan Gruuthuse

  • Hero Member
  • *****
  • Posts: 5006
applying a diff patch on avidemux git
« on: September 29, 2016, 06:07:27 AM »
the patch should start with a similar line like:
Quote
diff --git a/avidemux/
Code: [Select] <- click , the code is now selected.
Right mouse click on selection, select copy.
Paste this into notepad++, gedit or similar editor (none word processor = modifies the present code)
and save this file as update.diff (example)
place the saved file into top of avidemux2 (git of current avidemux)
now you can apply the patch
Code: [Select]
git apply update.diffIf al went fine you should be able to build the modified code.

A sample patch can be found here: slider position displayed time for documentation purpose only
You should not use this after 2016/09/28, commit ab5ddb4  [nvEnc] provide probe function. The code will evolve and will probably be not valid.

« Last Edit: September 30, 2016, 05:32:56 AM by Jan Gruuthuse »

Jan Gruuthuse

  • Hero Member
  • *****
  • Posts: 5006
going back
« Reply #1 on: September 29, 2016, 06:09:08 AM »
Going back (if you don't want the patch remaining in your git)
Code: [Select]
# Undo changes in tracked files
git reset --hard

# Remove untracked files
git clean -df
should take you back as if you did not apply the patch:
Quote
Removing install/
Removing update.diff
« Last Edit: September 30, 2016, 05:32:31 AM by Jan Gruuthuse »

Jan Gruuthuse

  • Hero Member
  • *****
  • Posts: 5006
patch a patch
« Reply #2 on: September 30, 2016, 08:19:48 AM »
Code: [Select]
cd ~/avidemux2
Code: [Select]
patch -p1 < ~/Downloads/dragging-slider-to-zero-does-not-rewind-video-to-zero-fix.patch
Quote
patching file avidemux/common/gui_navigate.cpp

revert patch:
Code: [Select]
patch -Rp1 < ~/Downloads/dragging-slider-to-zero-does-not-rewind-video-to-zero-fix.patch
source: slider position displayed time

~/ is the home of the current user. Just in case you wonder ;)
« Last Edit: September 30, 2016, 08:31:23 AM by Jan Gruuthuse »