I’m doing a bit of mucking around with Atlassian JIRA on a local system, using a 30-day trial license. One thing I noticed on Windows systems is that the general assumption that you’re running as an Administrator all of the time is still being followed. It’s kind of a pain.
For instance, when you go about installing the Atlassian Plugin SDK, it will set all of the necessary environment variables on the installing user’s account only, but the installer requires you to elevate privileges via the User Account Control before it runs. It even attempts to install the files in the Administrator user’s home folder, meaning no one else would even be able to get close to these files.
I created a neutral folder under
C:\Atlassian and installed there instead.
Here are the environment variables it sets on the Administrator account only, which you need to add to your usual Limited User Account, so that the rest of their command-line examples will work properly:
ATLAS_HOME C:\Atlassian\atlassian-plugin-sdk JAVA_HOME C:/Program Files/Java/jdk1.7.0_51 M2_REPO C:\Users\Admin\.m2\repository Path (spelled oddly, it should be PATH, but cmd.exe doesn't seem to mind) %JAVA_HOME%\bin;C:\Atlassian\atlassian-plugin-sdk\bin
M2_REPO environment variable is pretty important because it defines where all your Maven dependencies will be cached.
Once the environment variables are set via the Control Panel, running
atlas-version should work fine:
C:\Users\Limited>atlas-version ATLAS Version: 4.2.20 ATLAS Home: C:\Atlassian\atlassian-plugin-sdk ATLAS Scripts: C:\Atlassian\atlassian-plugin-sdk\bin ATLAS Maven Home: C:\Atlassian\atlassian-plugin-sdk\apache-maven -------- Executing: "C:\Atlassian\atlassian-plugin-sdk\apache-maven\bin\mvn.bat" --version -gs C:\Atlassian\atlassian-plugin-sdk\apache-maven/conf/settings.xml Apache Maven 2.1.0 (r755702; 2009-03-18 20:10:27+0100) Java version: 1.7.0_51 Java home: C:\Program Files\Java\jdk1.7.0_51\jre Default locale: en_US, platform encoding: Cp1252 OS name: "windows 7" version: "6.1" arch: "amd64" Family: "windows"
Sadly, it’s not a typo, a four year-old version of Maven is really being used here.