summaryrefslogtreecommitdiff
path: root/docs/scripts/indent-smb.conf.pl
diff options
context:
space:
mode:
Diffstat (limited to 'docs/scripts/indent-smb.conf.pl')
-rwxr-xr-xdocs/scripts/indent-smb.conf.pl8
1 files changed, 8 insertions, 0 deletions
diff --git a/docs/scripts/indent-smb.conf.pl b/docs/scripts/indent-smb.conf.pl
new file mode 100755
index 0000000000..c4c87a1511
--- /dev/null
+++ b/docs/scripts/indent-smb.conf.pl
@@ -0,0 +1,8 @@
+#!/usr/bin/perl
+
+while(<STDIN>) {
+ if(/^$/) { }
+ elsif(/^([ \t]*)#(.*)/) { print "#$2\n"; }
+ elsif(/^([ \t]*)(.*) = (.*)$/) { print "\t$2 = $3\n"; }
+ elsif(/^([ \t]*)\[(.*)\]([ \t]*)$/) { print "\n[$2]\n"; }
+}