Skip to content

Commit

Permalink
fix acme.sh issue
Browse files Browse the repository at this point in the history
  • Loading branch information
huifeng.liu committed Feb 2, 2021
1 parent 7be972f commit 30d8171
Show file tree
Hide file tree
Showing 8 changed files with 42 additions and 21 deletions.
19 changes: 13 additions & 6 deletions ProxySU/MainWindow.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:local="clr-namespace:ProxySU"
mc:Ignorable="d"
Title="ProxySU - v2.5.4" Height="675" Width="660">
Title="ProxySU - v2.5.5" Height="720" Width="660">
<!--以下样式参考自:https://yq.aliyun.com/articles/331878
https://docs.microsoft.co/en-us/dotnet/desktop-wpf/fundamentals/styles-templates-overview-->
<Window.Resources>
Expand Down Expand Up @@ -57,6 +57,7 @@
<Grid>
<Grid.RowDefinitions>
<RowDefinition></RowDefinition>
<RowDefinition Height="40"></RowDefinition>
<RowDefinition Height="1.3*"></RowDefinition>
<RowDefinition Height="1.8*"></RowDefinition>
</Grid.RowDefinitions>
Expand Down Expand Up @@ -147,23 +148,29 @@
<TextBlock x:Name="TextBlockProxyPassword" IsEnabled="False" Text="{DynamicResource TextBlockHostPassword}" HorizontalAlignment="Right" VerticalAlignment="Center" Margin="5" Grid.Column="2" Grid.Row="1" ></TextBlock>
<TextBox x:Name="TextBoxProxyUserName" IsEnabled="False" Text="" Margin="3" Grid.Column="1" Grid.Row="1" />
<PasswordBox x:Name="PasswordBoxProxyPassword" IsEnabled="False" Password="" Margin="3" Grid.Column="3" Grid.Row="1"></PasswordBox>
<Button x:Name="ButtonSaveInstalledLog" Content="{DynamicResource ButtonSaveInstalledLog}" Grid.Column="4" Grid.Row="1" Grid.ColumnSpan="2" Margin="10,3,10,3" Click="ButtonSaveInstalledLog_Click"></Button>
</Grid>
</Grid>
<Grid Grid.Row="1">
<Grid Grid.Row="1">
<StackPanel Margin="10,0,0,0" Orientation="Horizontal" VerticalAlignment="Center">
<TextBlock Foreground="Red" x:Name="AcmeEmailLabel" Text="Email:" VerticalAlignment="Center" />
<TextBox Margin="10,0,0,0" Height="20" Width="200" x:Name="AcmeEmailTextBox" />
<TextBlock Margin="10,0,0,0" Text="{DynamicResource AcmeEmailDesc}" Foreground="Red" />
</StackPanel>
</Grid>
<Grid Grid.Row="2">
<Grid.RowDefinitions>
<RowDefinition Height="20"></RowDefinition>
<RowDefinition Height="20"></RowDefinition>
<RowDefinition></RowDefinition>
</Grid.RowDefinitions>

<TextBlock x:Name="TextBlockSetUpProcessing" Text="{DynamicResource TextBlockSetUpProcessing}" Foreground="Blue" HorizontalAlignment="Center" VerticalAlignment="Center" Grid.Row="0"></TextBlock>
<Button x:Name="ButtonSaveInstalledLog" Content="{DynamicResource ButtonSaveInstalledLog}" Margin="0,0,10,0" Width="140" HorizontalAlignment="Right" Click="ButtonSaveInstalledLog_Click"></Button>
<TextBlock x:Name="TextBlockSetUpProcessing" Text="{DynamicResource TextBlockSetUpProcessing}" Foreground="Blue" HorizontalAlignment="Center" VerticalAlignment="Center" Grid.Row="0"></TextBlock>
<ProgressBar x:Name="ProgressBarSetUpProcessing" Minimum="0" Maximum="100" Value="{Binding InsertBindingHere}" Margin="10,0,10,3" Grid.Row="1"></ProgressBar>
<TextBlock Text="{Binding ElementName=ProgressBarSetUpProcessing, Path=Value, StringFormat={}{0:0}%}" HorizontalAlignment="Center" VerticalAlignment="Center" Grid.Row="1"/>
<TextBox x:Name="TextBoxMonitorCommandResults" IsReadOnly="True" TextWrapping="Wrap" AcceptsReturn="True" VerticalScrollBarVisibility="Auto" Grid.Row="2" Margin="10,0,10,3"></TextBox>

