artifacts publishing expression assistance

At the end of our build process, we have a series of directories generated as follows:
src/module1/.tmp-build/classes
src/module2/.tmp-build/classes
src/module3/.tmp-build/classes
...

I'd like to copy all their contents to an artifacts directory called "classes" . Is there a way to accomplish this using a wildcard expression? I have tried several with no success, such as:

**/.tmp-build/classes=>classes
src/*/.tmp-build/classes=>classes

Appreciate any tips, thanks.

3 comments

Hello,

You may use something like \*/.tmp-build/classes/\ =>classes , but in this case the directory structure in target "classes" directory will include all the intermediate paths:

classes/src/module1/.tmp-build/classes/..
classes/src/module2/.tmp-build/classes/..

For pattern src/*/.tmp-build/classes/ =>classes you'll have

classes/module1/.tmp-build/classes/..
classes/module2/.tmp-build/classes/..

I don't think this is what you need.
Actually, by the moment there is no way to put all files to a single folder and remove intermediate directory structure :(

Kind regards,
KIR

Edited by: Kirill Maximov (JetBrains) on Mar 21, 2008 6:18 PM

0

Your second suggestion would be OK, but I still can't get it to work. Here's the message in the build log:

Publishing artifacts 'src/*/.tmp-build/classes/' to root artifacts directory
Artifacts path src/*/.tmp-build/classes/ not found

Here's some directory listings on the build agent:
$ pwd
/home/buildagent/buildagent/work/1f56909ed485940b/src/module1

$ ls -laF
drwxrwxr-x 5 buildagent buildagent 4096 Mar 21 12:05 .tmp-build/
-rwxrwxrwx 1 buildagent buildagent 90373 Mar 19 10:13 buildNotes.txt

$ ls -l .tmp-build
drwxrwxr-x 3 buildagent buildagent 4096 Mar 21 12:05 classes
drwxrwxr-x 2 buildagent buildagent 4096 Mar 21 12:04 javalib
drwxrwxr-x 3 buildagent buildagent 4096 Mar 21 12:04 src
**note, I renamed a couple of strings in the above to clear out our app-specific info

Could the directory name starting with a leading period be a problem, or am I missing something else with the expression?

0

It should work. At least it works in the tests.

Please check that:
1. classes subdirectory really contains files
2. checkout directory for your project points to /home/buildagent/buildagent/work/1f56909ed485940b (or default value is used)

If everything is OK, I'd ask you to enable debug on the agent and file a issue to tracker with your build log and teamcity-agent.log. You may send logs directly to me via kir at jetbrains. com, if you feel unsafe to place them to tracker.

Kind regards,
KIR

Edited by: Kirill Maximov (JetBrains) on Mar 24, 2008 1:36 PM

0

Please sign in to leave a comment.