Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 0 additions & 4 deletions Deploy/local_build.ps1

This file was deleted.

5 changes: 5 additions & 0 deletions Directory.Build.props
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
<Project>
<PropertyGroup>
<AccelerateBuildsInVisualStudio>true</AccelerateBuildsInVisualStudio>
</PropertyGroup>
</Project>
Original file line number Diff line number Diff line change
Expand Up @@ -41,18 +41,6 @@ internal IEnumerable<PluginPair> Setup()
if (!PluginMetadataList.Any(o => o.Language.Equals(Language, StringComparison.OrdinalIgnoreCase)))
return new List<PluginPair>();

// TODO: Remove. This is backwards compatibility for 1.10.0 release- changed PythonEmbeded to Environments/Python
if (Language.Equals(AllowedLanguage.Python, StringComparison.OrdinalIgnoreCase))
{
FilesFolders.RemoveFolderIfExists(Path.Combine(DataLocation.DataDirectory(), "PythonEmbeddable"));

if (!string.IsNullOrEmpty(PluginSettings.PythonDirectory) && PluginSettings.PythonDirectory.StartsWith(Path.Combine(DataLocation.DataDirectory(), "PythonEmbeddable")))
{
InstallEnvironment();
PluginSettings.PythonDirectory = string.Empty;
}
}

if (!string.IsNullOrEmpty(PluginsSettingsFilePath) && FilesFolders.FileExists(PluginsSettingsFilePath))
{
// Ensure latest only if user is using Flow's environment setup.
Expand Down
12 changes: 8 additions & 4 deletions Flow.Launcher.Core/Plugin/QueryBuilder.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
using System;
using System;
using System.Collections.Generic;
using Flow.Launcher.Plugin;

Expand Down Expand Up @@ -33,9 +33,13 @@ public static Query Build(string text, Dictionary<string, PluginPair> nonGlobalP
searchTerms = terms;
}

var query = new Query(rawQuery, search,terms, searchTerms, actionKeyword);

return query;
return new Query ()
{
Search = search,
RawQuery = rawQuery,
SearchTerms = searchTerms,
ActionKeyword = actionKeyword
};
}
}
}
115 changes: 0 additions & 115 deletions Flow.Launcher.CrashReporter/Flow.Launcher.CrashReporter.csproj

This file was deleted.

Binary file removed Flow.Launcher.CrashReporter/Images/app_error.png
Binary file not shown.
Binary file removed Flow.Launcher.CrashReporter/Images/crash_go.png
Binary file not shown.
Binary file removed Flow.Launcher.CrashReporter/Images/crash_stop.png
Binary file not shown.
Binary file removed Flow.Launcher.CrashReporter/Images/crash_warning.png
Binary file not shown.
5 changes: 0 additions & 5 deletions Flow.Launcher.CrashReporter/Properties/AssemblyInfo.cs

This file was deleted.

6 changes: 0 additions & 6 deletions Flow.Launcher.CrashReporter/packages.config

This file was deleted.

8 changes: 0 additions & 8 deletions Flow.Launcher.Infrastructure/Storage/ISavable.cs

This file was deleted.

22 changes: 0 additions & 22 deletions Flow.Launcher.Infrastructure/UserSettings/PluginSettings.cs
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,6 @@ public string NodeExecutablePath
}
}

// TODO: Remove. This is backwards compatibility for 1.10.0 release.
public string PythonDirectory { get; set; }

public Dictionary<string, Plugin> Plugins { get; set; } = new Dictionary<string, Plugin>();