</Grid>
<Grid Grid.Row="2">
<Grid Grid.Row="3">
<TabControl Grid.Column="0" Grid.Row="9" Grid.ColumnSpan="4" Grid.RowSpan="3">
<TabItem Header="Xray" Width="60" Height="30">
<Grid>
Expand Down
3 changes: 2 additions & 1 deletion ProxySU/MainWindow.xaml.cs
Original file line number Diff line number Diff line change
Expand Up @@ -10102,7 +10102,8 @@ private bool AcmeShInstall(SshClient client)
sshShellCommand = $"{sshCmdInstall}automake autoconf libtool";
currentShellCommandResult = MainWindowsShowCmd(client, sshShellCommand);

sshShellCommand = $"curl https://raw.githubusercontent.com/acmesh-official/acme.sh/master/acme.sh | INSTALLONLINE=1 sh";
//sshShellCommand = $"curl https://raw.githubusercontent.com/acmesh-official/acme.sh/master/acme.sh | INSTALLONLINE=1 sh";
sshShellCommand = $"curl https://raw.githubusercontent.com/acmesh-official/acme.sh/master/acme.sh | sh -s -- --install-online -m {AcmeEmailTextBox.Text}";
currentShellCommandResult = MainWindowsShowCmd(client, sshShellCommand);

