makit 0.0.6 → 0.0.7

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 25ea2184f779faed979afe31bd6494caca9f7ba01b77db6b4a70ed2f512c3f87
4
- data.tar.gz: f724c4e67f813a6677d73a62a79606938d0770ec92537ff9eb6dff3595e9021a
3
+ metadata.gz: 254994adada857fd53b6fc18040b3741700d2569481db7797d24f70a5cf791df
4
+ data.tar.gz: f86c6304e3ac3bed1d9080847f30142cdd21e89ea1c228f0a7369563322a1e49
5
5
  SHA512:
6
- metadata.gz: 63eb2e57ae7eefdd32a7f6a6ff65847e2c00fbcc1e5d5b194b2d464a3bb04b4e52c18b8700c2bbfc423afce5a9a868f5f7f0e4f6c35673d3ee803f0b43b3d176
7
- data.tar.gz: 28022382f1a8da338d32b1e550da2a68220636aa40948962d00cc6e0da907109d44d03558ae6bc94b6896052cb07cd007f0d5b7f8cb3b54a7e2ddd88cc057d96
6
+ metadata.gz: 59f41b1d403be9db7cfddb78cd4dfef508ca8e3b415477b23a2dd49018abe88c3265f4b14df4261bea2f8c5f9e23ff79b9a544297a426e5092de8580d6a7f82e
7
+ data.tar.gz: 8e8a11079149d5ffbf0a12f90cd729664b0ea276d50628f73ffd23a092712f9fc6d55a7c16abb60e34b8492e74e458a1aff16fc9e9eac194d27898334ab19aa6
data/lib/makit/dotnet.rb CHANGED
@@ -62,6 +62,24 @@ module Makit
62
62
  end
63
63
  end
64
64
 
65
+ def self.publish(project_path, configuration = "Release", output = "artifacts")
66
+ project_dir = File.dirname(project_path)
67
+ #puts "project_dir: #{project_dir}"
68
+ newest_file = Makit::Directory::get_newest_file(project_dir)
69
+ command_request = Makit::RUNNER::parse_command_request("dotnet publish #{project_path} --configuration #{configuration} --output #{output}")
70
+ if newest_file.nil?
71
+ #puts "newest_git_file is nil, assigning a default"
72
+ # assign a timestamp of now
73
+ newest_file_date = Time.now
74
+ RUNNER.cache_run(command_request, newest_file_date)
75
+ else
76
+ newest_file_date = File.mtime(newest_file)
77
+ #puts "newest file: #{newest_file}"
78
+ #puts "newest file date: #{newest_file_date}"
79
+ RUNNER.cache_run(command_request, newest_file_date)
80
+ end
81
+ end
82
+
65
83
  def self.sln_add_projects(sln_name)
66
84
  if !File.exist? "#{sln_name}.sln"
67
85
  raise "Solution #{sln_name}.sln does not exist"
@@ -146,6 +146,10 @@ module Makit
146
146
  project_path = File.join(project.output, "#{project.name}.csproj")
147
147
  Makit::DotNet.build(project_path, build_arg.configuration, build_arg.output)
148
148
  end
149
+ project.publish_args.each do |publish_arg|
150
+ project_path = File.join(project.output, "#{project.name}.csproj")
151
+ Makit::DotNet.publish(project_path, publish_arg.configuration, publish_arg.output)
152
+ end
149
153
  end
150
154
  end
151
155
  end
@@ -8,7 +8,7 @@ require 'google/protobuf/timestamp_pb'
8
8
  require 'google/protobuf/duration_pb'
9
9
 
10
10
 
