Module: Ci::Maskable
- Extended by:
- ActiveSupport::Concern
- Included in:
- GroupVariable, InstanceVariable, Variable
- Defined in:
- app/models/concerns/ci/maskable.rb
Constant Summary collapse
- REGEX =
-
Single line
-
No escape characters
-
No variables
-
No spaces
-
Minimal length of 8 characters
-
Characters must be from the Base64 alphabet (RFC4648) with the addition of ‘@’, ‘:’, ‘.’, and ‘~’
-
Absolutely no fun is allowed
-
%r{\A[a-zA-Z0-9_+=/@:.~-]{8,}\z}
- MASK_AND_RAW_REGEX =
-
Single line
-
No spaces
-
Minimal length of 8 characters
-
Some fun is allowed
-
%r{\A\S{8,}\z}
Instance Method Summary collapse
Instance Method Details
#masked_and_expanded? ⇒ Boolean
33 34 35 36 37 |
# File 'app/models/concerns/ci/maskable.rb', line 33 def return masked? unless self.class.method_defined?(:raw) masked? && !raw? end |
#masked_and_raw? ⇒ Boolean
27 28 29 30 31 |
# File 'app/models/concerns/ci/maskable.rb', line 27 def masked_and_raw? return false unless self.class.method_defined?(:raw) masked? && raw? end |
#to_runner_variable ⇒ Object
39 40 41 |
# File 'app/models/concerns/ci/maskable.rb', line 39 def to_runner_variable super.merge(masked: masked?) end |