mirror of
https://github.com/ZoiteChat/zoitechat.git
synced 2026-03-10 16:00:18 +00:00
win32: Use version information from configure.ac to populate the Windows-specific files that need it - config-win32.h, version.txt, hexchat.rc, hexchat.iss
This is done via T4 templates. The original files are now generated at build-time and so have been added to .gitignore and removed from the repository, with the exception of version.txt which must be hosted on GitHub for the updater plugin.
This commit is contained in:
12
version.include.tt
Normal file
12
version.include.tt
Normal file
@@ -0,0 +1,12 @@
|
||||
<#@
|
||||
template debug="false" hostspecific="false" language="C#" #><#@
|
||||
assembly name="System.Core" #><#@
|
||||
import namespace="System.IO" #><#@
|
||||
import namespace="System.Linq" #><#@
|
||||
import namespace="System.Text.RegularExpressions" #><#
|
||||
var versionParts = File.ReadLines(Path.Combine(System.Environment.GetEnvironmentVariable("SOLUTIONDIR"), "configure.ac"))
|
||||
.Select(line => Regex.Match(line, @"^AC_INIT\(\[HexChat\],\[([^]]+)\]\)$"))
|
||||
.First(match => match.Success)
|
||||
.Groups[1].Value
|
||||
.Split('.');
|
||||
#>
|
||||
Reference in New Issue
Block a user