Skip to content

Commit

Permalink
Added support for getting the directory of the application.
Browse files Browse the repository at this point in the history
  • Loading branch information
GregaMohorko committed Oct 3, 2017
1 parent 1647149 commit 4205f65
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions src/BlueUpdate/BlueUpdate/IO/Directories.cs
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,15 @@ namespace BlueUpdate.IO
/// </summary>
public static class Directories
{
/// <summary>
/// Gets the directory of the specified application.
/// </summary>
/// <param name="app">The application of which to get the directory.</param>
public static DirectoryInfo GetDirectory(UpdatableApp app)
{
return GetDirectory(app.DirectoryName, false);
}

internal static DirectoryInfo GetDirectory(string name,bool createIfNotPresent=false)
{
DirectoryInfo[] siblingDirectories = Update.RootDirectory.GetDirectories(name, SearchOption.TopDirectoryOnly);
Expand Down

0 comments on commit 4205f65

Please sign in to comment.