Skip to content

Commit 99770e6

Browse files
committed
read and package title from config
1 parent b377d9a commit 99770e6

File tree

2 files changed

+5
-2
lines changed

2 files changed

+5
-2
lines changed

RakeFile

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ require 'albacore'
66
PROPS = 'src/CommonAssemblyInfo.cs'
77
SLN = 'src/FluentNHibernate.sln'
88
CONFIG = 'config.json'
9+
NUSPEC = 'src/FluentNHibernate.nuspec'
910

1011
module Platform
1112

@@ -34,7 +35,6 @@ module Platform
3435
end
3536

3637
NH_VERSION = Platform.config['build']['nh_precompiler_switch']
37-
NUSPEC = Platform.config['nuspec']['filename']
3838

3939
# Albacore.configure do |config|
4040
# config.log_level = :verbose
@@ -187,6 +187,8 @@ namespace :package do
187187
puts "Updating #{NUSPEC}"
188188
update_xml NUSPEC do |xml|
189189
# Override the version number in the nuspec file with the one from this rake file (set above)
190+
xml.root.elements["metadata/id"].text = config['id']
191+
xml.root.elements["metadata/title"].text = config['title']
190192
xml.root.elements["metadata/version"].text = get_version
191193

192194
xml.root.elements["metadata/dependencies/dependency[@id='NHibernate']"].attributes['version'] = config['nhibernate_version_interval']

config.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,8 @@
1313
},
1414
"nuspec":
1515
{
16-
"filename": "FluentNHibernate.nuspec",
16+
"id": "FluentNHibernate",
17+
"title": "FluentNHibernate",
1718
"nhibernate_version_interval": "4.0",
1819
"binaries_folder": "net40"
1920
}

0 commit comments

Comments
 (0)