Merge branch 'master' into fix_settings_openurl

This commit is contained in:
Jeremy Wu 2020-04-25 13:31:50 +10:00
commit bc06c8d495
10 changed files with 21 additions and 16 deletions

View file

@ -8,6 +8,7 @@ using Flow.Launcher.Infrastructure;
using Flow.Launcher.Infrastructure.Logger;
using Flow.Launcher.Infrastructure.UserSettings;
using Flow.Launcher.Plugin.SharedCommands;
using System.Linq;
namespace Flow.Launcher.Core.Configuration
{
@ -19,7 +20,11 @@ namespace Flow.Launcher.Core.Configuration
/// <returns></returns>
private UpdateManager NewUpdateManager()
{
return new UpdateManager(string.Empty, Constant.FlowLauncher, Constant.RootDirectory);
var applicationFolderName = Constant.ApplicationDirectory
.Split(new[] { Path.DirectorySeparatorChar }, StringSplitOptions.None)
.Last();
return new UpdateManager(string.Empty, applicationFolderName, Constant.RootDirectory);
}
public void DisablePortableMode()
@ -148,7 +153,7 @@ namespace Flow.Launcher.Core.Configuration
{
// Specify here so this method does not rely on other environment variables to initialise
var portableDataPath = Path.Combine(Directory.GetParent(Assembly.GetExecutingAssembly().Location.NonNull()).ToString(), "UserData");
var roamingDataPath = Path.Combine(Environment.GetFolderPath(Environment.SpecialFolder.ApplicationData), "Flow.Launcher");
var roamingDataPath = Path.Combine(Environment.GetFolderPath(Environment.SpecialFolder.ApplicationData), "FlowLauncher");
bool DataLocationPortableDeleteRequired = false;
bool DataLocationRoamingDeleteRequired = false;

View file

@ -12,7 +12,7 @@ namespace Flow.Launcher.Infrastructure.UserSettings
public const string PortableFolderName = "UserData";
public const string DeletionIndicatorFile = ".dead";
public static string PortableDataPath = Path.Combine(Constant.ProgramDirectory, PortableFolderName);
public static string RoamingDataPath = Path.Combine(Environment.GetFolderPath(Environment.SpecialFolder.ApplicationData), Constant.FlowLauncher);
public static string RoamingDataPath = Path.Combine(Environment.GetFolderPath(Environment.SpecialFolder.ApplicationData), "FlowLauncher");
public static string DataDirectory()
{
if (PortableDataLocationInUse())

View file

@ -387,7 +387,7 @@
<Run Text="{Binding Github, Mode=OneWay}" />
</Hyperlink>
</TextBlock>
<TextBlock Grid.Row="2" Grid.Column="0" Text="JJW24 Version" />
<TextBlock Grid.Row="2" Grid.Column="0" Text="Version" />
<TextBlock Grid.Row="2" Grid.Column="1" Text="{Binding Version}" />
<TextBlock Grid.Row="3" Grid.Column="0" Text="{DynamicResource releaseNotes}" />
<TextBlock Grid.Row="3" Grid.Column="1">

View file

@ -4,7 +4,7 @@ import json
import sys
import inspect
class Flow.Launcher(object):
class FlowLauncher(object):
"""
Flow.Launcher python plugin base
"""
@ -42,7 +42,7 @@ class Flow.Launcher(object):
print("DEBUG:{}".format(msg))
sys.exit()
class Flow.LauncherAPI(object):
class FlowLauncherAPI(object):
@classmethod
def change_query(cls,query,requery = False):

View file

@ -1,8 +1,8 @@
# -*- coding: utf-8 -*-
from flowlauncher import Flow.Launcher
from flow.launcher import Flow.Launcher
class HelloWorld(Flow.Launcher):
class HelloWorld(FlowLauncher):
def query(self, query):
results = []

View file

@ -6,7 +6,7 @@
"Author":"happlebao",
"Version":"1.0",
"Language":"python",
"Website":"https://github.com/wox-launcher/wox",
"Website":"https://github.com/Flow-Launcher/Flow.Launcher",
"IcoPath":"Images\\app.png",
"ExecuteFileName":"main.py"
}

View file

@ -1,7 +1,7 @@
<?xml version="1.0"?>
<package>
<metadata>
<id>Flow.Launcher-JJW24</id>
<id>FlowLauncher</id>
<title>Flow Launcher</title>
<version>$version$</version>
<authors>happlebao, Jeremy Wu</authors>

View file

@ -74,7 +74,7 @@ function Zip-Release ($path, $version, $output) {
$input = "$path\Output\Release"
Write-Host "Input path: $input"
$file = "$output\Flow.Launcher-JJW24-$version.zip"
$file = "$output\Flow.Launcher-$version.zip"
Write-Host "Filename: $file"
[Reflection.Assembly]::LoadWithPartialName("System.IO.Compression.FileSystem")
@ -93,7 +93,7 @@ function Pack-Squirrel-Installer ($path, $version, $output) {
Write-Host "Input path: $input"
Nuget pack $spec -Version $version -Properties Configuration=Release -BasePath $input -OutputDirectory $output
$nupkg = "$output\Flow.Launcher-JJW24.$version.nupkg"
$nupkg = "$output\FlowLauncher.$version.nupkg"
Write-Host "nupkg path: $nupkg"
$icon = "$path\Flow.Launcher\Resources\app.ico"
Write-Host "icon: $icon"
@ -107,7 +107,7 @@ function Pack-Squirrel-Installer ($path, $version, $output) {
Move-Item $temp\* $output -Force
Remove-Item $temp
$file = "$output\Flow.Launcher-JJW24-$version.exe"
$file = "$output\Flow Launcher-$version.exe"
Write-Host "Filename: $file"
Move-Item "$output\Setup.exe" $file -Force

View file

@ -16,6 +16,6 @@ using System.Runtime.InteropServices;
[assembly: AssemblyTrademark("")]
[assembly: AssemblyCulture("")]
[assembly: ComVisible(false)]
[assembly: AssemblyVersion("2.0.0")]
[assembly: AssemblyFileVersion("2.0.0")]
[assembly: AssemblyInformationalVersion("2.0.0")]
[assembly: AssemblyVersion("1.0.0")]
[assembly: AssemblyFileVersion("1.0.0")]
[assembly: AssemblyInformationalVersion("1.0.0")]