public void UpdatePluginSettings(List<PluginMetadata> metadatas)
Expand All @@ -38,25 +35,6 @@ public void UpdatePluginSettings(List<PluginMetadata> metadatas)
if (Plugins.ContainsKey(metadata.ID))
{
var settings = Plugins[metadata.ID];

if (metadata.ID == "572be03c74c642baae319fc283e561a8" && metadata.ActionKeywords.Count > settings.ActionKeywords.Count)
{
// TODO: Remove. This is backwards compatibility for Explorer 1.8.0 release.
// Introduced two new action keywords in Explorer, so need to update plugin setting in the UserData folder.
if (settings.Version.CompareTo("1.8.0") < 0)
{
settings.ActionKeywords.Add(Query.GlobalPluginWildcardSign); // for index search
settings.ActionKeywords.Add(Query.GlobalPluginWildcardSign); // for path search
settings.ActionKeywords.Add(Query.GlobalPluginWildcardSign); // for quick access action keyword
}

// TODO: Remove. This is backwards compatibility for Explorer 1.9.0 release.
// Introduced a new action keywords in Explorer since 1.8.0, so need to update plugin setting in the UserData folder.
if (settings.Version.CompareTo("1.8.0") > 0)
{
settings.ActionKeywords.Add(Query.GlobalPluginWildcardSign); // for quick access action keyword
}
}

if (string.IsNullOrEmpty(settings.Version))
settings.Version = metadata.Version;
Expand Down
7 changes: 0 additions & 7 deletions Flow.Launcher.Plugin/Interfaces/IPublicAPI.cs
Original file line number Diff line number Diff line change
Expand Up @@ -133,13 +133,6 @@ public interface IPublicAPI
/// <returns></returns>
List<PluginPair> GetAllPlugins();

/// <summary>
/// Fired after global keyboard events
/// if you want to hook something like Ctrl+R, you should use this event
/// </summary>
[Obsolete("Unable to Retrieve correct return value")]
event FlowLauncherGlobalKeyboardEventHandler GlobalKeyboardEvent;

/// <summary>
/// Register a callback for Global Keyboard Event
/// </summary>
Expand Down
19 changes: 1 addition & 18 deletions Flow.Launcher.Plugin/Query.cs
Original file line number Diff line number Diff line change
Expand Up @@ -6,16 +6,11 @@ public class Query
{
public Query() { }

/// <summary>
/// to allow unit tests for plug ins
/// </summary>
[Obsolete("Use the default Query constructor.")]
public Query(string rawQuery, string search, string[] terms, string[] searchTerms, string actionKeyword = "")
{
Search = search;
RawQuery = rawQuery;
#pragma warning disable CS0618
Terms = terms;
#pragma warning restore CS0618
SearchTerms = searchTerms;
ActionKeyword = actionKeyword;
}
Expand Down Expand Up @@ -47,28 +42,16 @@ public Query(string rawQuery, string search, string[] terms, string[] searchTerm
/// </summary>
public string[] SearchTerms { get; init; }

/// <summary>
/// The raw query split into a string array
/// </summary>
[Obsolete("It may or may not include action keyword, which can be confusing. Use SearchTerms instead")]
public string[] Terms { get; init; }

/// <summary>
/// Query can be splited into multiple terms by whitespace
/// </summary>
public const string TermSeparator = " ";

[Obsolete("Typo")]
public const string TermSeperater = TermSeparator;

/// <summary>
/// User can set multiple action keywords seperated by ';'
/// </summary>
public const string ActionKeywordSeparator = ";";

[Obsolete("Typo")]
public const string ActionKeywordSeperater = ActionKeywordSeparator;


/// <summary>
/// Wildcard action keyword. Plugins using this value will be queried on every search.
Expand Down
6 changes: 0 additions & 6 deletions Flow.Launcher.Plugin/Result.cs
Original file line number Diff line number Diff line change
Expand Up @@ -133,12 +133,6 @@ public string IcoPath
/// </summary>
public IList<int> TitleHighlightData { get; set; }

/// <summary>
/// Deprecated as of Flow Launcher v1.9.1. Subtitle highlighting is no longer offered
/// </summary>
[Obsolete("Deprecated as of Flow Launcher v1.9.1. Subtitle highlighting is no longer offered")]
public IList<int> SubTitleHighlightData { get; set; }

/// <summary>
/// Query information associated with the result
/// </summary>
Expand Down
14 changes: 1 addition & 13 deletions Flow.Launcher.Plugin/SharedCommands/SearchWeb.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
using Microsoft.Win32;
using Microsoft.Win32;
using System;
using System.Diagnostics;
using System.IO;
Expand Down Expand Up @@ -71,12 +71,6 @@ public static void OpenInBrowserWindow(this string url, string browserPath = "",
}
}

[Obsolete("This is provided for backwards compatibility after 1.9.0 release, e.g. GitHub plugin. Use the new method instead")]
public static void NewBrowserWindow(this string url, string browserPath = "")
{
OpenInBrowserWindow(url, browserPath);
}

/// <summary>
/// Opens search as a tab in the default browser chosen in Windows settings.
/// </summary>
Expand Down Expand Up @@ -111,11 +105,5 @@ public static void OpenInBrowserTab(this string url, string browserPath = "", bo
});
}
}

