Regular Expressions 101

Sponsors

Library entries

1
java

Rick Roll

Matches chorus of Never Going to Give You Up
Submitted by Stephen Battista - 4 months ago

Parse Kubernetes Resource URI Paths

Vote

1

Regular Expression
golang

`
^(?:/api|/apis/(?P<GROUP>[^/]+))/(?P<VERSION>[^/]+)(?:/namespaces/(?P<NAMESPACE>[^/]+))?/(?P<RESOURCETYPE>[^/\n]+)(?:/(?P<NAME>[^/\n]+))?(?:/(?P<SUBRESOURCE>[^/\n]+))?$
`
gm

Description

Loading markdown...
Submitted by Mathew Wicks - 7 months ago