build: 格式化shell文件

This commit is contained in:
Argo Zhang 2019-09-29 11:01:25 +08:00
parent 260b9b0481
commit a5f3b75dfe
No known key found for this signature in database
GPG Key ID: 152E398953DDF19F
11 changed files with 35 additions and 22 deletions

View File

@ -6,6 +6,10 @@ root=true
# All files # All files
[*] [*]
indent_style = space indent_style = space
# shell files
[*.{cmd,sh,bat}]
insert_final_newline = true
trim_trailing_whitespace = true
# Code files # Code files
[*.{cs,csx,vb,vbx}] [*.{cs,csx,vb,vbx}]
indent_size = 4 indent_size = 4

View File

@ -96,6 +96,8 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "win", "win", "{C6F2DCA0-794
EndProject EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "linux", "linux", "{FDCFC3E3-14CF-40B2-9FE5-5BC239AAC110}" Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "linux", "linux", "{FDCFC3E3-14CF-40B2-9FE5-5BC239AAC110}"
ProjectSection(SolutionItems) = preProject ProjectSection(SolutionItems) = preProject
deploy-admin.sh = deploy-admin.sh
deploy-client.sh = deploy-client.sh
publish-admin.sh = publish-admin.sh publish-admin.sh = publish-admin.sh
publish-client.sh = publish-client.sh publish-client.sh = publish-client.sh
watch-run-admin.sh = watch-run-admin.sh watch-run-admin.sh = watch-run-admin.sh

View File

@ -1,4 +1,5 @@
<Project> <Project>
<PropertyGroup> <PropertyGroup>
<Copyright>Longbow</Copyright> <Copyright>Longbow</Copyright>
<Authors>Argo Zhang(argo@163.com)</Authors> <Authors>Argo Zhang(argo@163.com)</Authors>
@ -11,9 +12,9 @@
<Target Condition=" '$(TargetFramework)' == 'netcoreapp3.0' " Name="PostPublish" AfterTargets="Publish"> <Target Condition=" '$(TargetFramework)' == 'netcoreapp3.0' " Name="PostPublish" AfterTargets="Publish">
<Message Text="Publish -> $(PublishDir)" Importance="high" /> <Message Text="Publish -> $(PublishDir)" Importance="high" />
<Copy Condition="'$(OS)' == 'Windows_NT'" DestinationFolder="$(PublishDir)" SourceFiles="$(MSBuildThisFileDirectory)src\admin\keys\Longbow.lic" SkipUnchangedFiles="true" /> <Copy Condition="'$(OS)' == 'Windows_NT'" DestinationFolder="$(PublishDir)" SourceFiles="$(MSBuildThisFileDirectory)src\admin\keys\Longbow.lic" SkipUnchangedFiles="true" />
<Copy Condition="'$(OS)' == 'UNIX'" DestinationFolder="$(PublishDir)" SourceFiles="$(MSBuildThisFileDirectory)src/admin/keys/Longbow.lic" SkipUnchangedFiles="true" />
<Copy Condition="'$(OS)' == 'Windows_NT'" DestinationFolder="$(PublishDir)" SourceFiles="$(MSBuildThisFileDirectory)src\admin\Bootstrap.Admin\BootstrapAdmin.db" SkipUnchangedFiles="true" /> <Copy Condition="'$(OS)' == 'Windows_NT'" DestinationFolder="$(PublishDir)" SourceFiles="$(MSBuildThisFileDirectory)src\admin\Bootstrap.Admin\BootstrapAdmin.db" SkipUnchangedFiles="true" />
<Copy Condition="'$(OS)' == 'Windows_NT'" DestinationFolder="$(PublishDir)" SourceFiles="$(MSBuildThisFileDirectory)src/admin/Bootstrap.Admin/BootstrapAdmin.db" SkipUnchangedFiles="true" /> <Copy Condition="'$(OS)' == 'UNIX'" DestinationFolder="$(PublishDir)" SourceFiles="$(MSBuildThisFileDirectory)src/admin/keys/Longbow.lic" SkipUnchangedFiles="true" />
<Copy Condition="'$(OS)' == 'UNIX'" DestinationFolder="$(PublishDir)" SourceFiles="$(MSBuildThisFileDirectory)src/admin/Bootstrap.Admin/BootstrapAdmin.db" SkipUnchangedFiles="true" />
</Target> </Target>
<Target Condition=" '$(TargetFramework)' == 'netcoreapp3.0' " Name="PostBuild" AfterTargets="PostBuildEvent"> <Target Condition=" '$(TargetFramework)' == 'netcoreapp3.0' " Name="PostBuild" AfterTargets="PostBuildEvent">

