From 2e5d8664920453ede30b450c7b39ac3a0bc141bb Mon Sep 17 00:00:00 2001 From: Richard Maw Date: Sun, 10 Aug 2014 20:29:42 +0100 Subject: Make morph show-branch-root print the path The help for the show-branch-root command said it returns a path, but the command and the yarns just showed the aliased url it was cloned from. Given I found myself needing the path in some scripts, not the repo url, I think it's more useful to reconcile the difference this way. --- .../show-branch-root-in-branched-branch.script | 30 ---------------------- .../show-branch-root-in-branched-branch.stdout | 1 - .../show-branch-root-in-checked-out-branch.script | 30 ---------------------- .../show-branch-root-in-checked-out-branch.stdout | 1 - .../show-branch-root-with-repo-url.script | 30 ---------------------- .../show-branch-root-with-repo-url.stdout | 1 - 6 files changed, 93 deletions(-) delete mode 100755 tests.branching/show-branch-root-in-branched-branch.script delete mode 100644 tests.branching/show-branch-root-in-branched-branch.stdout delete mode 100755 tests.branching/show-branch-root-in-checked-out-branch.script delete mode 100644 tests.branching/show-branch-root-in-checked-out-branch.stdout delete mode 100755 tests.branching/show-branch-root-with-repo-url.script delete mode 100644 tests.branching/show-branch-root-with-repo-url.stdout (limited to 'tests.branching') diff --git a/tests.branching/show-branch-root-in-branched-branch.script b/tests.branching/show-branch-root-in-branched-branch.script deleted file mode 100755 index 4598d6a9..00000000 --- a/tests.branching/show-branch-root-in-branched-branch.script +++ /dev/null @@ -1,30 +0,0 @@ -#!/bin/sh -# -# Copyright (C) 2012 Codethink Limited -# -# This program is free software; you can redistribute it and/or modify -# it under the terms of the GNU General Public License as published by -# the Free Software Foundation; version 2 of the License. -# -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License along -# with this program; if not, write to the Free Software Foundation, Inc., -# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. - - -## Check that 'morph show-branch-root' works when being run in a -## local system branch created using 'morph branch ...'. - -set -eu - -# Create a workspace and branch. -cd "$DATADIR/workspace" -"$SRCDIR/scripts/test-morph" init -"$SRCDIR/scripts/test-morph" branch test:morphs testbranch - -# Try to print the branch root repository. -"$SRCDIR/scripts/test-morph" show-branch-root diff --git a/tests.branching/show-branch-root-in-branched-branch.stdout b/tests.branching/show-branch-root-in-branched-branch.stdout deleted file mode 100644 index b2804d56..00000000 --- a/tests.branching/show-branch-root-in-branched-branch.stdout +++ /dev/null @@ -1 +0,0 @@ -test:morphs diff --git a/tests.branching/show-branch-root-in-checked-out-branch.script b/tests.branching/show-branch-root-in-checked-out-branch.script deleted file mode 100755 index 97f892b9..00000000 --- a/tests.branching/show-branch-root-in-checked-out-branch.script +++ /dev/null @@ -1,30 +0,0 @@ -#!/bin/sh -# -# Copyright (C) 2012 Codethink Limited -# -# This program is free software; you can redistribute it and/or modify -# it under the terms of the GNU General Public License as published by -# the Free Software Foundation; version 2 of the License. -# -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License along -# with this program; if not, write to the Free Software Foundation, Inc., -# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. - - -## Check that 'morph show-branch-root' works when being run in a -## local system branch created using 'morph checkout ...'. - -set -eu - -# Create a workspace and branch. -cd "$DATADIR/workspace" -"$SRCDIR/scripts/test-morph" init -"$SRCDIR/scripts/test-morph" checkout test:morphs master - -# Try to print the branch root repository. -"$SRCDIR/scripts/test-morph" show-branch-root diff --git a/tests.branching/show-branch-root-in-checked-out-branch.stdout b/tests.branching/show-branch-root-in-checked-out-branch.stdout deleted file mode 100644 index b2804d56..00000000 --- a/tests.branching/show-branch-root-in-checked-out-branch.stdout +++ /dev/null @@ -1 +0,0 @@ -test:morphs diff --git a/tests.branching/show-branch-root-with-repo-url.script b/tests.branching/show-branch-root-with-repo-url.script deleted file mode 100755 index 5480c3ef..00000000 --- a/tests.branching/show-branch-root-with-repo-url.script +++ /dev/null @@ -1,30 +0,0 @@ -#!/bin/sh -# -# Copyright (C) 2012 Codethink Limited -# -# This program is free software; you can redistribute it and/or modify -# it under the terms of the GNU General Public License as published by -# the Free Software Foundation; version 2 of the License. -# -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License along -# with this program; if not, write to the Free Software Foundation, Inc., -# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. - - -## Check that 'morph show-branch-root' works when being run in a -## local system branch created from a full repository URL. - -set -eu - -# Create a workspace and branch. -cd "$DATADIR/workspace" -"$SRCDIR/scripts/test-morph" init -"$SRCDIR/scripts/test-morph" branch "file://${DATADIR}/morphs.git" testbranch - -# Try to print the branch root repository. -"$SRCDIR/scripts/test-morph" show-branch-root diff --git a/tests.branching/show-branch-root-with-repo-url.stdout b/tests.branching/show-branch-root-with-repo-url.stdout deleted file mode 100644 index 2d47eb40..00000000 --- a/tests.branching/show-branch-root-with-repo-url.stdout +++ /dev/null @@ -1 +0,0 @@ -file://TMP/morphs.git -- cgit v1.2.1