Class: Mrsk::Commands::Lock
- Inherits:
-
Base
- Object
- Base
- Mrsk::Commands::Lock
show all
- Defined in:
- lib/mrsk/commands/lock.rb
Instance Attribute Summary
Attributes inherited from Base
#config
Instance Method Summary
collapse
Methods inherited from Base
#container_id_for, #initialize, #run_over_ssh
Instance Method Details
#acquire(message, version) ⇒ Object
5
6
7
8
9
|
# File 'lib/mrsk/commands/lock.rb', line 5
def acquire(message, version)
combine \
[:mkdir, lock_dir],
write_lock_details(message, version)
end
|
#release ⇒ Object
11
12
13
14
15
|
# File 'lib/mrsk/commands/lock.rb', line 11
def release
combine \
[:rm, lock_details_file],
[:rm, "-r", lock_dir]
end
|
#status ⇒ Object
17
18
19
20
21
|
# File 'lib/mrsk/commands/lock.rb', line 17
def status
combine \
stat_lock_dir,
read_lock_details
end
|