forked from vaginessa/rcloneWinMount
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Program.cs
33 lines (30 loc) · 923 Bytes
/
Program.cs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
using System;
using DokanNet;
namespace rcloneWinMount
{
internal class Program
{
private static void Main(string[] remoteNameArg)
{
if (remoteNameArg.Length == 0)
{
Console.WriteLine("No Remote defined!");
Console.WriteLine("Press Return to Exit");
Console.ReadLine();
}
else
{
try
{
var mirror = new rcloneMountPoint(remoteNameArg[0]);
mirror.Mount("s:\\", DokanOptions.DebugMode | DokanOptions.NetworkDrive, 5);
Console.WriteLine(@"Success");
}
catch (DokanException ex)
{
Console.WriteLine(@"Error: " + ex.Message);
}
}
}
}
}