dotkit 0.0.25 → 0.0.30
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/dotkit.rb +36 -3
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 0f486508bad2c07a0b31d1216c4f776f90c4b22de48fcf3fcdb1e005466900d5
|
4
|
+
data.tar.gz: bab00d072bf646781c6538fc728a551d62b84f3b143d673b7270ac743abc6374
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: b0b20848648098b01d015f94b6984b245825814218f734d4984f1cca02dd73d87f02b7fd55850a8b886aaaf8b11603adcaca26f0adb0f6bf57455d4aa2ad1b26
|
7
|
+
data.tar.gz: c21513b5cd1ba8ed7f00ac14d17620321ad2f39e1fcb7baa54eae5174de7f10458cb9be438130cca3551eed585440281968eddc3ed0c4378298250488c274195
|
data/lib/dotkit.rb
CHANGED
@@ -14,7 +14,15 @@ task :build do
|
|
14
14
|
end
|
15
15
|
if(text.include?('<OutputType>Exe</OutputType>') ||
|
16
16
|
text.include?('<OutputType>WinExe</OutputType>'))
|
17
|
-
|
17
|
+
if(text.include?('<TargetFramework>net5.0-windows</TargetFramework>'))
|
18
|
+
PROJECT.run("dotnet publish #{csproj} -c Release -f net5.0-windows -r win-x64 /p:PublishSingleFile=true /p:UseAppHost=true")
|
19
|
+
else
|
20
|
+
if(text.include?('<TargetFramework>net5.0</TargetFramework>'))
|
21
|
+
PROJECT.run("dotnet publish #{csproj} -c Release -f net5.0 -r win-x64 /p:PublishSingleFile=true /p:UseAppHost=true")
|
22
|
+
else
|
23
|
+
PROJECT.run("dotnet publish #{csproj} -c Release -f netcoreapp3.1 -r win-x64 /p:PublishSingleFile=true /p:UseAppHost=true")
|
24
|
+
end
|
25
|
+
end
|
18
26
|
end
|
19
27
|
}
|
20
28
|
end
|
@@ -78,9 +86,13 @@ task :bump do
|
|
78
86
|
old_version = Raykit::Version.detect(PROJECT.name)
|
79
87
|
new_version = Raykit::Version.bump_file("#{PROJECT.name}/#{PROJECT.name}.csproj")
|
80
88
|
puts " bumped version from #{old_version} to #{new_version}"
|
81
|
-
puts " perform rake :integrate to integrate this change."
|
89
|
+
#puts " perform rake :integrate to integrate this change."
|
82
90
|
puts ''
|
83
|
-
|
91
|
+
if(PROJECT.outstanding_commit?)
|
92
|
+
if(Rake::Task.task_defined?("integrate"))
|
93
|
+
Rake::Task["integrate"].invoke
|
94
|
+
end
|
95
|
+
end
|
84
96
|
end
|
85
97
|
|
86
98
|
desc 'update package versions'
|
@@ -91,6 +103,11 @@ task :update do
|
|
91
103
|
PROJECT.run("dotnet add #{csproj} package #{package}")
|
92
104
|
}
|
93
105
|
}
|
106
|
+
if(PROJECT.outstanding_commit?)
|
107
|
+
if(Rake::Task.task_defined?("integrate"))
|
108
|
+
Rake::Task["integrate"].invoke
|
109
|
+
end
|
110
|
+
end
|
94
111
|
end
|
95
112
|
|
96
113
|
task :default => [:integrate] do
|
@@ -121,3 +138,19 @@ def copy_files(source_dir,glob_pattern,target_dir,exclude_pattern)
|
|
121
138
|
end
|
122
139
|
puts " copied #{count} files to " + target_dir
|
123
140
|
end
|
141
|
+
|
142
|
+
# https://docs.microsoft.com/en-us/visualstudio/code-quality/how-to-generate-code-metrics-data?view=vs-2019
|
143
|
+
def compute_code_metrics
|
144
|
+
metrics_file='artifacts/Code-Metrics.xml'
|
145
|
+
FileUtils.mkdir('artifacts') if(!Dir.exists?('artifacts'))
|
146
|
+
File.delete('artifacts/Code-Metrics.xml') if(File.exists?('artifacts/Code-Metrics.xml'))
|
147
|
+
PROJECT.run("metrics /s:#{PROJECT.name}.sln /o:artifacts/Code-Metrics.xml")
|
148
|
+
if(!File.exist?(metrics_file))
|
149
|
+
raise "#{metrics_file} does not exist"
|
150
|
+
end
|
151
|
+
end
|
152
|
+
|
153
|
+
desc 'initialize a dotnet library'
|
154
|
+
task :init_lib do
|
155
|
+
Raykit::DotNet::initialize_csharp_lib(PROJECT.name)
|
156
|
+
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: dotkit
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.30
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Lou Parslow
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2020-
|
11
|
+
date: 2020-11-10 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|