pact_broker-client 1.76.2 → 1.77.0

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: fd56681a5a874533d5601479c66ccce9096b5b17d97cec422ed14dbb49a1f03e
4
- data.tar.gz: f1df5c362d04a332bfbf5b5e8b89dd3444c94a5d03e7840864be0e76fffeb0ac
3
+ metadata.gz: c967e70badf0e2634f5ca4013fa85fb4f079a14b8862c79186c7ec2785c3ca64
4
+ data.tar.gz: 37caa5d0ec3b19a0a6cf26c9fc6bef0b5a220c2484353fd71ad9320c17e65281
5
5
  SHA512:
6
- metadata.gz: dfc90ba2cba909d9cb01ac15b0cfea6f2833fc6f45f27e8ffef5a6fa5062a24356ffa926ee05ad43b9650632b4346ebb7d74bd89bdd65250d0a734756f39499d
7
- data.tar.gz: bf22ba6e9a8444bed009133ec0993264e0becf16d1024e2f23a7ec82c835cd8bd0f4044bf04bbf04f4867a994860976a6dbe3167d696f6adffae779b98a84c92
6
+ metadata.gz: 8790b48db58649026ea18338a0b7e09965199ddfddb66c1f57ae5069d575d905972458710035c5419af265b0652905e7fba89ccdeb7a65f75cab9bc444e27541
7
+ data.tar.gz: a6d2bd3713df1b097e82befffa4b2e13e7cc9c3a13170aec55e339734187b7b2bf9157521eb426c2530a6dffdc19b164552dfc9dcbbccd4d34310b304a68180f
data/CHANGELOG.md CHANGED
@@ -1,3 +1,10 @@
1
+ <a name="v1.77.0"></a>
2
+ ### v1.77.0 (2024-10-08)
3
+
4
+ #### Features
5
+
6
+ * support --ignore flag in can-i-merge command ([1349bd0](/../../commit/1349bd0))
7
+
1
8
  <a name="v1.76.2"></a>
2
9
  ### v1.76.2 (2024-10-13)
3
10
 
data/README.md CHANGED
@@ -572,6 +572,13 @@ Options:
572
572
  -e, [--version=VERSION]
573
573
  # The pacticipant version. Must be entered after the
574
574
  --pacticipant that it relates to.
575
+ [--ignore=PACTICIPANT]
576
+ # The pacticipant name to ignore. Use once for each pacticipant
577
+ being ignored. A specific version can be ignored by also
578
+ specifying a --version after the pacticipant name option. The
579
+ environment variable PACT_BROKER_CAN_I_MERGE_IGNORE may also be
580
+ used to specify a pacticipant name to ignore, with commas to
581
+ separate multiple pacticipant names if necessary.
575
582
  -o, [--output=OUTPUT]
576
583
  # json or table
577
584
  # Default: table
@@ -48,6 +48,7 @@ module PactBroker
48
48
  long_desc "Checks if the specified pacticipant version is compatible with the configured main branch of each of the pacticipants with which it is integrated."
49
49
  method_option :pacticipant, required: true, aliases: "-a", desc: "The pacticipant name. Use once for each pacticipant being checked."
50
50
  method_option :version, required: false, aliases: "-e", desc: "The pacticipant version. Must be entered after the --pacticipant that it relates to."
51
+ method_option :ignore, required: false, banner: "PACTICIPANT", desc: "The pacticipant name to ignore. Use once for each pacticipant being ignored. A specific version can be ignored by also specifying a --version after the pacticipant name option. The environment variable PACT_BROKER_CAN_I_MERGE_IGNORE may also be used to specify a pacticipant name to ignore, with commas to separate multiple pacticipant names if necessary."
51
52
  method_option :output, aliases: "-o", desc: "json or table", default: "table"
52
53
  method_option :retry_while_unknown, banner: "TIMES", type: :numeric, default: 0, required: false, desc: "The number of times to retry while there is an unknown verification result (ie. the provider verification is likely still running)"
53
54
  method_option :retry_interval, banner: "SECONDS", type: :numeric, default: 10, required: false, desc: "The time between retries in seconds. Use in conjuction with --retry-while-unknown"
@@ -59,11 +60,12 @@ module PactBroker
59
60
  require "pact_broker/client/can_i_deploy"
60
61
 
61
62
  validate_credentials
62
- selectors = VersionSelectorOptionsParser.call(ARGV)
63
+ selectors = VersionSelectorOptionsParser.call(ARGV).select { |s| !s[:ignore] }
64
+ ignore_selectors = VersionSelectorOptionsParser.call(ARGV).select { |s| s[:ignore] } + ignore_merge_selectors_from_environment_variable
63
65
  validate_can_i_deploy_selectors(selectors)
64
66
  dry_run = options.dry_run || ENV["PACT_BROKER_CAN_I_MERGE_DRY_RUN"] == "true"
65
67
  can_i_merge_options = { output: options.output, retry_while_unknown: options.retry_while_unknown, retry_interval: options.retry_interval, dry_run: dry_run, verbose: options.verbose }
66
- result = CanIDeploy.call(selectors, { with_main_branches: true }, can_i_merge_options, pact_broker_client_options)
68
+ result = CanIDeploy.call(selectors, { with_main_branches: true, ignore_selectors: ignore_selectors}, can_i_merge_options, pact_broker_client_options)
67
69
  $stdout.puts result.message
68
70
  $stdout.flush
69
71
  exit(1) unless result.success
@@ -121,6 +123,9 @@ module PactBroker
121
123
  def ignore_selectors_from_environment_variable
122
124
  ENV.fetch("PACT_BROKER_CAN_I_DEPLOY_IGNORE", "").split(",").collect(&:strip).collect{ |i| { pacticipant: i } }
123
125
  end
126
+ def ignore_merge_selectors_from_environment_variable
127
+ ENV.fetch("PACT_BROKER_CAN_I_MERGE_IGNORE", "").split(",").collect(&:strip).collect{ |i| { pacticipant: i } }
128
+ end
124
129
  end
125
130
  end
126
131
  end
@@ -1,5 +1,5 @@
1
1
  module PactBroker
2
2
  module Client
3
- VERSION = '1.76.2'
3
+ VERSION = '1.77.0'
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: pact_broker-client
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.76.2
4
+ version: 1.77.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Beth Skurrie
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2024-10-23 00:00:00.000000000 Z
11
+ date: 2024-10-24 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: httparty
@@ -161,7 +161,7 @@ files:
161
161
  - ci.sh
162
162
  - doc/CAN_I_DEPLOY_USAGE_WITH_TAGS.md
163
163
  - doc/pacts/markdown/Pact Broker Client - Pact Broker.md
164
- - doc/pacts/markdown/Pact Broker Client - Pactflow.md
164
+ - doc/pacts/markdown/Pact Broker Client - PactFlow.md
165
165
  - doc/pacts/markdown/README.md
166
166
  - example/scripts/README.md
167
167
  - example/scripts/deploy-consumer.sh