mirror of
https://github.com/rclone/rclone.git
synced 2026-01-06 10:33:34 +00:00
filter: export GlobToRegexp #5164
This commit is contained in:
@@ -10,10 +10,10 @@ import (
|
||||
"github.com/pkg/errors"
|
||||
)
|
||||
|
||||
// globToRegexp converts an rsync style glob to a regexp
|
||||
// GlobToRegexp converts an rsync style glob to a regexp
|
||||
//
|
||||
// documented in filtering.md
|
||||
func globToRegexp(glob string, ignoreCase bool) (*regexp.Regexp, error) {
|
||||
func GlobToRegexp(glob string, ignoreCase bool) (*regexp.Regexp, error) {
|
||||
var re bytes.Buffer
|
||||
if ignoreCase {
|
||||
_, _ = re.WriteString("(?i)")
|
||||
|
||||
Reference in New Issue
Block a user