-
Notifications
You must be signed in to change notification settings - Fork 6
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix(taskfiles): Make remote utilities macOS-compliant. #21
Conversation
WalkthroughThe pull request updates the Changes
Sequence Diagram(s)sequenceDiagram
participant User
participant TaskExecutor
participant OSCheck
participant Shell
User->>TaskExecutor: Start download-and-extract-tar task
TaskExecutor->>OSCheck: Determine operating system
OSCheck-->>TaskExecutor: Return OS type (darwin/other)
alt macOS
TaskExecutor->>Shell: Use "gtar" for extraction
else
TaskExecutor->>Shell: Use "tar" for extraction
end
TaskExecutor->>Shell: Remove output directory (rm -rf)
TaskExecutor->>Shell: Create output directory (mkdir -p)
TaskExecutor->>Shell: Download and extract tar archive using ARCHIVER
Possibly related PRs
Suggested reviewers
📜 Recent review detailsConfiguration used: CodeRabbit UI 📒 Files selected for processing (1)
🚧 Files skipped from review as they are similar to previous changes (1)
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media? 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
taskfiles/utils-remote.yaml
Outdated
@@ -77,6 +77,8 @@ tasks: | |||
ref: "default (list) .INCLUDE_PATTERNS" | |||
|
|||
# Misc | |||
ARCHIVER: >- | |||
{{if eq OS "darwin"}}gtar{{else}}tar{{end}} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why do we want to use gtar
on macOS?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The tar
command doesn't support --directory
, --no-anchored
, or --wildcards
. However, it does provide the shorthand -C
option as an alternative to --directory
, but the other two options are not available in the default version of tar
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
References:
gtar
: https://linux.die.net/man/1/gtar
tar
: https://ss64.com/mac/tar.html
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you add that to the PR description?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ok
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
added
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For the PR title, how about:
fix(taskfiles): Make remote utilities macOS-compliant.
Co-authored-by: kirkrodrigues <[email protected]>
Description
mkdir
andrm
with their shorthand equivalents for cross-platform compatibility.tar
instead oftar
on macOS.tar
command doesn't support--directory
,--no-anchored
, or--wildcards
.-C
option as an alternative to--directory
.References:
gtar
: https://linux.die.net/man/1/gtartar
: https://ss64.com/mac/tar.htmlChecklist
breaking change.
Validation performed
ystdlib-cpp
.Summary by CodeRabbit
Summary by CodeRabbit
New Features
Chores