Skip to content

Commit

Permalink
Make it easier to specify additional preview version information in a…
Browse files Browse the repository at this point in the history
…bout dialog

Signed-off-by: Sven Strickroth <email@cs-ware.de>
  • Loading branch information
csware committed Jan 19, 2020
1 parent a077995 commit 83bf569
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 3 deletions.
1 change: 0 additions & 1 deletion release.txt
Expand Up @@ -4,7 +4,6 @@ This article documents some of the main steps for releasing a new version.
* doc/doc.build.include
* src/version.h
* src/TortoiseGitSetup/VersionNumberInclude.wxi
* For a preview release also make sure to include the yyyymmdd-HASH in src/TortoiseProc/AboutDlg.cpp in "tortoisegitprocpath"

* Make sure crash-report is enabled in version.h (but don't commit this change)
* For a preview release enable "PREVIEW" in version.h (but don't commit this change)
Expand Down
6 changes: 5 additions & 1 deletion src/TortoiseProc/AboutDlg.cpp
@@ -1,7 +1,7 @@
// TortoiseGit - a Windows shell extension for easy version control

// Copyright (C) 2003-2008 - TortoiseSVN
// Copyright (C) 2009-2019 - TortoiseGit
// Copyright (C) 2009-2020 - TortoiseGit

// This program is free software; you can redistribute it and/or
// modify it under the terms of the GNU General Public License
Expand Down Expand Up @@ -98,7 +98,11 @@ BOOL CAboutDlg::OnInitDialog()
}

CString tortoisegitprocpath;
#if PREVIEW
tortoisegitprocpath.Format(L"(%s; %s)", _T(PREVIEW_INFO), static_cast<LPCTSTR>(CPathUtils::GetAppDirectory().TrimRight(L'\\')));
#else
tortoisegitprocpath.Format(L"(%s)", static_cast<LPCTSTR>(CPathUtils::GetAppDirectory().TrimRight(L'\\')));
#endif
temp.Format(IDS_ABOUTVERSION, TGIT_VERMAJOR, TGIT_VERMINOR, TGIT_VERMICRO, TGIT_VERBUILD, static_cast<LPCTSTR>(tortoisegitprocpath), static_cast<LPCTSTR>(out));
SetDlgItemText(IDC_VERSIONABOUT, Lf2Crlf(temp));

Expand Down
3 changes: 2 additions & 1 deletion src/version.h
@@ -1,6 +1,6 @@
// TortoiseGit - a Windows shell extension for easy version control

// Copyright (C) 2008-2019 - TortoiseGit
// Copyright (C) 2008-2020 - TortoiseGit

#define FILEVER 2,9,0,0
#define PRODUCTVER FILEVER
Expand All @@ -20,6 +20,7 @@
#endif

#define PREVIEW 0
#define PREVIEW_INFO "yyyymmdd-hash"

/*
* TortoiseGit crash handler
Expand Down

0 comments on commit 83bf569

Please sign in to comment.