macOS FMA: Secretive.app - #45858
Conversation
There was a problem hiding this comment.
Claude Code Review
This repository is configured for manual code reviews. Comment @claude review to trigger a review and subscribe this PR to future pushes, or @claude review once for a one-time review.
Tip: disable this comment in your organization's Code Review settings.
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #45858 +/- ##
==========================================
- Coverage 66.78% 66.78% -0.01%
==========================================
Files 2747 2748 +1
Lines 219860 219862 +2
Branches 10842 10842
==========================================
+ Hits 146831 146832 +1
- Misses 59760 59761 +1
Partials 13269 13269
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (1)
WalkthroughAdds Secretive to Fleet's maintained apps: a Homebrew input JSON, a darwin output JSON for version 3.0.4 (including detection SQL, installer URL, checksum, and install/uninstall scripts), an apps registry entry for macOS, and a frontend React SVG icon plus registry mapping so the UI can display Secretive. Possibly related PRs
🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@ee/maintained-apps/outputs/secretive/darwin.json`:
- Line 19: The uninstall script calls trash with a quoted glob string
('~/Library/Containers/com.maxgoedjen.Secretive.*') so the wildcard is not
expanded and containers are not removed; update either the trash invocation or
the trash function to handle globs: remove the quotes around the pattern when
calling trash so the shell expands matches before passing them, or modify the
trash function (trash) to iterate over expanded matches (e.g., accept a pattern
parameter and loop over matching files/dirs, handling ~ expansion per match) and
then perform the existing existence check and mv for each matched path.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
Run ID: f297ada4-d2c6-4f33-b114-bf23f5eda366
⛔ Files ignored due to path filters (1)
website/assets/images/app-icon-secretive-60x60@2x.pngis excluded by!**/*.png
📒 Files selected for processing (5)
ee/maintained-apps/inputs/homebrew/secretive.jsonee/maintained-apps/outputs/apps.jsonee/maintained-apps/outputs/secretive/darwin.jsonfrontend/pages/SoftwarePage/components/icons/Secretive.tsxfrontend/pages/SoftwarePage/components/icons/index.ts
| } | ||
| ], | ||
| "refs": { | ||
| "5dd0dce3": "#!/bin/bash\n\n# variables\nAPPDIR=\"/Applications/\"\nLOGGED_IN_USER=$(scutil <<< \"show State:/Users/ConsoleUser\" | awk '/Name :/ { print $3 }')\n# functions\n\ntrash() {\n local logged_in_user=\"$1\"\n local target_file=\"$2\"\n local timestamp=\"$(date +%Y-%m-%d-%s)\"\n local rand=\"$(jot -r 1 0 99999)\"\n\n # replace ~ with /Users/$logged_in_user\n if [[ \"$target_file\" == ~* ]]; then\n target_file=\"/Users/$logged_in_user${target_file:1}\"\n fi\n\n local trash=\"/Users/$logged_in_user/.Trash\"\n local file_name=\"$(basename \"${target_file}\")\"\n\n if [[ -e \"$target_file\" ]]; then\n echo \"removing $target_file.\"\n mv -f \"$target_file\" \"$trash/${file_name}_${timestamp}_${rand}\"\n else\n echo \"$target_file doesn't exist.\"\n fi\n}\n\nsudo rm -rf \"$APPDIR/Secretive.app\"\ntrash $LOGGED_IN_USER '~/Library/Application Scripts/com.maxgoedjen.Secretive.Host'\ntrash $LOGGED_IN_USER '~/Library/Application Scripts/com.maxgoedjen.Secretive.SecretAgent'\ntrash $LOGGED_IN_USER '~/Library/Containers/com.maxgoedjen.Secretive.*'\n", |
There was a problem hiding this comment.
Handle wildcard container cleanup correctly in uninstall script.
Line 19 passes ~/Library/Containers/com.maxgoedjen.Secretive.* into trash, but trash treats it as a single literal path ([[ -e "$target_file" ]] + quoted mv). The wildcard won’t expand, so container directories are not removed.
🔧 Suggested fix (script-level)
trash $LOGGED_IN_USER '~/Library/Application Scripts/com.maxgoedjen.Secretive.Host'
trash $LOGGED_IN_USER '~/Library/Application Scripts/com.maxgoedjen.Secretive.SecretAgent'
-trash $LOGGED_IN_USER '~/Library/Containers/com.maxgoedjen.Secretive.*'
+for container in /Users/"$LOGGED_IN_USER"/Library/Containers/com.maxgoedjen.Secretive.*; do
+ [[ -e "$container" ]] || continue
+ trash "$LOGGED_IN_USER" "$container"
+done📝 Committable suggestion
‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.
| "5dd0dce3": "#!/bin/bash\n\n# variables\nAPPDIR=\"/Applications/\"\nLOGGED_IN_USER=$(scutil <<< \"show State:/Users/ConsoleUser\" | awk '/Name :/ { print $3 }')\n# functions\n\ntrash() {\n local logged_in_user=\"$1\"\n local target_file=\"$2\"\n local timestamp=\"$(date +%Y-%m-%d-%s)\"\n local rand=\"$(jot -r 1 0 99999)\"\n\n # replace ~ with /Users/$logged_in_user\n if [[ \"$target_file\" == ~* ]]; then\n target_file=\"/Users/$logged_in_user${target_file:1}\"\n fi\n\n local trash=\"/Users/$logged_in_user/.Trash\"\n local file_name=\"$(basename \"${target_file}\")\"\n\n if [[ -e \"$target_file\" ]]; then\n echo \"removing $target_file.\"\n mv -f \"$target_file\" \"$trash/${file_name}_${timestamp}_${rand}\"\n else\n echo \"$target_file doesn't exist.\"\n fi\n}\n\nsudo rm -rf \"$APPDIR/Secretive.app\"\ntrash $LOGGED_IN_USER '~/Library/Application Scripts/com.maxgoedjen.Secretive.Host'\ntrash $LOGGED_IN_USER '~/Library/Application Scripts/com.maxgoedjen.Secretive.SecretAgent'\ntrash $LOGGED_IN_USER '~/Library/Containers/com.maxgoedjen.Secretive.*'\n", | |
| "5dd0dce3": "#!/bin/bash\n\n# variables\nAPPDIR=\"/Applications/\"\nLOGGED_IN_USER=$(scutil <<< \"show State:/Users/ConsoleUser\" | awk '/Name :/ { print $3 }')\n# functions\n\ntrash() {\n local logged_in_user=\"$1\"\n local target_file=\"$2\"\n local timestamp=\"$(date +%Y-%m-%d-%s)\"\n local rand=\"$(jot -r 1 0 99999)\"\n\n # replace ~ with /Users/$logged_in_user\n if [[ \"$target_file\" == ~* ]]; then\n target_file=\"/Users/$logged_in_user${target_file:1}\"\n fi\n\n local trash=\"/Users/$logged_in_user/.Trash\"\n local file_name=\"$(basename \"${target_file}\")\"\n\n if [[ -e \"$target_file\" ]]; then\n echo \"removing $target_file.\"\n mv -f \"$target_file\" \"$trash/${file_name}_${timestamp}_${rand}\"\n else\n echo \"$target_file doesn't exist.\"\n fi\n}\n\nsudo rm -rf \"$APPDIR/Secretive.app\"\ntrash $LOGGED_IN_USER '~/Library/Application Scripts/com.maxgoedjen.Secretive.Host'\ntrash $LOGGED_IN_USER '~/Library/Application Scripts/com.maxgoedjen.Secretive.SecretAgent'\nfor container in /Users/"$LOGGED_IN_USER"/Library/Containers/com.maxgoedjen.Secretive.*; do\n [[ -e "$container" ]] || continue\n trash "$LOGGED_IN_USER" "$container"\ndone\n", |
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
In `@ee/maintained-apps/outputs/secretive/darwin.json` at line 19, The uninstall
script calls trash with a quoted glob string
('~/Library/Containers/com.maxgoedjen.Secretive.*') so the wildcard is not
expanded and containers are not removed; update either the trash invocation or
the trash function to handle globs: remove the quotes around the pattern when
calling trash so the shell expands matches before passing them, or modify the
trash function (trash) to iterate over expanded matches (e.g., accept a pattern
parameter and loop over matching files/dirs, handling ~ expansion per match) and
then perform the existing existence check and mv for each matched path.
Updated the description of the Secretive app to provide more detail about its functionality.
Summary by CodeRabbit