UnixCopyPathCommand
Base classes¶
| Name | Children | Inherits |
|---|---|---|
| CopyPathCommand anyenv.os_commands.base Base class for copy path commands. |
⋔ Inheritance diagram¶
graph TD
581921880["copy_path.UnixCopyPathCommand"]
2819545931["base.CopyPathCommand"]
925645236["abc.ABC"]
2751680898["builtins.object"]
2819545931 --> 581921880
925645236 --> 2819545931
2751680898 --> 925645236
🛈 DocStrings¶
Bases: CopyPathCommand
Unix/Linux copy path command implementation.
Source code in src/anyenv/os_commands/copy_path.py
create_command
¶
Generate Unix cp command.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
source
|
str
|
Source path to copy from |
required |
destination
|
str
|
Destination path to copy to |
required |
recursive
|
bool
|
Whether to copy directories recursively |
False
|
Returns:
| Type | Description |
|---|---|
str
|
The cp command string |
Source code in src/anyenv/os_commands/copy_path.py
parse_command
¶
Parse Unix cp result based on exit code.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
output
|
str
|
Raw command output (ignored) |
required |
exit_code
|
int
|
Command exit code |
0
|
Returns:
| Type | Description |
|---|---|
bool
|
True if copy was successful, False otherwise |