summaryrefslogtreecommitdiff
path: root/nslcd_server
diff options
context:
space:
mode:
authorLuke Shumaker <lukeshu@lukeshu.com>2017-12-18 14:21:44 -0500
committerLuke Shumaker <lukeshu@lukeshu.com>2017-12-18 15:09:27 -0500
commit70bd3033eccda373294128e1b8a9e4919a3626ad (patch)
tree85e771087134a8bc8b8923934e2a37187cc6370b /nslcd_server
parent643cd143070d779d4697ef7eeecd3dbf5f5e24ff (diff)
type_nilbackend.go.gen: use variables to shorten crazy-long line
Diffstat (limited to 'nslcd_server')
-rwxr-xr-xnslcd_server/type_nilbackend.go.gen8
1 files changed, 6 insertions, 2 deletions
diff --git a/nslcd_server/type_nilbackend.go.gen b/nslcd_server/type_nilbackend.go.gen
index 61077a0..0c6f4b5 100755
--- a/nslcd_server/type_nilbackend.go.gen
+++ b/nslcd_server/type_nilbackend.go.gen
@@ -1,5 +1,5 @@
#!/usr/bin/env bash
-# Copyright (C) 2015 Luke Shumaker <lukeshu@sbcglobal.net>
+# Copyright (C) 2015, 2017 Luke Shumaker <lukeshu@sbcglobal.net>
#
# This library is free software; you can redistribute it and/or
# modify it under the terms of the GNU Lesser General Public
@@ -34,7 +34,11 @@ import (
// databases.
type NilBackend struct{}
-$(< "$interface" sed -rn 's/^\t([^(]+)\(unix.Ucred, ([^)]+)\) <-chan (\S+)$/func (o NilBackend) \1(unix.Ucred, \2) <-chan \3 { r := make(chan \3); close(r); return r }/p')
+$(
+ re_in='^\t([^(]+)\(unix\.Ucred, ([^)]+)\) <-chan (\S+)$'
+ re_out='func (o NilBackend) \1(unix.Ucred, \2) <-chan \3 { r := make(chan \3); close(r); return r }'
+ < "$interface" sed -rn "s/$re_in/$re_out/p"
+)
var _ Backend = NilBackend{}
EOF