我在哪里将atlassian-plugin-sdk'allowGoogleTracking'选项设置为false?

dle*_*rob 5 atlassian-plugin-sdk

我已经安装/设置了atlassian-plugin-sdk,所以我可以查看JIRA插件开发.

但是,当我运行"atlas-run-standalone --product jira"命令并启动JIRA实例时,它会尝试连接到Google Analytics并拒绝连接(它被我们的代理阻止).

它说我可以关闭此跟踪选项:

you may disable tracking by adding <allowGoogleTracking>false</allowGoogleTracking> to the amps plugin configuration in your pom.xml
Run Code Online (Sandbox Code Playgroud)

我的问题是,我在哪里可以找到这个"allowGoogleTracking"选项?其中pom.xml似乎无法在"atlassian-plugin-sdk"目录中找到一个.

我试过谷歌搜索和环顾四周,但我似乎无法找到他们确切地告诉我我应该编辑哪个pom.xml文件的任何地方.

Joe*_*Joe 8

从文档:

默认情况下,AMPS会将基本使用事件发送给Google Analytics.要禁用跟踪,请:

  1. 添加<allow.google.tracking>false</allow.google.tracking>到文件的<properties>部分.m2/settings.xml
  2. 包含<allowGoogleTracking>false</allowGoogleTracking>在你的放大器插件配置中pom.xml
  3. 或传递-Dallow.google.tracking=false命令行.

最简单的方法是~/.m2/settings.xml在默认配置文件中将其设置在文件中.您可能还希望同时设置skipAllPrompts:

<settings>
  ...
  <profiles>
    <profile>
      <id>defaultProfile</id>
      <activation>
        <activeByDefault>true</activeByDefault>
      </activation>
      ...
      <properties>
        <allow.google.tracking>false</allow.google.tracking>
        <skipAllPrompts>true</skipAllPrompts>
     </properties>
    </profile>
   </profiles>
</settings>
Run Code Online (Sandbox Code Playgroud)

  • 谢谢,我编辑了atlassian-plugin-sdk\apache-maven-3.2.1\conf目录下的settings.xml,它对我有用. (3认同)
  • 您还可以设置 ATLAS_OPTS 环境变量( -Dallow.google.tracking=false ) (2认同)