How to list a specific directories in the SVN pre-commit Hook
Asked Answered
S

1

2

I want to list specific directories in the SVN pre-commit Hook

when I use svn list [repor_path] command I got this result :

svn list  http://SB-LAP163W/svn/TEST/RC | findstr  13.10
13.10.1/
13.10.2/
13.10.3/

that's what I'm looking but when I use the same command doesn't work in the pre-commit hook how can I deal with it using svnlook command?

I tried SVNLOOK dirs-changed -t TXN-NAME REPOS-PATH it will give me the changed path PC/13.10/main/dto/ and in my case, I want to list the folders under RC repo not PC

PS: RC and PC two directories has the same root

  • svn/ILS/RC/
  • svn/ILS/PC/
Servomechanical answered 28/1, 2019 at 6:44 Comment(0)
R
1

If your path you want to list does not correspond with the changed directory but is fixed then just try

svnlook tree svn/ILS/PC | grep -E '13\.10.*/'

You will get all folders fulfilling the regexp.

If there are some dependencies to changed files/folders or the commit message use a script as in SVN (server - pre-commit hook): Know the list of files that are being committed

Renunciation answered 28/1, 2019 at 10:13 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.