[Obsolete("This is provided for backwards compatibility after 1.9.0 release, e.g. GitHub plugin. Use the new method instead")]
public static void NewTabInBrowser(this string url, string browserPath = "")
{
OpenInBrowserTab(url, browserPath);
}
}
}
21 changes: 17 additions & 4 deletions Flow.Launcher.Test/QueryBuilderTest.cs
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,19 @@ public void ExclusivePluginQueryTest()
{">", new PluginPair {Metadata = new PluginMetadata {ActionKeywords = new List<string> {">"}}}}
};

Query q = QueryBuilder.Build("> file.txt file2 file3", nonGlobalPlugins);
Query q = QueryBuilder.Build("> ping google.com -n 20 -6", nonGlobalPlugins);

Assert.AreEqual("file.txt file2 file3", q.Search);
Assert.AreEqual("> ping google.com -n 20 -6", q.RawQuery);
Assert.AreEqual("ping google.com -n 20 -6", q.Search, "Search should not start with the ActionKeyword.");
Assert.AreEqual(">", q.ActionKeyword);

Assert.AreEqual(5, q.SearchTerms.Length, "The length of SearchTerms should match.");

Assert.AreEqual("ping", q.FirstSearch);
Assert.AreEqual("google.com", q.SecondSearch);
Assert.AreEqual("-n", q.ThirdSearch);

Assert.AreEqual("google.com -n 20 -6", q.SecondToEndSearch, "SecondToEndSearch should be trimmed of multiple whitespace characters");
}

[Test]
Expand All @@ -29,9 +38,13 @@ public void ExclusivePluginQueryIgnoreDisabledTest()
{">", new PluginPair {Metadata = new PluginMetadata {ActionKeywords = new List<string> {">"}, Disabled = true}}}
};

Query q = QueryBuilder.Build("> file.txt file2 file3", nonGlobalPlugins);
Query q = QueryBuilder.Build("> ping google.com -n 20 -6", nonGlobalPlugins);

Assert.AreEqual("> file.txt file2 file3", q.Search);
Assert.AreEqual("> ping google.com -n 20 -6", q.Search);
Assert.AreEqual(q.Search, q.RawQuery, "RawQuery should be equal to Search.");
Assert.AreEqual(6, q.SearchTerms.Length, "The length of SearchTerms should match.");
Assert.AreNotEqual(">", q.ActionKeyword, "ActionKeyword should not match that of a disabled plugin.");
Assert.AreEqual("ping google.com -n 20 -6", q.SecondToEndSearch, "SecondToEndSearch should be trimmed of multiple whitespace characters");
}

[Test]
Expand Down
1 change: 1 addition & 0 deletions Flow.Launcher.sln
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,7 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution
.gitattributes = .gitattributes
.gitignore = .gitignore
appveyor.yml = appveyor.yml
Directory.Build.props = Directory.Build.props
Directory.Build.targets = Directory.Build.targets
Scripts\flowlauncher.nuspec = Scripts\flowlauncher.nuspec
LICENSE = LICENSE
Expand Down
Loading