error MSB3073: The command "subwcrev.exe exited with code 6. Running MSBuild on Jenkins - jenkins

I am trying to do a build with MSBuild plugin in Jenkins. I have successfully installed and configured the MSBuild plugin. Completed config. The Build part is successfull, MsBuild installation is done correctly too. When trying to run the build command from GUI, however, this is seen:
SubWCRev : E155036: The working copy at 'C:\Program Files (x86)\Jenkins\workspace\FolderName'
18:05:15 is too old (format 8) to work with client version '1.9.7 (r1800392)' (expects format 31). You need to upgrade the working copy first.
18:05:15
18:05:15 C:\Windows\Microsoft.NET\Framework64\v4.0.30319\Microsoft.Common.targets(1063,5): error MSB3073: **The command "subwcrev.exe** "C:\Program Files (x86)\Jenkins\workspace\FolderName\." "C:\Program Files (x86)\Jenkins\workspace\IropsAnalyzer\Tools\SomeFoldername\Repository\SomeFolder.Repository\Properties\AssemblyInfo.template" "C:\Program Files (x86)\Jenkins\workspace\IropsAnalyzer\Tools\LegalitiesAnalyzer\Repository\LegalitiesAnalyzer.Repository\Properties\AssemblyInfo.cs"" **exited with code 6**. [C:\Program Files (x86)\Jenkins\workspace\FolderName\Tools\SomeFolderName\Repository\SomeFolderName.Repository\SomeFolderName.Repository.csproj]
In order to counter the need to upgrade the working copy issue I selected the version to 1.9 which is highest there is, still get the same issue. Also, looked up on exit code 6 but not much available. Any pointers?

Related

Jenkins MSBUILD : error MSB1008: Only one project can be specified.Switch: Files

I know there are many threads with same subject line ,but i am not getting any answer and hence putting my question here.
I am new to this and try to learn as fast as possible due to the time lines i have.
I did Jenkin setup (tried my best to do correctly in first shot)
But when ever i try to build i got following error
Started by user User 1
Building in workspace C:\Program Files (x86)\Jenkins\workspace********Service
[WS-CLEANUP] Deleting project workspace...
[WS-CLEANUP] Done
Querying for remote changeset at '$/Reference Data Master/Development/Source/*******DataSrvices' as of 'D2017-08-24T07:21:11Z'...
Query result is: Changeset #109084 by 'user' on '2017-08-23T13:04:44Z'.
Checking if there exists a mapping for E:\MyDrive\Jenkins\workspace...yes, in workspace 'Hudson-*****Service-MASTER'.
Downloading list of workspaces from http://********:8080/tfs...
Getting version 'C109084' to 'E:\MyDrive\Jenkins\workspace'...
Finished getting version 'C109084'. Retrieved 0 resources.
Path To MSBuild.exe: C:\Windows\Microsoft.NET\Framework\v4.0.30319\MSBuild.exe
Executing the command cmd.exe /C " chcp 1252 && C:\Windows\Microsoft.NET\Framework\v4.0.30319\MSBuild.exe %workspace%\DataService.Windows\DataSrvices.sln " && exit %%ERRORLEVEL%% from C:\Program Files (x86)\Jenkins\workspace\WindowsService
[WindowsService] $ cmd.exe /C " chcp 1252 && C:\Windows\Microsoft.NET\Framework\v4.0.30319\MSBuild.exe %workspace%\DataService.Windows\DataSrvices.sln " && exit %%ERRORLEVEL%%
Active code page: 1252
Microsoft (R) Build Engine version 4.0.30319.34209
[Microsoft .NET Framework, version 4.0.30319.34209]
Copyright (C) Microsoft Corporation. All rights reserved.
MSBUILD : error MSB1008: Only one project can be specified.
Switch: Files
For switch syntax, type "MSBuild /help"
Build step 'Build a Visual Studio project or solution using MSBuild' marked build as failure
Finished: FAILURE
Please find the setup i did for my first JOB in jenkins
Source COde managment : Done it for TFS
Build Trigger
Use the MSBuild plugin, and simply build your complete solution. The example in this screen shot even runs your code analysis if you like.

Can't install packages in Atom, in app or cmd

