live_set 0.2.2 → 0.2.3
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 +4 -4
- data/CHANGELOG.md +5 -0
- data/lib/live_set/live_set_all_tracks.rb +6 -4
- data/lib/live_set/live_set_audio_clip.rb +2 -1
- data/lib/live_set/live_set_audio_track.rb +6 -4
- data/lib/live_set/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 32e6a9b1a71d9857578af4ffc6cc644eaf476cf719af3be8c8983f2c51dd1f3a
|
4
|
+
data.tar.gz: b4c43b90e98dfb6917d998bf274a603275e6c90a1601977597d5d65d7e3aa77c
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: b400c0bedce4e5d903abe7b32d50abf4087ba1ab7cbf077a5bd559c9fda2a9a9ebf322710cbe211223413e8d79b83cd0fdf583526f5d514094d88d97a94cb7b6
|
7
|
+
data.tar.gz: '0891c4261574ef1d988070eba9f8bdd8cd29fc6eb5a3733a41a8afa714e2f46dd0da61a8a06d58cde5d81a8ea96ea76dfea83ccc2c1b9fb923ebfa974a5dfd86'
|
data/CHANGELOG.md
CHANGED
@@ -24,18 +24,20 @@ class AllTracks
|
|
24
24
|
return 'Ready for transfer to Push 3 Standalone'.green if ready_for_p3s
|
25
25
|
|
26
26
|
response = []
|
27
|
-
response << 'Some tracks are not frozen'.red unless all_frozen
|
27
|
+
response << ' - Some tracks are not frozen.'.red unless all_frozen
|
28
28
|
@track_instances.each do |track|
|
29
29
|
track.audio_clips.each do |clip|
|
30
|
-
response << "Clip '#{clip.
|
30
|
+
response << " - Clip '#{clip.absolute_path}' has not been collected.".red unless clip.relative_path.start_with?('Samples/Imported/')
|
31
31
|
end
|
32
32
|
end
|
33
|
+
response.reverse!
|
34
|
+
response << 'Warning: This set should not be transferred to Push 3 Standalone.'.red
|
35
|
+
response.reverse!
|
33
36
|
response.join "\n"
|
34
37
|
end
|
35
38
|
|
36
39
|
def summary
|
37
40
|
all_frozen_msg = all_frozen ? ' (All are frozen)'.yellow : ''
|
38
|
-
push_warning = all_frozen ? '' : "\nWarning: some tracks are not frozen, so this set should not be transferred to Push 3 Standalone.".red
|
39
41
|
total_size = @track_instances.sum(&:track_size)
|
40
42
|
size_warning = if total_size >= 2_000_000_000
|
41
43
|
"\nWarning: This set is too large to be frozen and too large too large to transfer to Push 3 Standalone.".red
|
@@ -45,7 +47,7 @@ class AllTracks
|
|
45
47
|
total_set_size = "Total set size: #{human_file_size total_size}".yellow
|
46
48
|
<<~END_MSG
|
47
49
|
#{p3s_tx_msg}
|
48
|
-
#{total_set_size}#{size_warning}
|
50
|
+
#{total_set_size}#{size_warning}
|
49
51
|
#{@track_instances.count} tracks#{all_frozen_msg}:
|
50
52
|
END_MSG
|
51
53
|
end
|
@@ -1,7 +1,8 @@
|
|
1
1
|
require 'date'
|
2
2
|
|
3
3
|
class LiveAudioClip
|
4
|
-
attr_reader :file_size
|
4
|
+
attr_reader :absolute_path, :file_ref, :file_size, :file_type, :id, :last_modified, :live_pack_name, :need_refreeze, :relative_path,
|
5
|
+
:relative_path_type
|
5
6
|
|
6
7
|
# @param audio_clip is an inner <ClipSlot/> element from an Ableton Live .als file as parsed by Nokogiri
|
7
8
|
def initialize(id, need_refreeze, clip_slot)
|
@@ -1,5 +1,5 @@
|
|
1
1
|
class LiveAudioTrack
|
2
|
-
attr_reader :frozen, :track_size
|
2
|
+
attr_reader :audio_clips, :clip_slots, :frozen, :id, :track_size
|
3
3
|
|
4
4
|
# @param audio_track is an <AudioTrack/> element from an Ableton Live .als file as parsed by Nokogiri
|
5
5
|
def initialize(audio_track)
|
@@ -13,7 +13,8 @@ class LiveAudioTrack
|
|
13
13
|
clip_slot_id = clip_slot['Id']
|
14
14
|
need_refreeze = clip_slot.NeedRefreeze['Value'].to_bool
|
15
15
|
inner_clip_slot = clip_slot.ClipSlot
|
16
|
-
LiveAudioClip.new clip_slot_id, need_refreeze, inner_clip_slot if
|
16
|
+
LiveAudioClip.new clip_slot_id, need_refreeze, inner_clip_slot if
|
17
|
+
inner_clip_slot.respond_to?(:Value) && !inner_clip_slot.Value.children.empty?
|
17
18
|
end
|
18
19
|
@audio_clips.compact!
|
19
20
|
@track_size = @audio_clips.sum(&:file_size) || 0
|
@@ -25,8 +26,9 @@ class LiveAudioTrack
|
|
25
26
|
|
26
27
|
def show_track(all_frozen)
|
27
28
|
name = @audio_track.Name.EffectiveName['Value']
|
28
|
-
frozen =
|
29
|
-
|
29
|
+
frozen = @audio_track.frozen? ? ' frozen'.green : ' **not frozen**'.red unless all_frozen || @audio_clips.empty?
|
30
|
+
size = ", totaling #{human_file_size @track_size}" unless @audio_clips.empty?
|
31
|
+
"Track '#{name}'#{frozen} (#{@audio_clips.length} clips#{size})\n" + show_clips
|
30
32
|
end
|
31
33
|
|
32
34
|
def show_clips
|
data/lib/live_set/version.rb
CHANGED