11
deploy-admin.sh Normal file
View File

@ -0,0 +1,11 @@
#! /bin/bash
cd ~/BootstrapAdmin
git pull
dotnet publish src/admin/Bootstrap.Admin -c Release
rm -f ~/BootstrapAdmin/src/admin/Bootstrap.Admin/bin/Release/netcoreapp2.2/publish/appsettings*.json
systemctl stop ba.admin
\cp -fr ~/BootstrapAdmin/src/admin/Bootstrap.Admin/bin/Release/netcoreapp2.2/publish/* /usr/local/ba/admin/
systemctl start ba.admin
systemctl status ba.admin -l

11
deploy-client.sh Normal file
View File

@ -0,0 +1,11 @@
#! /bin/bash
cd ~/BootstrapAdmin
git pull
dotnet publish src/client/Bootstrap.Client -c Release
rm -f ~/BootstrapAdmin/src/client/Bootstrap.Client/bin/Release/netcoreapp2.2/publish/appsettings*.json
systemctl stop ba.client
\cp -fr ~/BootstrapAdmin/src/client/Bootstrap.Client/bin/Release/netcoreapp2.2/publish/* /usr/local/ba/client/
systemctl start ba.client
systemctl status ba.client -l

View File

@ -1,11 +1,3 @@
#! /bin/bash #! /bin/bash
cd ~/BootstrapAdmin
git pull
dotnet publish src/admin/Bootstrap.Admin -c Release dotnet publish src/admin/Bootstrap.Admin -c Release
rm -f ~/BootstrapAdmin/src/admin/Bootstrap.Admin/bin/Release/netcoreapp2.2/publish/appsettings*.json
systemctl stop ba.admin
\cp -fr ~/BootstrapAdmin/src/admin/Bootstrap.Admin/bin/Release/netcoreapp2.2/publish/* /usr/local/ba/admin/
systemctl start ba.admin
systemctl status ba.admin

View File

@ -1,11 +1,3 @@
#! /bin/bash #! /bin/bash
cd ~/BootstrapAdmin
git pull
dotnet publish src/client/Bootstrap.Client -c Release dotnet publish src/client/Bootstrap.Client -c Release
rm -f ~/BootstrapAdmin/src/client/Bootstrap.Client/bin/Release/netcoreapp2.2/publish/appsettings*.json
systemctl stop ba.client
\cp -fr ~/BootstrapAdmin/src/client/Bootstrap.Client/bin/Release/netcoreapp2.2/publish/* /usr/local/ba/client/
systemctl start ba.client
systemctl status ba.client

View File

@ -1,3 +1,3 @@
@echo off @echo off
dotnet watch --project ./src/admin/Bootstrap.Admin run dotnet watch --project ./src/admin/Bootstrap.Admin run

View File

@ -1,3 +1,3 @@
#! /bin/bash #! /bin/bash
dotnet watch --project ./src/admin/Bootstrap.Admin run dotnet watch --project ./src/admin/Bootstrap.Admin run

View File

@ -1,3 +1,3 @@
@echo off @echo off
dotnet watch --project ./src/client/Bootstrap.Client run dotnet watch --project ./src/client/Bootstrap.Client run

View File

@ -1,3 +1,3 @@
#! /bin/bash #! /bin/bash
dotnet watch --project ./src/client/Bootstrap.Client run dotnet watch --project ./src/client/Bootstrap.Client run