Follow

I just needed to once again convert snake_case to CamelCase in bash, and instead of coming up with a better way I searched my own timeline and stole my terrible regex I posted about a couple months ago: cybre.space/@cincodenada/10568

· · Web · 1 · 0 · 2

Also because I saw @relsqui's reply on that post and realized I was literally already using Perl, I also decided to see what an actual Perl solution would look like. This is...probably better?

```
perl -ne 'print map { ucfirst } split "-"' snake_case
```

Also, codeblocks on Masto when??

@cincodenada I wonder if glitch-soc has them…

perl -ne 'print map { ucfirst } split "-"' snake_case

Sign in to participate in the conversation
Cybrespace

cybrespace: the social hub of the information superhighway jack in to the mastodon fediverse today and surf the dataflow through our cybrepunk, slightly glitchy web portal support us on patreon or liberapay!