I'm trying to install linter for atom, however both in the app and in cmd I get:
INFO: Could not find files for the given pattern(s).
\Java\jre7\bin";C:\Program Files
(x86)\QuickTime\QTSystem\;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\WINDOWS\System32\WindowsPowerShell\v1.0\;C:\Program Files (x86)\ATI Technologies\ATI.ACE\Core-Static;C:\Program Files (x86)\AMD\ATI.ACE\Core-Static;C:\Program Files (x86)\Brackets\command;C:\Program Files\Microsoft SQL Server\120\Tools\Binn\;C:\Program Files (x86)\Windows Kits\10\Windows Performance Toolkit\;C:\Program Files (x86)\GtkSharp\2.12\bin;" was unexpected at this time.
And I honestly don't know what that means, but I've tried searching for an answer and I can't find it. "atom -v" returns the version (1.10.0), "apm -v" returns the above, as well as any apm command. "where apm" returns
C:\Users\JM\AppData\Local\atom\bin\apm
C:\Users\JM\AppData\Local\atom\bin\apm.cmd
https://github.com/atom/atom/issues/12608#issuecomment-245024152
https://github.com/atom/apm/commit/fa84f2693b22630e5125dcea10004300d00cdd75
I found the edits made in the repo and edited my apm.cmd file, solved the problem! For anyone wondering, line 12 was changed from if defined apm_git_path set "Path=!apm_git_path!;%PATH%" to if defined apm_git_path set "Path=!apm_git_path!;!PATH!"
This should be fixed on its own in future updates.
There is other solution:
got to folder with packages
git clone https://github.com/developer/some_pack.git
cd some_pack
npm install
apm link
it works fine

Spark installation failed on cygwin

I'm currently installing spark using cygwin terminal, I followed the steps indicated here, http://www.tutorialspoint.com/apache_spark/apache_spark_installation.htm, everything was fine until the last step..
I added the "export PATH=$PATH:/usr/local/spark/bin" line to ~/.bashrc file.
When I run the $spark-shell command, it gives me this error..
/usr/local/spark/bin/spark-class: line 86: C:\Program Files\Java\jdk1.7.0_75\bin/bin/java: No such file or directory
I tried searching for answers online but unfortunately nothing worked for me.
Please help. Thanks!
The problem is in:
/usr/local/spark/bin/spark-class: line 86: C:\Program Files\Java\jdk1.7.0_75\bin/bin/java: No such file or directory
You have two "bin" - one from Windows "\bin" and one from cygwin "/bin"
You can modify the JAVA_HOME environment variable - and set it to be C:\Program Files\Java\jdk1.7.0_75 (or the actual path of jdk)
I'd make a backup of /usr/local/spark/bin/spark-class and try to change the following line in /usr/local/spark/bin/spark-class
RUNNER="${JAVA_HOME}/bin/java
to be:
RUNNER="${JAVA_HOME}\java
And then run again the $spark-shell command

Specify dbus session address on windows