11
- descriptor_data = "\n\x1blib/makit/v1/makit.v1.proto\x12\x08makit.v1\x1a\x1fgoogle/protobuf/timestamp.proto\x1a\x1egoogle/protobuf/duration.proto\"\x8c\x01\n\rDotNetProject\x12\x10\n\x08template\x18\x01 \x01(\t\x12\x0c\n\x04name\x18\x02 \x01(\t\x12\x0e\n\x06output\x18\x03 \x01(\t\x12\x10\n\x08packages\x18\x04 \x03(\t\x12\n\n\x02os\x18\x05 \x01(\t\x12-\n\nbuild_args\x18\x06 \x03(\x0b\x32\x19.makit.v1.DotNetBuildArgs\"8\n\x0f\x44otNetBuildArgs\x12\x15\n\rconfiguration\x18\x01 \x01(\t\x12\x0e\n\x06output\x18\x02 \x01(\t\"a\n\x07Project\x12\x16\n\x0egit_remote_url\x18\x01 \x01(\t\x12\x0c\n\x04name\x18\x02 \x01(\t\x12\x30\n\x0f\x64otnet_projects\x18\x05 \x03(\x0b\x32\x17.makit.v1.DotNetProject\"\xa5\x01\n\x0e\x43ommandRequest\x12\x0c\n\x04name\x18\x01 \x01(\t\x12\x11\n\targuments\x18\x02 \x03(\t\x12+\n\x07timeout\x18\x03 \x01(\x0b\x32\x1a.google.protobuf.Timestamp\x12\x11\n\tdirectory\x18\x04 \x01(\t\x12\x0c\n\x04task\x18\x05 \x01(\t\x12\r\n\x05input\x18\x06 \x01(\x0c\x12\x15\n\rexit_on_error\x18\x07 \x01(\x08\"\x91\x02\n\x07\x43ommand\x12\n\n\x02id\x18\x01 \x01(\x03\x12\x0c\n\x04name\x18\x02 \x01(\t\x12\x11\n\targuments\x18\x03 \x03(\t\x12\x11\n\texit_code\x18\x04 \x01(\x05\x12\r\n\x05input\x18\x05 \x01(\x0c\x12\x0e\n\x06output\x18\x06 \x01(\x0c\x12\r\n\x05\x65rror\x18\x07 \x01(\x0c\x12.\n\nstarted_at\x18\x08 \x01(\x0b\x32\x1a.google.protobuf.Timestamp\x12+\n\x08\x64uration\x18\t \x01(\x0b\x32\x19.google.protobuf.Duration\x12\x0c\n\x04user\x18\n \x01(\t\x12\x0e\n\x06\x64\x65vice\x18\x0b \x01(\t\x12\n\n\x02os\x18\x0c \x01(\t\x12\x11\n\tdirectory\x18\r \x01(\t\"I\n\rConfiguration\x12\x0c\n\x04name\x18\x01 \x01(\t\x12*\n\x08\x63ommands\x18\x02 \x03(\x0b\x32\x18.makit.v1.CommandRequest\"3\n\rGitRepository\x12\x0b\n\x03url\x18\x01 \x01(\t\x12\x15\n\rrelative_path\x18\x02 \x01(\t\"h\n\x0bGitLogEntry\x12\x0e\n\x06\x63ommit\x18\x01 \x01(\t\x12\x0e\n\x06\x61uthor\x18\x02 \x01(\t\x12(\n\x04\x64\x61te\x18\x03 \x01(\x0b\x32\x1a.google.protobuf.Timestamp\x12\x0f\n\x07message\x18\x04 \x01(\t\"\xc8\x01\n\nMakeResult\x12\x12\n\nrepository\x18\x01 \x01(\t\x12\x0e\n\x06\x63ommit\x18\x02 \x01(\t\x12\x0e\n\x06\x62ranch\x18\x03 \x01(\t\x12\x0b\n\x03tag\x18\x04 \x01(\t\x12\x0e\n\x06\x64\x65vice\x18\x05 \x01(\t\x12\x1a\n\x12runtime_identifier\x18\x06 \x01(\t\x12#\n\x08\x63ommands\x18\x07 \x03(\x0b\x32\x11.makit.v1.Command\x12\x14\n\x0cinitial_size\x18\x08 \x01(\x05\x12\x12\n\nfinal_size\x18\t \x01(\x05\"?\n\rDotNetNewArgs\x12\x10\n\x08template\x18\x01 \x01(\t\x12\x0c\n\x04name\x18\x02 \x01(\t\x12\x0e\n\x06output\x18\x03 \x01(\t**\n\x08Language\x12\x08\n\x04RUBY\x10\x00\x12\n\n\x06\x43SHARP\x10\x01\x12\x08\n\x04RUST\x10\x02*,\n\x0bPackageType\x12\x07\n\x03GEM\x10\x00\x12\t\n\x05NUGET\x10\x01\x12\t\n\x05\x43RATE\x10\x03\x32H\n\x0e\x43ommandService\x12\x36\n\x07\x45xecute\x12\x18.makit.v1.CommandRequest\x1a\x11.makit.v1.Commandb\x06proto3"
11
+ descriptor_data = "\n\x1blib/makit/v1/makit.v1.proto\x12\x08makit.v1\x1a\x1fgoogle/protobuf/timestamp.proto\x1a\x1egoogle/protobuf/duration.proto\"\xbf\x01\n\rDotNetProject\x12\x10\n\x08template\x18\x01 \x01(\t\x12\x0c\n\x04name\x18\x02 \x01(\t\x12\x0e\n\x06output\x18\x03 \x01(\t\x12\x10\n\x08packages\x18\x04 \x03(\t\x12\n\n\x02os\x18\x05 \x01(\t\x12-\n\nbuild_args\x18\x06 \x03(\x0b\x32\x19.makit.v1.DotNetBuildArgs\x12\x31\n\x0cpublish_args\x18\x07 \x03(\x0b\x32\x1b.makit.v1.DotNetPublishArgs\"8\n\x0f\x44otNetBuildArgs\x12\x15\n\rconfiguration\x18\x01 \x01(\t\x12\x0e\n\x06output\x18\x02 \x01(\t\":\n\x11\x44otNetPublishArgs\x12\x15\n\rconfiguration\x18\x01 \x01(\t\x12\x0e\n\x06output\x18\x02 \x01(\t\"a\n\x07Project\x12\x16\n\x0egit_remote_url\x18\x01 \x01(\t\x12\x0c\n\x04name\x18\x02 \x01(\t\x12\x30\n\x0f\x64otnet_projects\x18\x05 \x03(\x0b\x32\x17.makit.v1.DotNetProject\"\xa5\x01\n\x0e\x43ommandRequest\x12\x0c\n\x04name\x18\x01 \x01(\t\x12\x11\n\targuments\x18\x02 \x03(\t\x12+\n\x07timeout\x18\x03 \x01(\x0b\x32\x1a.google.protobuf.Timestamp\x12\x11\n\tdirectory\x18\x04 \x01(\t\x12\x0c\n\x04task\x18\x05 \x01(\t\x12\r\n\x05input\x18\x06 \x01(\x0c\x12\x15\n\rexit_on_error\x18\x07 \x01(\x08\"\x91\x02\n\x07\x43ommand\x12\n\n\x02id\x18\x01 \x01(\x03\x12\x0c\n\x04name\x18\x02 \x01(\t\x12\x11\n\targuments\x18\x03 \x03(\t\x12\x11\n\texit_code\x18\x04 \x01(\x05\x12\r\n\x05input\x18\x05 \x01(\x0c\x12\x0e\n\x06output\x18\x06 \x01(\x0c\x12\r\n\x05\x65rror\x18\x07 \x01(\x0c\x12.\n\nstarted_at\x18\x08 \x01(\x0b\x32\x1a.google.protobuf.Timestamp\x12+\n\x08\x64uration\x18\t \x01(\x0b\x32\x19.google.protobuf.Duration\x12\x0c\n\x04user\x18\n \x01(\t\x12\x0e\n\x06\x64\x65vice\x18\x0b \x01(\t\x12\n\n\x02os\x18\x0c \x01(\t\x12\x11\n\tdirectory\x18\r \x01(\t\"I\n\rConfiguration\x12\x0c\n\x04name\x18\x01 \x01(\t\x12*\n\x08\x63ommands\x18\x02 \x03(\x0b\x32\x18.makit.v1.CommandRequest\"3\n\rGitRepository\x12\x0b\n\x03url\x18\x01 \x01(\t\x12\x15\n\rrelative_path\x18\x02 \x01(\t\"h\n\x0bGitLogEntry\x12\x0e\n\x06\x63ommit\x18\x01 \x01(\t\x12\x0e\n\x06\x61uthor\x18\x02 \x01(\t\x12(\n\x04\x64\x61te\x18\x03 \x01(\x0b\x32\x1a.google.protobuf.Timestamp\x12\x0f\n\x07message\x18\x04 \x01(\t\"\xc8\x01\n\nMakeResult\x12\x12\n\nrepository\x18\x01 \x01(\t\x12\x0e\n\x06\x63ommit\x18\x02 \x01(\t\x12\x0e\n\x06\x62ranch\x18\x03 \x01(\t\x12\x0b\n\x03tag\x18\x04 \x01(\t\x12\x0e\n\x06\x64\x65vice\x18\x05 \x01(\t\x12\x1a\n\x12runtime_identifier\x18\x06 \x01(\t\x12#\n\x08\x63ommands\x18\x07 \x03(\x0b\x32\x11.makit.v1.Command\x12\x14\n\x0cinitial_size\x18\x08 \x01(\x05\x12\x12\n\nfinal_size\x18\t \x01(\x05\"?\n\rDotNetNewArgs\x12\x10\n\x08template\x18\x01 \x01(\t\x12\x0c\n\x04name\x18\x02 \x01(\t\x12\x0e\n\x06output\x18\x03 \x01(\t**\n\x08Language\x12\x08\n\x04RUBY\x10\x00\x12\n\n\x06\x43SHARP\x10\x01\x12\x08\n\x04RUST\x10\x02*,\n\x0bPackageType\x12\x07\n\x03GEM\x10\x00\x12\t\n\x05NUGET\x10\x01\x12\t\n\x05\x43RATE\x10\x03\x32H\n\x0e\x43ommandService\x12\x36\n\x07\x45xecute\x12\x18.makit.v1.CommandRequest\x1a\x11.makit.v1.Commandb\x06proto3"
12
12
 
13
13
  pool = Google::Protobuf::DescriptorPool.generated_pool
14
14
  pool.add_serialized_file(descriptor_data)
@@ -17,6 +17,7 @@ module Makit
17
17
  module V1
18
18
  DotNetProject = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("makit.v1.DotNetProject").msgclass
19
19
  DotNetBuildArgs = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("makit.v1.DotNetBuildArgs").msgclass
20
+ DotNetPublishArgs = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("makit.v1.DotNetPublishArgs").msgclass
20
21
  Project = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("makit.v1.Project").msgclass
21
22
  CommandRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("makit.v1.CommandRequest").msgclass
22
23
  Command = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("makit.v1.Command").msgclass
data/lib/makit/version.rb CHANGED
@@ -1,7 +1,7 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Makit
4
- VERSION = "0.0.6"
4
+ VERSION = "0.0.7"
5
5
 
6
6
  class Version
7
7
  # given an array of version strings, return the highest version
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: makit
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.6
4
+ version: 0.0.7
5
5
  platform: ruby
6
6
  authors:
7
7
  - Lou Parslow