So i have all these servers and each one has a web.config on it. I need to run a script that will compare all the webconfigs for specific nodes.
for example i want to see if all the web.configs have the same publishedstate “configuration/appSettings/add/PublishState”
I am very new to coding and this is a little project I was assigned to at work. Any help, I would appreciate it. THanks
using System;
using System.Collections.Generic;
using System.Linq;
using System.IO;
using System.Diagnostics;
using System.Text;
using System.Xml;
namespace Project1
{
class Program
{
static void Main()
{
// Reads the webconfigs.txt file one line at a time.
TextReader trs = new StreamReader("\\\\servername\\Project1\\webconfigs.txt");
Console.WriteLine(trs.ReadLine());
}
}
}