appydave-tools 0.20.0 → 0.21.0
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 +15 -0
- data/bin/bank_reconciliation.rb +0 -1
- data/bin/configuration.rb +0 -1
- data/bin/dam +268 -14
- data/docs/dam/dam-testing-plan.md +152 -86
- data/docs/dam/prd-client-sharing.md +693 -0
- data/docs/dam/windows/README.md +40 -0
- data/docs/development/CODEX-recommendations.md +13 -9
- data/lib/appydave/tools/configuration/models/config_base.rb +1 -2
- data/lib/appydave/tools/dam/manifest_generator.rb +89 -36
- data/lib/appydave/tools/dam/repo_push.rb +1 -1
- data/lib/appydave/tools/dam/repo_status.rb +30 -8
- data/lib/appydave/tools/dam/s3_operations.rb +64 -8
- data/lib/appydave/tools/dam/share_operations.rb +234 -0
- data/lib/appydave/tools/dam/status.rb +8 -4
- data/lib/appydave/tools/version.rb +1 -1
- data/lib/appydave/tools.rb +1 -0
- data/package.json +1 -1
- metadata +7 -7
- data/docs/SESSION-SUMMARY-WINDOWS-PREP.md +0 -340
- data/docs/WINDOWS-COMPATIBILITY-REPORT.md +0 -429
- data/docs/WINDOWS-START-HERE.md +0 -202
- /data/docs/dam/{windows-testing-guide.md → windows/dam-testing-plan-windows-powershell.md} +0 -0
- /data/docs/{WINDOWS-SETUP.md → dam/windows/installation.md} +0 -0
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: c9c1294eb12c004bfbf7d5c3af2ad72e70202729867d5b2e1978d6710f573eca
|
|
4
|
+
data.tar.gz: 4c00d396ba791995706c8caea17eb36b65c0c6142533281ceb83d75e74a90d00
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 9c9e76453f9594c21c6e5a3571369f715eda1c5262fc5e80429776ed1a4e6afc29a6f258c238df3ef68ed3fc6a769dc5186168674aa90c9d0ee8705e2d056da9
|
|
7
|
+
data.tar.gz: 1dac5dcaa14e3731fff08d6bfb0f3b6128549920503dd6e5869caf89696d40b6e4f745afeade7261d7ccc0a51baa93722b4204b8808b140537c041f393c77703
|
data/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,18 @@
|
|
|
1
|
+
## [0.20.1](https://github.com/appydave/appydave-tools/compare/v0.20.0...v0.20.1) (2025-11-10)
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
### Bug Fixes
|
|
5
|
+
|
|
6
|
+
* remove noisy backup log message from self-healing config saves ([f9dacfd](https://github.com/appydave/appydave-tools/commit/f9dacfd74cce5f991c7f4bafb12d1494aa6ee4ab))
|
|
7
|
+
|
|
8
|
+
# [0.20.0](https://github.com/appydave/appydave-tools/compare/v0.19.0...v0.20.0) (2025-11-10)
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
### Features
|
|
12
|
+
|
|
13
|
+
* Phase 2: add unified status and git repo commands (status, repo-status, repo-sync, repo-push) ([c9ff7de](https://github.com/appydave/appydave-tools/commit/c9ff7dee9bd2d60954205df08c23dd673960a524))
|
|
14
|
+
* Phase 2: add unified status and git repo commands (status, repo-status, repo-sync, repo-push) ([b74f343](https://github.com/appydave/appydave-tools/commit/b74f3436e188cfa7dbdff386d35cb96d75f80860))
|
|
15
|
+
|
|
1
16
|
# [0.19.0](https://github.com/appydave/appydave-tools/compare/v0.18.5...v0.19.0) (2025-11-10)
|
|
2
17
|
|
|
3
18
|
|
data/bin/bank_reconciliation.rb
CHANGED
data/bin/configuration.rb
CHANGED
data/bin/dam
CHANGED
|
@@ -25,6 +25,8 @@ class VatCLI
|
|
|
25
25
|
'repo-status' => method(:repo_status_command),
|
|
26
26
|
'repo-sync' => method(:repo_sync_command),
|
|
27
27
|
'repo-push' => method(:repo_push_command),
|
|
28
|
+
's3-share' => method(:s3_share_command),
|
|
29
|
+
's3-discover' => method(:s3_discover_command),
|
|
28
30
|
# Deprecated aliases (for backward compatibility)
|
|
29
31
|
's3-cleanup' => method(:s3_cleanup_remote_command),
|
|
30
32
|
'cleanup-local' => method(:s3_cleanup_local_command)
|
|
@@ -66,6 +68,10 @@ class VatCLI
|
|
|
66
68
|
show_config_help
|
|
67
69
|
when 'list'
|
|
68
70
|
show_list_help
|
|
71
|
+
when 's3-share'
|
|
72
|
+
show_s3_share_help
|
|
73
|
+
when 's3-discover'
|
|
74
|
+
show_s3_discover_help
|
|
69
75
|
when 's3-up', 's3-down', 's3-status', 's3-cleanup-remote', 's3-cleanup-local', 'archive', 'manifest', 'sync-ssd'
|
|
70
76
|
show_s3_help(topic)
|
|
71
77
|
when 's3-cleanup', 'cleanup-local'
|
|
@@ -151,6 +157,30 @@ class VatCLI
|
|
|
151
157
|
exit 1
|
|
152
158
|
end
|
|
153
159
|
|
|
160
|
+
# Share file via pre-signed URL
|
|
161
|
+
def s3_share_command(args)
|
|
162
|
+
options = parse_share_args(args)
|
|
163
|
+
|
|
164
|
+
share_ops = Appydave::Tools::Dam::ShareOperations.new(options[:brand], options[:project])
|
|
165
|
+
share_ops.generate_links(files: options[:file], expires: options[:expires], download: options[:download])
|
|
166
|
+
rescue StandardError => e
|
|
167
|
+
puts "❌ Error: #{e.message}"
|
|
168
|
+
exit 1
|
|
169
|
+
end
|
|
170
|
+
|
|
171
|
+
# Discover files in S3 for a project
|
|
172
|
+
def s3_discover_command(args)
|
|
173
|
+
options = parse_discover_args(args)
|
|
174
|
+
files = fetch_s3_files(options[:brand_key], options[:project_id])
|
|
175
|
+
|
|
176
|
+
return if handle_empty_files?(files, options[:brand_key], options[:project_id])
|
|
177
|
+
|
|
178
|
+
display_s3_files(files, options[:brand_key], options[:project_id], options[:shareable])
|
|
179
|
+
rescue StandardError => e
|
|
180
|
+
puts "❌ Error: #{e.message}"
|
|
181
|
+
exit 1
|
|
182
|
+
end
|
|
183
|
+
|
|
154
184
|
# Archive project to SSD
|
|
155
185
|
def archive_command(args)
|
|
156
186
|
options = parse_s3_args(args, 'archive')
|
|
@@ -273,19 +303,14 @@ class VatCLI
|
|
|
273
303
|
project_arg = args[1]
|
|
274
304
|
|
|
275
305
|
if brand_arg.nil?
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
puts '❌ Could not auto-detect brand from current directory'
|
|
280
|
-
puts 'Usage: dam status <brand> [project]'
|
|
281
|
-
exit 1
|
|
282
|
-
end
|
|
283
|
-
brand_key = brand
|
|
284
|
-
else
|
|
285
|
-
brand_key = brand_arg
|
|
286
|
-
project_id = project_arg ? Appydave::Tools::Dam::ProjectResolver.resolve(brand_arg, project_arg) : nil
|
|
306
|
+
puts '❌ Brand argument required'
|
|
307
|
+
puts 'Usage: dam status <brand> [project]'
|
|
308
|
+
exit 1
|
|
287
309
|
end
|
|
288
310
|
|
|
311
|
+
brand_key = brand_arg
|
|
312
|
+
project_id = project_arg ? Appydave::Tools::Dam::ProjectResolver.resolve(brand_arg, project_arg) : nil
|
|
313
|
+
|
|
289
314
|
status = Appydave::Tools::Dam::Status.new(brand_key, project_id)
|
|
290
315
|
status.show
|
|
291
316
|
rescue StandardError => e
|
|
@@ -402,6 +427,113 @@ class VatCLI
|
|
|
402
427
|
{ brand: brand_key, project: project_id, dry_run: dry_run, force: force }
|
|
403
428
|
end
|
|
404
429
|
|
|
430
|
+
def parse_share_args(args)
|
|
431
|
+
# Extract --expires flag
|
|
432
|
+
expires = '7d' # default
|
|
433
|
+
if (expires_index = args.index('--expires'))
|
|
434
|
+
expires = args[expires_index + 1]
|
|
435
|
+
args.delete_at(expires_index + 1)
|
|
436
|
+
args.delete_at(expires_index)
|
|
437
|
+
end
|
|
438
|
+
|
|
439
|
+
# Extract --download flag
|
|
440
|
+
download = args.include?('--download')
|
|
441
|
+
|
|
442
|
+
# Remove other flags
|
|
443
|
+
args = args.reject { |arg| arg.start_with?('--') }
|
|
444
|
+
|
|
445
|
+
brand_arg = args[0]
|
|
446
|
+
project_arg = args[1]
|
|
447
|
+
file_arg = args[2]
|
|
448
|
+
|
|
449
|
+
show_share_usage_and_exit if brand_arg.nil? || project_arg.nil? || file_arg.nil?
|
|
450
|
+
|
|
451
|
+
brand_key = brand_arg
|
|
452
|
+
brand = Appydave::Tools::Dam::Config.expand_brand(brand_arg)
|
|
453
|
+
project_id = Appydave::Tools::Dam::ProjectResolver.resolve(brand_arg, project_arg)
|
|
454
|
+
|
|
455
|
+
# Set ENV for compatibility with ConfigLoader
|
|
456
|
+
ENV['BRAND_PATH'] = Appydave::Tools::Dam::Config.brand_path(brand)
|
|
457
|
+
|
|
458
|
+
{ brand: brand_key, project: project_id, file: file_arg, expires: expires, download: download }
|
|
459
|
+
end
|
|
460
|
+
|
|
461
|
+
def show_share_usage_and_exit
|
|
462
|
+
puts 'Usage: dam s3-share <brand> <project> <file> [--expires 7d] [--download]'
|
|
463
|
+
puts ''
|
|
464
|
+
puts 'Options:'
|
|
465
|
+
puts ' --expires TIME Expiry time (default: 7d)'
|
|
466
|
+
puts ' --download Force download instead of viewing in browser'
|
|
467
|
+
puts ''
|
|
468
|
+
puts 'Examples:'
|
|
469
|
+
puts ' dam s3-share appydave b70 video.mp4'
|
|
470
|
+
puts ' dam s3-share appydave b70 video.mp4 --expires 24h'
|
|
471
|
+
puts ' dam s3-share appydave b70 video.mp4 --download'
|
|
472
|
+
puts ' dam s3-share voz boy-baker final-edit.mov --expires 3d --download'
|
|
473
|
+
exit 1
|
|
474
|
+
end
|
|
475
|
+
|
|
476
|
+
def parse_discover_args(args)
|
|
477
|
+
shareable = args.include?('--shareable')
|
|
478
|
+
args = args.reject { |arg| arg.start_with?('--') }
|
|
479
|
+
|
|
480
|
+
brand_arg = args[0]
|
|
481
|
+
project_arg = args[1]
|
|
482
|
+
|
|
483
|
+
if brand_arg.nil? || project_arg.nil?
|
|
484
|
+
puts 'Usage: dam s3-discover <brand> <project> [--shareable]'
|
|
485
|
+
puts ''
|
|
486
|
+
puts 'Examples:'
|
|
487
|
+
puts ' dam s3-discover appydave b70 # List files'
|
|
488
|
+
puts ' dam s3-discover appydave b70 --shareable # Generate share commands'
|
|
489
|
+
exit 1
|
|
490
|
+
end
|
|
491
|
+
|
|
492
|
+
brand_key = brand_arg
|
|
493
|
+
brand = Appydave::Tools::Dam::Config.expand_brand(brand_arg)
|
|
494
|
+
project_id = Appydave::Tools::Dam::ProjectResolver.resolve(brand_arg, project_arg)
|
|
495
|
+
|
|
496
|
+
# Set ENV for compatibility with ConfigLoader
|
|
497
|
+
ENV['BRAND_PATH'] = Appydave::Tools::Dam::Config.brand_path(brand)
|
|
498
|
+
|
|
499
|
+
{ brand_key: brand_key, project_id: project_id, shareable: shareable }
|
|
500
|
+
end
|
|
501
|
+
|
|
502
|
+
def fetch_s3_files(brand_key, project_id)
|
|
503
|
+
s3_ops = Appydave::Tools::Dam::S3Operations.new(brand_key, project_id)
|
|
504
|
+
s3_ops.list_s3_files
|
|
505
|
+
end
|
|
506
|
+
|
|
507
|
+
def handle_empty_files?(files, brand_key, project_id)
|
|
508
|
+
return false unless files.empty?
|
|
509
|
+
|
|
510
|
+
puts "📭 No files found in S3 for #{brand_key}/#{project_id}"
|
|
511
|
+
puts ''
|
|
512
|
+
puts 'Upload files first:'
|
|
513
|
+
puts " dam s3-up #{brand_key} #{project_id}"
|
|
514
|
+
true
|
|
515
|
+
end
|
|
516
|
+
|
|
517
|
+
def display_s3_files(files, brand_key, project_id, shareable)
|
|
518
|
+
puts ''
|
|
519
|
+
puts "📁 Files in S3: #{brand_key}/#{project_id}"
|
|
520
|
+
puts ''
|
|
521
|
+
|
|
522
|
+
files.each do |file_info|
|
|
523
|
+
# list_s3_files returns array of hashes with 'Key', 'Size', 'ETag'
|
|
524
|
+
s3_key = file_info['Key']
|
|
525
|
+
filename = File.basename(s3_key)
|
|
526
|
+
|
|
527
|
+
if shareable
|
|
528
|
+
puts "dam s3-share #{brand_key} #{project_id} #{filename}"
|
|
529
|
+
else
|
|
530
|
+
puts filename
|
|
531
|
+
end
|
|
532
|
+
end
|
|
533
|
+
|
|
534
|
+
puts ''
|
|
535
|
+
end
|
|
536
|
+
|
|
405
537
|
# Help text methods
|
|
406
538
|
# rubocop:disable Metrics/MethodLength
|
|
407
539
|
def show_main_help
|
|
@@ -414,6 +546,14 @@ class VatCLI
|
|
|
414
546
|
help [command] Show help information
|
|
415
547
|
list [brand] [pattern] List brands/projects
|
|
416
548
|
|
|
549
|
+
Status & Monitoring:
|
|
550
|
+
status <brand> [project] Show unified status (local/S3/SSD/git)
|
|
551
|
+
|
|
552
|
+
Git Repository Commands:
|
|
553
|
+
repo-status <brand> [--all] Check git status for brand repos
|
|
554
|
+
repo-sync <brand> [--all] Pull updates for brand repos
|
|
555
|
+
repo-push <brand> [project] Push changes for brand repo
|
|
556
|
+
|
|
417
557
|
S3 Sync Commands:
|
|
418
558
|
s3-up <brand> <project> Upload to S3 staging
|
|
419
559
|
s3-down <brand> <project> Download from S3 staging
|
|
@@ -421,6 +561,10 @@ class VatCLI
|
|
|
421
561
|
s3-cleanup-remote <brand> <project> Delete S3 files
|
|
422
562
|
s3-cleanup-local <brand> <project> Delete local s3-staging files
|
|
423
563
|
|
|
564
|
+
S3 Sharing Commands:
|
|
565
|
+
s3-discover <brand> <project> List files available in S3
|
|
566
|
+
s3-share <brand> <project> <file> Generate shareable pre-signed URL
|
|
567
|
+
|
|
424
568
|
Archive Commands:
|
|
425
569
|
archive <brand> <project> Copy project to SSD backup
|
|
426
570
|
manifest <brand> [--all] Generate project manifest
|
|
@@ -438,10 +582,18 @@ class VatCLI
|
|
|
438
582
|
|
|
439
583
|
Examples:
|
|
440
584
|
dam list
|
|
585
|
+
dam status appydave
|
|
586
|
+
dam status appydave b65
|
|
587
|
+
dam repo-status appydave
|
|
588
|
+
dam repo-sync appydave
|
|
441
589
|
dam s3-up appydave b65
|
|
442
590
|
dam s3-down voz boy-baker --dry-run
|
|
443
591
|
dam s3-status appydave b65
|
|
444
|
-
dam s3-
|
|
592
|
+
dam s3-discover appydave b70
|
|
593
|
+
dam s3-discover appydave b70 --shareable
|
|
594
|
+
dam s3-share appydave b70 video.mp4
|
|
595
|
+
dam s3-share appydave b70 video.mp4 --expires 24h
|
|
596
|
+
dam s3-cleanup-remote appydave b65 --force
|
|
445
597
|
|
|
446
598
|
For more information: https://github.com/appydave/appydave-tools
|
|
447
599
|
HELP
|
|
@@ -462,9 +614,9 @@ class VatCLI
|
|
|
462
614
|
ss → v-supportsignal (SupportSignal client)
|
|
463
615
|
|
|
464
616
|
Usage:
|
|
465
|
-
dam list # Show all brands
|
|
466
|
-
dam list --summary # Show brands with project counts
|
|
617
|
+
dam list # Show all brands with counts
|
|
467
618
|
dam list appydave # List all AppyDave projects
|
|
619
|
+
dam list appydave 'b6*' # List AppyDave projects matching pattern
|
|
468
620
|
dam s3-up voz boy-baker # Upload VOZ project
|
|
469
621
|
HELP
|
|
470
622
|
end
|
|
@@ -573,6 +725,108 @@ class VatCLI
|
|
|
573
725
|
HELP
|
|
574
726
|
end
|
|
575
727
|
|
|
728
|
+
def show_s3_share_help
|
|
729
|
+
puts <<~HELP
|
|
730
|
+
S3 Share Command - Generate Shareable Pre-Signed URLs
|
|
731
|
+
|
|
732
|
+
Generate time-limited secure URLs for sharing video files with clients.
|
|
733
|
+
Recipients don't need AWS access - just click the link in their browser!
|
|
734
|
+
|
|
735
|
+
Usage: dam s3-share <brand> <project> <file> [OPTIONS]
|
|
736
|
+
|
|
737
|
+
Options:
|
|
738
|
+
--expires TIME Expiry time (default: 7d)
|
|
739
|
+
Examples: 24h, 48h, 3d, 7d
|
|
740
|
+
--download Force download instead of viewing in browser (default: inline viewing)
|
|
741
|
+
|
|
742
|
+
How It Works:
|
|
743
|
+
1. Generates pre-signed S3 URL (time-limited, secure)
|
|
744
|
+
2. Copies URL to clipboard automatically
|
|
745
|
+
3. Shows expiry date/time
|
|
746
|
+
4. By default: Opens in browser (inline) - perfect for video playback
|
|
747
|
+
5. With --download: Forces file download
|
|
748
|
+
|
|
749
|
+
Examples:
|
|
750
|
+
dam s3-share appydave b70 video.mp4
|
|
751
|
+
# → View in browser (default), 7-day expiry
|
|
752
|
+
|
|
753
|
+
dam s3-share appydave b70 video.mp4 --download
|
|
754
|
+
# → Force download, 7-day expiry
|
|
755
|
+
|
|
756
|
+
dam s3-share appydave b70 final-edit.mp4 --expires 24h
|
|
757
|
+
# → View in browser, 24-hour expiry for quick review
|
|
758
|
+
|
|
759
|
+
dam s3-share voz boy-baker scene-01.mov --expires 3d --download
|
|
760
|
+
# → Force download, 3-day expiry for client approval
|
|
761
|
+
|
|
762
|
+
Viewing Modes:
|
|
763
|
+
🎬 Default (inline): Opens in browser - great for video playback
|
|
764
|
+
📥 --download flag: Forces download - better for archiving
|
|
765
|
+
|
|
766
|
+
Security:
|
|
767
|
+
✅ Time-limited (expires automatically)
|
|
768
|
+
✅ Cryptographically signed (can't be tampered with)
|
|
769
|
+
✅ No AWS state stored (signature encodes everything)
|
|
770
|
+
✅ Revocable (delete S3 file if needed)
|
|
771
|
+
⚠️ Anyone with URL can access (don't share publicly)
|
|
772
|
+
|
|
773
|
+
Prerequisites:
|
|
774
|
+
- File must be uploaded to S3 first
|
|
775
|
+
- Run: dam s3-up <brand> <project>
|
|
776
|
+
|
|
777
|
+
Use Cases:
|
|
778
|
+
- Share videos with clients for review (inline)
|
|
779
|
+
- Send final files for download (--download)
|
|
780
|
+
- Provide temporary access to collaborators
|
|
781
|
+
- Quick video sharing without email attachments
|
|
782
|
+
|
|
783
|
+
For more information: https://github.com/appydave/appydave-tools
|
|
784
|
+
HELP
|
|
785
|
+
end
|
|
786
|
+
|
|
787
|
+
def show_s3_discover_help
|
|
788
|
+
puts <<~HELP
|
|
789
|
+
S3 Discover Command - List Files in S3
|
|
790
|
+
|
|
791
|
+
Discover what video files exist in S3 for a project.
|
|
792
|
+
Useful before sharing to see available files.
|
|
793
|
+
|
|
794
|
+
Usage: dam s3-discover <brand> <project> [--shareable]
|
|
795
|
+
|
|
796
|
+
Modes:
|
|
797
|
+
Default List filenames only
|
|
798
|
+
--shareable Generate ready-to-run share commands
|
|
799
|
+
|
|
800
|
+
Examples:
|
|
801
|
+
dam s3-discover appydave b70
|
|
802
|
+
# Output:
|
|
803
|
+
# xmen.mp4
|
|
804
|
+
# behind-the-scenes.mov
|
|
805
|
+
|
|
806
|
+
dam s3-discover appydave b70 --shareable
|
|
807
|
+
# Output:
|
|
808
|
+
# dam s3-share appydave b70 xmen.mp4
|
|
809
|
+
# dam s3-share appydave b70 behind-the-scenes.mov
|
|
810
|
+
|
|
811
|
+
Workflow:
|
|
812
|
+
1. Upload files: dam s3-up appydave b70
|
|
813
|
+
2. Discover files: dam s3-discover appydave b70
|
|
814
|
+
3. Share specific file: dam s3-share appydave b70 xmen.mp4
|
|
815
|
+
|
|
816
|
+
Use Cases:
|
|
817
|
+
- Find files available for sharing
|
|
818
|
+
- Generate multiple share commands at once
|
|
819
|
+
- Quick project file listing without downloading
|
|
820
|
+
- Copy-paste shareable commands for clients
|
|
821
|
+
|
|
822
|
+
Prerequisites:
|
|
823
|
+
- Files must be uploaded to S3 first
|
|
824
|
+
- Run: dam s3-up <brand> <project>
|
|
825
|
+
|
|
826
|
+
For more information: https://github.com/appydave/appydave-tools
|
|
827
|
+
HELP
|
|
828
|
+
end
|
|
829
|
+
|
|
576
830
|
# rubocop:disable Metrics/CyclomaticComplexity
|
|
577
831
|
def show_s3_help(command)
|
|
578
832
|
case command
|