if (currentShellCommandResult.Contains("Install success") == true)
Expand Down
4 changes: 2 additions & 2 deletions ProxySU/Properties/AssemblyInfo.cs
Original file line number Diff line number Diff line change
Expand Up @@ -51,5 +51,5 @@
// 可以指定所有值,也可以使用以下所示的 "*" 预置版本号和修订号
// 方法是按如下所示使用“*”: :
// [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("2.5.4.0")]
[assembly: AssemblyFileVersion("2.5.4.0")]
[assembly: AssemblyVersion("2.5.5.0")]
[assembly: AssemblyFileVersion("2.5.5.0")]
31 changes: 19 additions & 12 deletions ProxySU/ProxySU.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
<ProjectTypeGuids>{60dc8134-eba5-43b8-bcc9-bb4bc16c2548};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}</ProjectTypeGuids>
<WarningLevel>4</WarningLevel>
<Deterministic>true</Deterministic>
<IsWebBootstrapper>false</IsWebBootstrapper>
<PublishUrl>publish\</PublishUrl>
<Install>true</Install>
<InstallFrom>Disk</InstallFrom>
Expand All @@ -23,10 +24,10 @@
<UpdatePeriodically>false</UpdatePeriodically>
<UpdateRequired>false</UpdateRequired>
<MapFileExtensions>true</MapFileExtensions>
<ApplicationRevision>0</ApplicationRevision>
<ApplicationRevision>1</ApplicationRevision>
<ApplicationVersion>1.0.0.%2a</ApplicationVersion>
<IsWebBootstrapper>false</IsWebBootstrapper>
<UseApplicationTrust>false</UseApplicationTrust>
<PublishWizardCompleted>true</PublishWizardCompleted>
<BootstrapperEnabled>true</BootstrapperEnabled>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
Expand All @@ -51,6 +52,18 @@
<PropertyGroup>
<ApplicationIcon>ProxySU.ico</ApplicationIcon>
</PropertyGroup>
<PropertyGroup>
<ManifestCertificateThumbprint>01AFC64B121E781F77B42A6E9F1B587DDBAD475A</ManifestCertificateThumbprint>
</PropertyGroup>
<PropertyGroup>
<ManifestKeyFile>ProxySU_TemporaryKey.pfx</ManifestKeyFile>
</PropertyGroup>
<PropertyGroup>
<GenerateManifests>true</GenerateManifests>
</PropertyGroup>
<PropertyGroup>
<SignManifests>true</SignManifests>
</PropertyGroup>
<ItemGroup>
<Reference Include="Newtonsoft.Json">
<HintPath>..\json.net\net40\Newtonsoft.Json.dll</HintPath>
Expand Down Expand Up @@ -186,17 +199,11 @@
<ItemGroup />
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<PropertyGroup>
<PostBuildEvent>del "$(TargetDir)*.xml"
del "$(TargetDir)*.pdb"
del "$(TargetDir)*.zip"
mkdir "$(TargetDir)TemplateConfg"
xcopy /Y /E /R "$(TargetDir)..\..\..\TemplateConfg\*.*" "$(TargetDir)TemplateConfg\"
"$(TargetDir)..\..\..\7z\7z.exe" a $(TargetDir)Release.zip $(TargetDir) -xr!*config
rmdir /S /Q "$(TargetDir)..\Beta"
mkdir "$(TargetDir)..\Beta"
copy /Y "$(TargetDir)Release.zip" "$(TargetDir)..\Beta\Beta.zip"</PostBuildEvent>
<PostBuildEvent>
</PostBuildEvent>
</PropertyGroup>
<PropertyGroup>
<PreBuildEvent>rmdir /S /Q "$(TargetDir)</PreBuildEvent>
<PreBuildEvent>
</PreBuildEvent>
</PropertyGroup>
</Project>
2 changes: 2 additions & 0 deletions ProxySU/Translations/ProxySU.en-US.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,8 @@
<sys:String x:Key="RadioButtonProxyNoLogin">Not Login</sys:String>
<sys:String x:Key="RadiobuttonProxyYesLogin">Requires Login</sys:String>
<sys:String x:Key="TextBlockProxyHost">Proxy Addr:</sys:String>
<sys:String x:Key="AcmeEmail">Email</sys:String>
<sys:String x:Key="AcmeEmailDesc">Acme.sh SSL must an available email address.</sys:String>
<sys:String x:Key="ButtonSaveInstalledLog">Save Installation Log...</sys:String>
<sys:String x:Key="TextBlockSetUpProcessing">Waiting for installation and deployment</sys:String>
<sys:String x:Key="TabItemHeaderSysTools">System Tools</sys:String>
Expand Down
2 changes: 2 additions & 0 deletions ProxySU/Translations/ProxySU.zh-CN.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,8 @@
<sys:String x:Key="RadioButtonProxyNoLogin">不需登录</sys:String>
<sys:String x:Key="RadiobuttonProxyYesLogin">需要登录</sys:String>
<sys:String x:Key="TextBlockProxyHost">代理地址:</sys:String>
<sys:String x:Key="AcmeEmail">Email</sys:String>
<sys:String x:Key="AcmeEmailDesc">申请SSL证书需要一个可用的Email地址</sys:String>
<sys:String x:Key="ButtonSaveInstalledLog">安装日志另存为...</sys:String>
<sys:String x:Key="TextBlockSetUpProcessing">等待安装布署</sys:String>
<sys:String x:Key="TabItemHeaderSysTools">系统工具</sys:String>
Expand Down
2 changes: 2 additions & 0 deletions ProxySU/Translations/ProxySU.zh-TW.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,8 @@
<sys:String x:Key="RadioButtonProxyNoLogin">不需登錄</sys:String>
<sys:String x:Key="RadiobuttonProxyYesLogin">需要登錄</sys:String>
<sys:String x:Key="TextBlockProxyHost">代理地址:</sys:String>
<sys:String x:Key="AcmeEmail">Email</sys:String>
<sys:String x:Key="AcmeEmailDesc">申請SSL證書需要一個可用的Email地址</sys:String>
<sys:String x:Key="ButtonSaveInstalledLog">安裝日誌另存為...</sys:String>
<sys:String x:Key="TextBlockSetUpProcessing">等待安裝佈署</sys:String>
<sys:String x:Key="TabItemHeaderSysTools">系統工具</sys:String>
Expand Down
Binary file removed ProxySU/bin/Beta/Beta.zip
Binary file not shown.

0 comments on commit 30d8171

Please sign in to comment.