<commit_before>﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using DotRas;

namespace VPN {
class Program {
    static void Main(string[] args) {
        // default command is --start
        if (args.Length == 0) args = new string[] { "--start" };

        // if app root exist config file then use it, else use user's personal root
        string file = AppDomain.CurrentDomain.BaseDirectory + "vpn.bin";
        if (!System.IO.File.Exists(file))
            file = System.Environment.GetFolderPath(System.Environment.SpecialFolder.Personal) + "\\vpn.bin";

        // try to get config file
        Config cfg;
        try {
            cfg = new Config(file);
        } catch (Exception ex) {
            Console.WriteLine("Open config file failed, please check if config file has been occupied by other application.");
            return;
        }

        Console.Title = "VPN Tool";
        // process command
        switch (args[0]) {
        /// help
        case "-h":
        case "--help":
            Console.WriteLine("This application is write to connect vpns with the function of auto switch account.");
            Console.WriteLine("source: https://github.com/tinymins/vpn");
            Console.WriteLine("usage: vpn [--help] [<command>] [<args>]");
            Console.WriteLine("");
            Console.WriteLine("Commands:");
            Console.WriteLine("  1. To config your vpn adapter name:");
            Console.WriteLine("     vpn [-e|--set-entry] YOUR_VPN_CONNECTION_NAME");
            Console.WriteLine("  2. To add or update password of vpn account list:");
            Console.WriteLine("     vpn [-a|--add-account] HOSTNAME USERNAME PASSWORD");
            Console.WriteLine("  3. To remove vpn account:");
            Console.WriteLine("     vpn [-d|--delete-account] HOSTNAME USERNAME");
            Console.WriteLine("  4. To remove all vpn account:");
            Console.WriteLine("     vpn [-c|--clear-account]");
            Console.WriteLine("  5. To list vpn account:");
            Console.WriteLine("     vpn [-l|--list-account]");;
            Console.WriteLine("  6. To connect vpn:");
            Console.WriteLine("     vpn [-s|--start]");
            Console.WriteLine("");
            Console.WriteLine("Samples:");
            Console.WriteLine("  vpn --set-entry MyVPN");
            Console.WriteLine("  vpn --add-account vpn.sample.com root password");<commit_msg>Change help text<commit_after>﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using DotRas;

namespace VPN {
class Program {
    static void Main(string[] args) {
        // default command is --start
        if (args.Length == 0) args = new string[] { "--start" };

        // if app root exist config file then use it, else use user's personal root
        string file = AppDomain.CurrentDomain.BaseDirectory + "vpn.bin";
        if (!System.IO.File.Exists(file))
            file = System.Environment.GetFolderPath(System.Environment.SpecialFolder.Personal) + "\\vpn.bin";

        // try to get config file
        Config cfg;
        try {
            cfg = new Config(file);
        } catch (Exception ex) {
            Console.WriteLine("Open config file failed, please check if config file has been occupied by other application.");
            return;
        }

        Console.Title = "VPN Tool";
        // process command
        switch (args[0]) {
        /// help
        case "-h":
        case "--help":
            Console.WriteLine("This application writes for connecting vpns with the function\nof auto switch account.");
            Console.WriteLine("source: https://github.com/tinymins/vpn");
            Console.WriteLine("usage: vpn [--help] [<command>] [<args>]");
            Console.WriteLine("");
            Console.WriteLine("Commands:");
            Console.WriteLine("  1. To config your vpn adapter name:");
            Console.WriteLine("     vpn [-e|--set-entry] YOUR_VPN_CONNECTION_NAME");
            Console.WriteLine("  2. To add or update password of vpn account list:");
            Console.WriteLine("     vpn [-a|--add-account] HOSTNAME USERNAME PASSWORD");
            Console.WriteLine("  3. To remove vpn account:");
            Console.WriteLine("     vpn [-d|--delete-account] HOSTNAME USERNAME");
            Console.WriteLine("  4. To remove all vpn account:");
            Console.WriteLine("     vpn [-c|--clear-account]");
            Console.WriteLine("  5. To list vpn account:");
            Console.WriteLine("     vpn [-l|--list-account]");;
            Console.WriteLine("  6. To connect vpn:");
            Console.WriteLine("     vpn [-s|--start]");
            Console.WriteLine("");
            Console.WriteLine("Samples:");
            Console.WriteLine("  vpn --set-entry MyVPN");
            Console.WriteLine("  vpn --add-account vpn.sample.com root password");
{'fraction_non_alphanumeric': 0.13401442307692307, 'fraction_numerical': 0.003205128205128205, 'mean_word_length': 2.1323713927227104, 'pattern_counts': {'":': 4, '<': 7, '<?xml version=': 0, '>': 7, 'https://': 2, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1237578', 'n_tokens_mistral': 1332, 'n_tokens_neox': 1311, 'n_words': 395}