User
Welcome, Guest. Please login or register.
November 22, 2017, 01:21:03 PM

Login with username, password and session length

Search
News
Mogware announces the Advanced Version.
Latest Downloads
Links
« previous next »
Pages: [1] Print
Author Topic: Force update revision on every file and create a "release tag"/ version tagging  (Read 3298 times)
shom
Mouse
*

Karma: +0/-0
Posts: 1


Email
« on: April 27, 2010, 04:06:54 PM »

FH doesn't allow you to create a "snapshot" of the entire project to tag as a release.  Here's a way to do version tagging with FH:

Update Revision
FileHamster provides an option to do an update revision on a file or folder (including sub-directories recursively).  FH will make a revision of each file that has changed since the last revision.  While this is great for not making extra revisions (hence storage space) of files that haven't changed, it is not ideal for creating a revision of a release that you can revert to.  In order to create a revision of each file in its current state follow these steps:
Mark every file for revisioning
Run UpdateRevisionPrep.bat to mark every file in the current directory and sub-directories for revisioning.  This will create a file called fileList.txt this can later be used to diff against itself to determine which files have been newly created since the last release.  fileList.txt will contain the listing of ALL files in the directory and subdirectory even the ones that are ignored by FH (due to exclusion rules).

NOTE: Copy UpdateRevisionPrep.bat and touch.exe from N:\Systems_Controls\J7_Inhouse_System&Controls\Tools\FileHamster \UpdateRevision to the release folder and exclude them from being revisioned by FH.

Batch file source
Code: [Select]
REM Author: Shom Bandopadhaya shom@belcan.com
REM Description: Changes the time stamp of files in current directory and subdirectories so FileHamster
REM will do an update revision on every file and then that version can be tagged as a release.

@echo off
echo "Touching" all files to current system time (ignore folder related errors)...
FOR /R %%i in (*.*) do touch "%%i"
cls
echo All files have been "touched"
echo Creating list of files for current version >fileList.txt
dir /A:-D /B /S >fileList.txt
echo Ready to do an "Update Revision" with FileHamster
pause

touch.exe
touch.exe is provided free by [http://www.helge.mynetcologne.de/touch/index.htm Helge Klein].

Update Revision from FH
Right click on the release folder from which UpdateRevisionPrep.bat was run and click on "Update Revision"; check all the boxes and click OK.  FH will revision all the files.
Tag the release
Go to the report window in FH and generate a report on the release folder with the current date as the search parameter and show only the newest revision.  Select all the files, right click, protect and comment the files with the release tag.

Restoring a revision
FH currently doesn't support restoring all files to a tagged revision.  The easiest way to do so is to look at the revision history of a file and identify the desired release from the comments, and note the date.  Generate a report from the Report window using that date and select all files to revert to that tagged revision.  This is a workaround and is not thoroughly tested.
Logged
Pages: [1] Print 
« previous next »
Jump to:  

Powered by SMF 2.0.2 | SMF © 2006-2007, Simple Machines LLC Epsilon design by Bloc