parameter_substitution 1.3.1 → 1.4.0

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: 85c67efeaefb3f001e0463995bc4fb9f3e74f355a0d90f1e88c9758098bdfcce
4
- data.tar.gz: d40e06c430ee77c4c5955de0564f5dc3ec9cd728dd61904838110839b68d9553
3
+ metadata.gz: 4376e3ac8cfe9523646f46d4eee41dd6099ba707337023c91db16c5f01f7950b
4
+ data.tar.gz: 8479263cc5b34314b869290a74b752fa2b689c776f608f9eb8cd7bb596fc0e72
5
5
  SHA512:
6
- metadata.gz: fc93edd7f1370d8bc70bb5e54194dfd0931616951e91528849c7589de68be4b8d0dcdd5a1e02c20f3f696e4038f01e05a73914d1909d74132c02c59aea8213dd
7
- data.tar.gz: 5409c67d415ba25c74369151dc109c32c3077967e56d449aaaf43bb8ef5213bbff69d002265bb5ca0e916f141f7fa110736637fd7ed434a162f3ccadadd7c0bf
6
+ metadata.gz: a02aa97a0db8bf18776f6da9a9dbebc71e9020342399829bea326d2417df42c88a0fb99684a29f4f1dd46c96cef4d44ea9695ce43ab5706890b6860858e71c72
7
+ data.tar.gz: 125d67a336d15987d27f59bd8a4b4f0a201d2e06db9310c0f8fb830045fc4808660a2627688bd77d22744ea6c24c53f218e569aafc1fd5d4d847ef349d771944
@@ -0,0 +1,13 @@
1
+ # frozen_string_literal: true
2
+
3
+ class ParameterSubstitution::Formatters::StringToBase64 < ParameterSubstitution::Formatters::Base
4
+ def self.description
5
+ "Converts strings to base64 encoding"
6
+ end
7
+
8
+ def self.format(value)
9
+ return nil if value.nil?
10
+
11
+ [value].pack("m0")
12
+ end
13
+ end
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  class ParameterSubstitution
4
- VERSION = "1.3.1"
4
+ VERSION = "1.4.0"
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: parameter_substitution
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.3.1
4
+ version: 1.4.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Invoca Development
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2022-05-11 00:00:00.000000000 Z
11
+ date: 2024-01-22 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activesupport
@@ -127,6 +127,7 @@ files:
127
127
  - lib/parameter_substitution/formatters/split_after_colon.rb
128
128
  - lib/parameter_substitution/formatters/split_and_find.rb
129
129
  - lib/parameter_substitution/formatters/split_before_colon.rb
130
+ - lib/parameter_substitution/formatters/string_to_base64.rb
130
131
  - lib/parameter_substitution/formatters/time_with_seconds.rb
131
132
  - lib/parameter_substitution/formatters/trim.rb
132
133
  - lib/parameter_substitution/formatters/upper.rb