[arch-projects] [ABS] [PATCH v2 3/7] vcs prototypes: simplify code
Since the $PWD after the update/initial clone is always "$srcdir", we don't need to reference it later on. Signed-off-by: Linus Arver <linusarver@gmail.com> --- prototypes/PKGBUILD-bzr.proto | 6 +++--- prototypes/PKGBUILD-cvs.proto | 6 +++--- prototypes/PKGBUILD-darcs.proto | 6 +++--- prototypes/PKGBUILD-git.proto | 6 +++--- prototypes/PKGBUILD-hg.proto | 6 +++--- prototypes/PKGBUILD-svn.proto | 6 +++--- 6 files changed, 18 insertions(+), 18 deletions(-) diff --git a/prototypes/PKGBUILD-bzr.proto b/prototypes/PKGBUILD-bzr.proto index f47844b..6f36205 100644 --- a/prototypes/PKGBUILD-bzr.proto +++ b/prototypes/PKGBUILD-bzr.proto @@ -45,9 +45,9 @@ build() { msg "Bazaar checkout done or server timeout" msg "Starting build..." - rm -rf "$srcdir/$_bzrmod-build" - cp -r "$srcdir/$_bzrmod" "$srcdir/$_bzrmod-build" - cd "$srcdir/$_bzrmod-build" + rm -rf "$_bzrmod-build" + cp -r "$_bzrmod" "$_bzrmod-build" + cd "$_bzrmod-build" # # BUILD HERE diff --git a/prototypes/PKGBUILD-cvs.proto b/prototypes/PKGBUILD-cvs.proto index a5a9fd1..ea12d69 100644 --- a/prototypes/PKGBUILD-cvs.proto +++ b/prototypes/PKGBUILD-cvs.proto @@ -45,9 +45,9 @@ build() { msg "CVS checkout done or server timeout" msg "Starting build..." - rm -rf "$srcdir/$_cvsmod-build" - cp -r "$srcdir/$_cvsmod" "$srcdir/$_cvsmod-build" - cd "$srcdir/$_cvsmod-build" + rm -rf "$_cvsmod-build" + cp -r "$_cvsmod" "$_cvsmod-build" + cd "$_cvsmod-build" # # BUILD HERE diff --git a/prototypes/PKGBUILD-darcs.proto b/prototypes/PKGBUILD-darcs.proto index 008526d..7f0fd66 100644 --- a/prototypes/PKGBUILD-darcs.proto +++ b/prototypes/PKGBUILD-darcs.proto @@ -44,9 +44,9 @@ build() { darcs get --partial --set-scripts-executable "$_darcstrunk/$_darcsmod" fi - rm -rf "$srcdir/$_darcsmod-build" - cp -r "$srcdir/$_darcsmod" "$srcdir/$_darcsmod-build" - cd "$srcdir/$_darcsmod-build" + rm -rf "$_darcsmod-build" + cp -r "$_darcsmod" "$_darcsmod-build" + cd "$_darcsmod-build" msg "Starting build..." diff --git a/prototypes/PKGBUILD-git.proto b/prototypes/PKGBUILD-git.proto index 4e6a42e..08ed0f2 100644 --- a/prototypes/PKGBUILD-git.proto +++ b/prototypes/PKGBUILD-git.proto @@ -45,9 +45,9 @@ build() { msg "GIT checkout done or server timeout" msg "Starting build..." - rm -rf "$srcdir/$_gitname-build" - git clone "$srcdir/$_gitname" "$srcdir/$_gitname-build" - cd "$srcdir/$_gitname-build" + rm -rf "$_gitname-build" + git clone "$_gitname" "$_gitname-build" + cd "$_gitname-build" # # BUILD HERE diff --git a/prototypes/PKGBUILD-hg.proto b/prototypes/PKGBUILD-hg.proto index ada253b..77d499d 100644 --- a/prototypes/PKGBUILD-hg.proto +++ b/prototypes/PKGBUILD-hg.proto @@ -46,9 +46,9 @@ build() { msg "Mercurial checkout done or server timeout" msg "Starting build..." - rm -rf "$srcdir/$_hgrepo-build" - cp -r "$srcdir/$_hgrepo" "$srcdir/$_hgrepo-build" - cd "$srcdir/$_hgrepo-build" + rm -rf "$_hgrepo-build" + cp -r "$_hgrepo" "$_hgrepo-build" + cd "$_hgrepo-build" # # BUILD HERE diff --git a/prototypes/PKGBUILD-svn.proto b/prototypes/PKGBUILD-svn.proto index 33599c1..64b23c4 100644 --- a/prototypes/PKGBUILD-svn.proto +++ b/prototypes/PKGBUILD-svn.proto @@ -44,9 +44,9 @@ build() { msg "SVN checkout done or server timeout" msg "Starting build..." - rm -rf "$srcdir/$_svnmod-build" - cp -r "$srcdir/$_svnmod" "$srcdir/$_svnmod-build" - cd "$srcdir/$_svnmod-build" + rm -rf "$_svnmod-build" + cp -r "$_svnmod" "$_svnmod-build" + cd "$_svnmod-build" # # BUILD HERE -- 1.7.7.2
participants (1)
-
Linus Arver