This is the documentation for Bamboo 5.8. View this page for the

Unknown macro: {spacejump}

of Bamboo, or visit the latest Bamboo documentation.

Phing is the PHP project build system or build tool based on Apache Ant. This page describes how to configure a Bamboo task to use Phing. See Configuring a builder task for an overview of Bamboo builder tasks.

To configure a Phing task:

  1. ジョブのタスク設定タブに移動します(新しいプランを作成するとデフォルト ジョブとなります)。
  2. Click the name of an existing Phing task, or click Add Task and then Phing to create a new task.
  3. Complete the following settings:
     

    タスクの説明A description of the task, which is displayed in Bamboo.
    このタスクを無効化オンまたはオフにすることで、選択的にこのタスクを実行します。
    実行可能ファイル

    The Phing executable that is available to perform the task. The executable that you
    select will become one of the task's (and so, the job's) requirements.

    TargetsThe Phing targets that you want this Bamboo task to execute (e.g. clean build test).
    ビルド ファイルThe name of your existing build file (by default build.xml).
    オプション

    You can include any additional Phing command lines switches that you wish to use here.

    Working Sub Directory(オプション)  Bamboo が実行ファイルを実行する、ジョブのルート ディレクトリに相対的な代替サブディレクトリ。ルート ディレクトリには、ジョブの構成済みソース リポジトリから確認されたものがすべて含まれます。このフィールドを空白のまま残した場合、Bamboo はルート ディレクトリでビルド ファイルを検索します。このオプションは、サブディレクトリ内にビルド スクリプトがあり、実行可能ファイルをそのサブディレクトリ内から実行する必要がある場合に便利です。
    Look for test result files?

    Check this box to tell Bamboo to look for test results. Test results must be in JUnit XML format,
    and the build will fail if none are found.

    Example of Phing PHPUnit target using JUnit XML formatter
    <target name="test">
      <phpunit haltonerror="true" haltonfailure="false">
        <formatter type="xml" todir="report/test-reports" outfile="phpunit.xml"/>
          <batchtest>
            <fileset dir="src">
              <include name="*.php"/>
            </fileset>
          </batchtest>
      </phpunit>
      <phpunitreport infile="report/test-reports/phpunit.xml" 
        format="noframes" todir="report"/>
    </target>
    Specify custom results directorySpecify the directory, relative to the root directory, where test results will be created. You can use patterns such as **/test-reports/*.xml. Bamboo requires test results to be in JUnit XML format.
    (warning) For jobs that use CVS, the root directory is <bamboo-home>/xml-data/build-dir/JOB_KEY/<cvs-module>.
  4. 保存をクリックします。

 

  • ラベルなし