utils
Class info¶
🛈 DocStrings¶
Common completion providers.
format_size
¶
Format file size in human readable format.
get_file_kind
¶
Get more specific file kind based on extension.
Source code in src/slashed/utils.py
get_first_line
¶
Get first line of text, stripped of whitespace.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
text
|
str | None
|
Input text or None |
required |
Returns:
| Type | Description |
|---|---|
str | None
|
First line without whitespace if text is provided, None otherwise |
Source code in src/slashed/utils.py
get_metadata
¶
Get metadata for path entry.