live_set 0.2.1 → 0.2.2

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: 9caef58c0bed30ead696f9d64848c74038aa520d83a2c47796cb0081c0ad6b14
4
- data.tar.gz: 85906715baa37c0ed5a2fd4f0a101e37d5c5728a4385f0754d120514b18d7b89
3
+ metadata.gz: dc8a391b89faff33b3611d93ff5223d28d14c9a87359bc98a9005b93908db8d9
4
+ data.tar.gz: a2aab3005d94ad93eaf5f94bd61af6770b1656ce1addc8d54a83bab20e3faeb3
5
5
  SHA512:
6
- metadata.gz: 88404bf0b8d04663da0d7a334a8affd9d930df965af1b3fed1b3a2b9286881380ecba7882badbf71d0612674a3f77775a436a6e5a505a4bb9b25801522ad5ab6
7
- data.tar.gz: d633040d514b77e4984e936c4676fd5f124ee30da405b6c612f916edbd33625cbacb0a1d35812aaae393f03436cab2054144e54a75db1214ba64196c92511cf4
6
+ metadata.gz: 54672b577455e31011165d8c78e1402ac74754f67d53ae07ca9fff123af8263c06650960fa8ce372511f8c26f6d206a9ab829253d4951a9eb7bfa08cd9c5cb6f
7
+ data.tar.gz: 24c3db212c86904c2935c6ea4bad27c80e6ed2e2ca535f4e32cd83b9828f96bdadf3bc1a62bb0f6ae9dc2b7c40a85821aa3db5b79bfe18f3dacd4d3ec4f8bbc5
data/CHANGELOG.md CHANGED
@@ -1,5 +1,9 @@
1
1
  # Change Log
2
2
 
3
+ ## 0.2.2
4
+
5
+ * Displays `Ready for transfer to Push 3 Standalone` in green if Live set is ready,
6
+ or displays the reasons for not being ready in red.
3
7
 
4
8
  ## 0.2.1
5
9
 
@@ -16,6 +16,23 @@ class AllTracks
16
16
  end
17
17
  end
18
18
 
19
+ def ready_for_p3s
20
+ @track_instances.all?(&:clips_collected?) && all_frozen
21
+ end
22
+
23
+ def p3s_tx_msg
24
+ return 'Ready for transfer to Push 3 Standalone'.green if ready_for_p3s
25
+
26
+ response = []
27
+ response << 'Some tracks are not frozen'.red unless all_frozen
28
+ @track_instances.each do |track|
29
+ track.audio_clips.each do |clip|
30
+ response << "Clip '#{clip.relative_path}' has not been collected".red unless clip.relative_path.start_with?('Samples/Imported/')
31
+ end
32
+ end
33
+ response.join "\n"
34
+ end
35
+
19
36
  def summary
20
37
  all_frozen_msg = all_frozen ? ' (All are frozen)'.yellow : ''
21
38
  push_warning = all_frozen ? '' : "\nWarning: some tracks are not frozen, so this set should not be transferred to Push 3 Standalone.".red
@@ -27,6 +44,7 @@ class AllTracks
27
44
  end
28
45
  total_set_size = "Total set size: #{human_file_size total_size}".yellow
29
46
  <<~END_MSG
47
+ #{p3s_tx_msg}
30
48
  #{total_set_size}#{size_warning}#{push_warning}
31
49
  #{@track_instances.count} tracks#{all_frozen_msg}:
32
50
  END_MSG
@@ -20,6 +20,10 @@ class LiveAudioClip
20
20
  @relative_path_type = @file_ref.RelativePathType['Value'] # What do these values mean?
21
21
  end
22
22
 
23
+ def collected?
24
+ @relative_path.start_with? 'Samples/Imported/'
25
+ end
26
+
23
27
  def show_clip
24
28
  [" #{@relative_path}", human_file_size(@file_size).rjust(8, ' '), @last_modified.strftime('%Y-%m-%d %H:%M:%S')]
25
29
  end
@@ -19,6 +19,10 @@ class LiveAudioTrack
19
19
  @track_size = @audio_clips.sum(&:file_size) || 0
20
20
  end
21
21
 
22
+ def clips_collected?
23
+ @audio_clips.all?(&:collected?)
24
+ end
25
+
22
26
  def show_track(all_frozen)
23
27
  name = @audio_track.Name.EffectiveName['Value']
24
28
  frozen = !all_frozen && @audio_track.frozen? ? ' **frozen**' : ''
@@ -6,9 +6,9 @@ VERBOSITY = %w[trace debug verbose info warning error fatal panic quiet].freeze
6
6
  def help_live_set(msg = nil)
7
7
  printf "Error: #{msg}\n\n".yellow unless msg.nil?
8
8
  msg = <<~END_HELP
9
- Live_sete displays information about an Ableton Live set or converts a Live 12 set to Live 11 format.
9
+ Live_set displays information about an Ableton Live set or converts a Live 12 set to Live 11 format.
10
10
  If the special folder called 'Ableton Project Info' is not present in the same folder as the .als file, a warning is generated.
11
- Similarly, if 'Ableton Project Info' is present in any parent folder, a warning is issued.
11
+ Similarly, if 'Ableton Project Info' is present in any parent folder, a warning is issued and the user is asked if the directory should be renamed.
12
12
 
13
13
  Syntax: live_set OPTIONS PATH_TO_ALS_FILE
14
14
 
@@ -1,3 +1,3 @@
1
1
  module LiveSetVersion
2
- VERSION = '0.2.1'.freeze unless defined? VERSION
2
+ VERSION = '0.2.2'.freeze unless defined? VERSION
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: live_set
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.1
4
+ version: 0.2.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Mike Slinn