Nushell
Get Nu!
Getting Started
  • The Nushell Book
  • Command Reference
  • Cookbook
  • Language Reference Guide
  • Contributing Guide
Blog
  • English
  • 中文
  • Deutsch
  • Français
  • Español
  • 日本語
  • Português do Brasil
  • Русский язык
GitHub
Get Nu!
Getting Started
  • The Nushell Book
  • Command Reference
  • Cookbook
  • Language Reference Guide
  • Contributing Guide
Blog
  • English
  • 中文
  • Deutsch
  • Français
  • Español
  • 日本語
  • Português do Brasil
  • Русский язык
GitHub
  • Categories

    • Bits
    • Bytes
    • Chart
    • Conversions
    • Core
    • Database
    • Dataframe
    • Dataframe Or Lazyframe
    • Date
    • Debug
    • Default
    • Env
    • Experimental
    • Expression
    • Filesystem
    • Filters
    • Formats
    • Generators
    • Hash
    • History
    • Lazyframe
    • Math
    • Misc
    • Network
    • Path
    • Platform
    • Plugin
    • Prompt
    • Random
    • Removed
    • Shells
    • Strings
    • System
    • Viewers

str pascal-case for strings

Convert a string to PascalCase.

Signature

> str pascal-case {flags} ...rest

Parameters

  • ...rest: For a data structure input, convert strings at the given cell paths.

Input/output types:

inputoutput
list<string>list<string>
recordrecord
stringstring
tabletable

Examples

convert a string to PascalCase

> 'nu-shell' | str pascal-case
NuShell

convert a string to PascalCase

> 'this-is-the-first-case' | str pascal-case
ThisIsTheFirstCase

convert a string to PascalCase

> 'this_is_the_second_case' | str pascal-case
ThisIsTheSecondCase

convert a column from a table to PascalCase

> [[lang, gems]; [nu_test, 100]] | str pascal-case lang
╭───┬────────┬──────╮
│ # │  lang  │ gems │
├───┼────────┼──────┤
│ 0 │ NuTest │  100 │
╰───┴────────┴──────╯