aboutsummaryrefslogtreecommitdiff
path: root/release/svnbranch.awk
diff options
context:
space:
mode:
Diffstat (limited to 'release/svnbranch.awk')
-rw-r--r--release/svnbranch.awk28
1 files changed, 28 insertions, 0 deletions
diff --git a/release/svnbranch.awk b/release/svnbranch.awk
new file mode 100644
index 000000000000..0fc86200c043
--- /dev/null
+++ b/release/svnbranch.awk
@@ -0,0 +1,28 @@
+# $FreeBSD$
+
+BEGIN {
+ FS = "_"
+}
+
+/RELENG_.*_RELEASE/ {
+ if (NF == 5) {
+ printf "release/%s.%s.%s", $2, $3, $4
+ exit
+ }
+}
+
+/RELENG_.*/ {
+ if (NF == 3) {
+ printf "releng/%s.%s", $2, $3
+ exit
+ }
+
+ if (NF == 2) {
+ printf "stable/%s", $2
+ exit
+ }
+}
+
+// {
+ printf "unknown_branch"
+}