Class: Environments::Local
- Inherits:
-
Object
- Object
- Environments::Local
- Defined in:
- lib/flakyci_rspec/environments/local.rb
Instance Method Summary collapse
Instance Method Details
#build_id ⇒ Object
23 24 25 |
# File 'lib/flakyci_rspec/environments/local.rb', line 23 def build_id Time.now.to_i.to_s end |
#build_name ⇒ Object
27 28 29 |
# File 'lib/flakyci_rspec/environments/local.rb', line 27 def build_name 'local' end |
#get_infos ⇒ Object
5 6 7 8 9 10 11 12 13 |
# File 'lib/flakyci_rspec/environments/local.rb', line 5 def get_infos { sha: sha, build_id: build_id, ref: get_ref, build_name: build_name, env_name: 'local' } end |
#get_ref ⇒ Object
19 20 21 |
# File 'lib/flakyci_rspec/environments/local.rb', line 19 def get_ref `git rev-parse --abbrev-ref HEAD`.strip! end |
#sha ⇒ Object
15 16 17 |
# File 'lib/flakyci_rspec/environments/local.rb', line 15 def sha `git rev-parse --short HEAD`.strip! end |