1.分享违规
在遵循
http://programmaticponderings.wordpress.com/2012/08/08/convert- vs-2010-database-project-to-ssdt-and-automate-publishing-with-jenkins- part-33 /之后
echo 'Copying Adventure Works Solution to Jenkins workspace...'
xcopy /s /E /H /Y /R "C:\Users\LAB-User2\Documents\Visual Studio 2012\Projects\Database3" "C:\Program Files (x86)\Jenkins\jobs\testing003\workspace"
echo 'Deleting artifacts from previous builds...'
del "%WORKSPACE%\*_publish.zip" /F /Q
2.使用MS build构建ms项目
在添加C:\ Windows \ Microsoft.NET \ Framework \ v4.0.30319 \环境变量
路径并在Jenkins中设置生成C:\ Windows \ Microsoft.NET \ Framework \ v4.0.30319 \ MSbuild.exe
'C:\Users\LAB-User2\Documents\Visual Studio 2012\Projects\Database3\Database3.sqlproj' /p:Configuration=Database3 /p:Platform=AnyCPU /t:Build;Publish /p:SqlPublishProfilePath='C:\Users\LAB-User2\Documents\Visual Studio 2012\Projects\Database3\Database3.publish.xml' /p:UpdateDatabase=False
Executing the command cmd.exe /C msbuild.exe "C:\Users\LAB-User2\Documents\Visual Studio 2012\Projects\Database3\Database3.sqlproj" /p:Configuration=Database3 /p:Platform=AnyCPU /t:Build;Publish "/p:SqlPublishProfilePath=C:\Users\LAB-User2\Documents\Visual Studio 2012\Projects\Database3\Database3.publish.xml" /p:UpdateDatabase=False C:\Windows\Microsoft.NET\Framework\v4.0.30319\MSbuild.exe && exit %%ERRORLEVEL%% from C:\Program Files (x86)\Jenkins\jobs\testing003\workspace
[workspace] $ cmd.exe /C msbuild.exe "C:\Users\LAB-User2\Documents\Visual Studio 2012\Projects\Database3\Database3.sqlproj" /p:Configuration=Database3 /p:Platform=AnyCPU /t:Build;Publish "/p:SqlPublishProfilePath=C:\Users\LAB-User2\Documents\Visual Studio 2012\Projects\Database3\Database3.publish.xml" /p:UpdateDatabase=False C:\Windows\Microsoft.NET\Framework\v4.0.30319\MSbuild.exe && exit %%ERRORLEVEL%%
'msbuild.exe' is not recognized as an internal or external command,
C:\Users\User2>cmd.exe /C msbuild.exe "C:\Users\LAB-User2\Documents\Visual S
tudio 2012\Projects\Database3\Database3.sqlproj" /p:Configuration=Database3 /p:P
latform=AnyCPU /t:Build;Publish "/p:SqlPublishProfilePath=C:\Users\LAB-User2\Doc
uments\Visual Studio 2012\Projects\Database3\Database3.publish.xml" /p:UpdateDat
abase=False C:\Windows\Microsoft.NET\Framework\v4.0.30319\MSbuild.exe && exit %%
ERRORLEVEL%% from C:\Program Files (x86)\Jenkins\jobs\testing003\workspace
Microsoft (R) Build Engine version 4.0.30319.17929
[Microsoft .NET Framework, version 4.0.30319.18034]
Copyright (C) Microsoft Corporation. All rights reserved.
MSBUILD : error MSB1008: Only one project can be specified.
Switch: C:\Windows\Microsoft.NET\Framework\v4.0.30319\MSbuild.exe
For switch syntax, type "MSBuild /help"
update Full Console output
Started by user anonymous
Building in workspace C:\Program Files (x86)\Jenkins\jobs\testing003\workspace
[workspace] $ cmd /c call C:\Windows\TEMP\hudson1045566609826009314.bat
C:\Program Files (x86)\Jenkins\jobs\testing003\workspace>echo 'Copying Adventure Works Solution to Jenkins workspace...'
'Copying Adventure Works Solution to Jenkins workspace...'
C:\Program Files (x86)\Jenkins\jobs\testing003\workspace>xcopy /s /E /H /Y /R "C:\Users\LAB-User2\Documents\Visual Studio 2012\Projects\Database3" "C:\Program Files (x86)\Jenkins\jobs\testing003\workspace"
C:\Users\LAB-User2\Documents\Visual Studio 2012\Projects\Database3\Database3.sln
C:\Users\LAB-User2\Documents\Visual Studio 2012\Projects\Database3\Database3.v11.suo
C:\Users\LAB-User2\Documents\Visual Studio 2012\Projects\Database3\excludefiles.txt
C:\Users\LAB-User2\Documents\Visual Studio 2012\Projects\Database3\Database3\Database3.dbmdl
Sharing violation
C:\Program Files (x86)\Jenkins\jobs\testing003\workspace>echo 'Deleting artifacts from previous builds...'
'Deleting artifacts from previous builds...'
C:\Program Files (x86)\Jenkins\jobs\testing003\workspace>del "C:\Program Files (x86)\Jenkins\jobs\testing003\workspace\*_publish.zip" /F /Q
Could Not Find C:\Program Files (x86)\Jenkins\jobs\testing003\workspace\*_publish.zip
C:\Program Files (x86)\Jenkins\jobs\testing003\workspace>exit 0
Path To MSBuild.exe: msbuild.exe
Executing the command cmd.exe /C msbuild.exe "C:\Users\LAB-User2\Documents\Visual Studio 2012\Projects\Database3\Database3.sqlproj" /p:Configuration=Database3 /p:Platform=AnyCPU /t:Build;Publish "/p:SqlPublishProfilePath=C:\Users\LAB-User2\Documents\Visual Studio 2012\Projects\Database3\Database3.publish.xml" /p:UpdateDatabase=False C:\Windows\Microsoft.NET\Framework\v3.5\msbuild.exe && exit %%ERRORLEVEL%% from C:\Program Files (x86)\Jenkins\jobs\testing003\workspace
[workspace] $ cmd.exe /C msbuild.exe "C:\Users\LAB-User2\Documents\Visual Studio 2012\Projects\Database3\Database3.sqlproj" /p:Configuration=Database3 /p:Platform=AnyCPU /t:Build;Publish "/p:SqlPublishProfilePath=C:\Users\LAB-User2\Documents\Visual Studio 2012\Projects\Database3\Database3.publish.xml" /p:UpdateDatabase=False C:\Windows\Microsoft.NET\Framework\v3.5\msbuild.exe && exit %%ERRORLEVEL%%
'msbuild.exe' is not recognized as an internal or external command,
operable program or batch file.
Build step 'Build a Visual Studio project or solution using MSBuild' marked build as failure
Finished: FAILURE
如果要使用Jenkins构建.NET项目,请按照下列步骤操作:
Install MsBuild Plugin
Go to Jenkins -> Manage Jenkins -> Configure System
(On newer versions: Jenkins -> Manage Jenkins -> Global Tool Configuration -> MSBuild
)
In the MSBuild section click the AddMsBuild button and specify the details:
C:\Windows\Microsoft.NET\Framework\v3.5\msbuild.exe
Select your job.
Select Add Build Step.
Select MsBuild version.
Specify the path to the project file (.csproj or .sln)
Build your project.
我在运行Windows 7的同一台机器上安装了Jenkins和Docker ToolBox。在运行Jenkins构建时,除了docker之外,所有命令都可以正常工作。当我尝试使用Jenkins在构建步骤中运行docker命令时,它给我错误。 E: \Jenkins\workspace\docker应用程序 但同样的命令适用于windows命令提示符。任何帮助都将不胜感激。
问题内容: 我一直在尝试让Jenkinsfile工作时遇到很多麻烦。我一直在尝试运行以下测试脚本: 但是在尝试构建时,我总是收到此错误: 我将所有管道插件更新为最新版本,但仍然遇到此错误。有什么帮助吗? 问题答案: 看来原因是全球财产造成了这个问题。通过转到-> 并删除全局属性,解决了我的问题。参见JENKINS-41339。
问题内容: 好的,我正在Windows(7)上运行节点。使用npm,我刚刚将模块安装到d:\目录。因此,我的文件结构如下所示: 但是,当我在此“ myproject”目录中时,例如,我似乎无法运行“ express”: 我做错什么了吗? 问题答案: 我的猜测是您没有全局安装Express。您可以使用以下命令(请参阅http://expressjs.com/guide.html)在全球范围内安装Ex
我正在使用windows并在Ruby on Rails中使用命令提示符。使用随EnterpriseDB安装程序一起安装的PostgreSQL 9.2。
这是我写的,只是为了启动我的discord机器人,但是每当我尝试使用这个命令时?嗨,我收到了错误信息 忽略命令无异常:discord.ext.commands.errors.命令没有找到:命令"hi"没有找到" 我试过几次,但我是新手,没有任何效果。 下面的答案有助于解决这个问题,这是我的新代码,因为机器人现在不会给出错误消息,但不会响应命令
问题内容: 我正在尝试为Angular CLI项目设置Jenkins。我已经在特定用户帐户下的Jenkins服务器上安装了node 和Angular Cli。如果我在服务器上打开命令提示符,请执行以下命令以验证它们是否正确安装,这是结果: 我已经用Jenkins配置了项目,并且创建了两个构建步骤,两个 执行两个bat文件。 一种运行:npm install 第二个运行:ng build –prod