The default session.conf for DBus on Windows (https://code.google.com/p/dbus-windows-installer/downloads/list) uses <listen>autolaunch:scope=install-path</listen> which, as the name implies, uses the current path of the dbus-daemon executable to somehow determine the session address.
Is there a way to specify an explicit path instead? perhaps something with tcp:?
After many attempts, I have found the solution. Even though the 1.4.3 version of DBus for Windows that is (at least for now) available at https://code.google.com/p/dbus-windows-installer/downloads/list is quite old, it does in fact support tcp: syntax.
Installing DBus-Windows-Installer-1.4.1-2.exe does two things:
It delivers the DBus libraries and default configuration in C:\Program Files (x86)\DBus
It adds C:\Program Files (x86)\DBus\bin to the %PATH%
Having the latter is necessary so that your application can access DBus DLLs and EXEs at runtime. To make this installation use the tcp: syntax, you have to
Edit C:\Program Files (x86)\DBus\etc\session.conf to <listen>tcp:host=localhost,port=54321,family=ipv4</listen>
Edit C:\Program Files (x86)\DBus\bin\dbus-env.bat to set DBUS_SESSION_BUS_ADDRESS=tcp:host=localhost,port=54321,family=ipv4
Launch the session daemon from an environment that first executes dbus-env.bat and then run dbus-daemon.exe --session
(Optional) Launch the session monitor from an environment that first executes dbus-env.bat and then run dbus-monitor.exe --session
Launch your application from an environment that first executes dbus-env.bat and then actually runs your application
As I said above, DBus 1.4.3 is quite old. In fact, according to https://code.google.com/p/support/wiki/ReadOnlyTransition it might not even be available for download soon. At the time of this writing, the latest stable branch is 1.10. So, here are the instructions for building your own latest DBus
Install Visual Studio
Any version 2010 and later should suffice, including the free Express versions
Install CMake
I believe any recent version will do, but I used https://cmake.org/files/v3.4/cmake-3.4.1-win32-x86.exe
My recommendation is to NOT add cmake to path, just to keep your system clean
Get libexpat
I believe any recent version will do, but I used http://olex.openlogic.com/package_versions/6311/download?package_version_id=1765&path=https%3A%2F%2Folex-secure.openlogic.com%2Fcontent%2Fopenlogic%2Fexpat%2F2.0.1%2Fopenlogic-expat-2.0.1-windows-bin-1.zip
run the executable from the zipfile, which installs libexpat into C:\Program Files (x86)\Expat 2.0.1 directory.
Let's call this ${expatDir}
Get the DBus source
git clone git://anongit.freedesktop.org/git/dbus/dbus
cd dbus
Let's call this ${dbusSrcDir}
git checkout dbus-1.10
this is the current stable branch
Start Developer Command Prompt for VS2015
cd ${dbusSrcDir}
cd ..
mkdir dbus-build
cd dbus-build
"c:\Program Files (x86)\CMake\bin\cmake.exe" -G "NMake Makefiles" -DCMAKE_INCLUDE_PATH:PATH="${expatDir}\Source\lib" -DCMAKE_LIBRARY_PATH:PATH="${expatDir}\Bin" -DDBUS_BUILD_TESTS:BOOL=OFF -DDBUS_DISABLE_ASSERT:BOOL=ON -DDBUS_USE_OUTPUT_DEBUG_STRING:BOOL=ON -DDBUS_ENABLE_DOXYGEN_DOCS:BOOL=OFF ..\dbus\cmake
nmake
At this point, you can either do nmake install to install to C:\Program Files (x86)\DBus or you can make a distributable "deploy package" by
mkdir c:\temp\dbus-deploy
mkdir c:\temp\dbus-deploy\bin
mkdir c:\temp\dbus-deploy\share
mkdir c:\temp\dbus-deploy\share\dbus-1
copy bin\dbus-1-3.dll c:\temp\dbus-deploy\bin
copy bin\dbus-daemon.exe c:\temp\dbus-deploy\bin
copy bin\dbus-env.bat c:\temp\dbus-deploy\bin
copy bin\dbus-launch.exe c:\temp\dbus-deploy\bin
copy bin\dbus-monitor.exe c:\temp\dbus-deploy\bin
copy bin\dbus-send.exe c:\temp\dbus-deploy\bin
copy ${expatDir}\Bin\libexpat.dll c:\temp\dbus-deploy\bin
Create a c:\temp\dbus-deploy\share\dbus-1\session.conf with the usual contents which includes <listen>tcp:host=localhost,port=54321,family=ipv4</listen>
Edit c:\temp\dbus-deploy\bin\dbus-env.bat to set DBUS_SESSION_BUS_ADDRESS=tcp:host=localhost,port=54321,family=ipv4
To use "the deploy package" in your application, modify %PATH% to point to your "deploy package" bin directory and make sure to source dbus-env.bat before doing anything.

Making a command executable from a windows command prompt

I'm being forced to work with a Windows 2003 server machine, and I need to be able to run a BitNami SVN commit hook that'll update a working directory on the same machine. Because of different users, the script I wrote and tested as working as Admin, doesn't work post-commit. So I'm trying to make SVN an executable command from any CMD prompt.
Right now, the only way I can do it is by running the batch file that does the following (This is the default BitNami installation batch file):
CALL C:\PROGRA~1\BITNAM~1\scripts\setenv.bat" if not exist
"%USERPROFILE%\BitNami Subversion Stack projects" mkdir
"%USERPROFILE%\BitNami Subversion Stack projects" cd
"%USERPROFILE%\BitNami Subversion Stack projects
START "BitNami Subversion Stack Environment" cmd
The \scripts\setenv.bat file contains this:
set PATH=C:\Program Files\BitNami Subversion
Stack/subversion\bin;C:\Program Files\BitNami Subversion
Stack/sqlite;%PATH%
rem ##### SUBVERSION ENV #####
rem ##### SQLITE ENV #####
rem ##### APACHE ENV #####
So I edited My Computer --> Properties --> Advanced --> Environment Variables
by added these two entries:
C:\Program Files\BitNami Subversion Stack/subversion\bin
C:\Program Files\BitNami Subversion Stack/sqlite
But I still cannot execute a SVN command from a normal command prompt. So I have two questions, 1 -- how can I make SVN work in this situation from a normal command prompt and 2, can anyone explain the difference between what I've done and what the batch file does? To my mind at the moment they are the same...although obviously not, since only one works...
Thanks for any help you can provide!
As Greg Hewgill pointed out, I had failed to update my PATH environment variable. Doing this solved my issue -- thanks Greg!

Resources