Strings

CommandDescription
charOutput special characters (e.g., 'newline').
decodeDecode bytes into a string.
detect columnsAttempt to automatically split text into multiple columns.
encodeEncode a string into bytes.
formatVarious commands for formatting data.
format durationOutputs duration with a specified unit of time.
format filesizeConverts a column of filesizes to some specified format.
format patternFormat columns into a string using a simple pattern.
nu-checkValidate and parse input content.
nu-highlightSyntax highlight the input string.
parseParse columns from string data using a simple pattern.
printPrint the given values to stdout.
splitSplit contents across desired subcommand (like row, column) via the separator.
split charsSplit a string into a list of characters.
split columnSplit a string into multiple columns using a separator.
split rowSplit a string into multiple rows using a separator.
split wordsSplit a string's words into separate rows.
strVarious commands for working with string data.
str camel-caseConvert a string to camelCase.
str capitalizeCapitalize first letter of text.
str containsChecks if string input contains a substring.
str distanceCompare two strings and return the edit distance/Levenshtein distance.
str downcaseMake text lowercase.
str ends-withCheck if an input ends with a string.
str expandGenerates all possible combinations defined in brace expansion syntax.
str index-ofReturns start index of first occurrence of string in input, or -1 if no match.
str joinConcatenate multiple strings into a single string, with an optional separator between each.
str kebab-caseConvert a string to kebab-case.
str lengthOutput the length of any strings in the pipeline.
str pascal-caseConvert a string to PascalCase.
str replaceFind and replace text.
str reverseReverse every string in the pipeline.
str screaming-snake-caseConvert a string to SCREAMING_SNAKE_CASE.
str snake-caseConvert a string to snake_case.
str starts-withCheck if an input starts with a string.
str statsGather word count statistics on the text.
str substringGet part of a string. Note that the start is included but the end is excluded, and that the first character of a string is index 0.
str title-caseConvert a string to Title Case.
str trimTrim whitespace or specific character.
str upcaseMake text uppercase.
url decodeConverts a percent-encoded web safe string to a string.
url encodeConverts a string to a percent encoded web safe string.