Application Building Automation Ideas

I am currently working on an internal .NET test tool. At the moment, the tool is based on a graphical interface. One of the things I want the tool to be able to do is run in command line mode. Thus, we can run it in automatic mode and crunch according to some data every day.

We started introducing command line mode into it, but I'm just not happy with it. He feels awkward and just worn. I am looking for a more elegant solution that will scale relatively easily as we provide more features for the application.

One of my thoughts was modeled after PowerShell and Exchange Server. The Exchange server apparently built about 800 cmdlets, and then used them to create its own interface. Thus, everything the user interface can do can be used with cmdlets using a script. I really like it, to be honest. It is elegant and scalable in a natural way, as they add more functionality.

What ideas do you have for something like that? Has anyone out there tried the PowerShell route I mentioned? Share your thoughts.

thanks

+3
source share
4 answers

Powershell .NET , , .NET. , DLL, .NET, System.IO, System.Net, , - .. . Powershell script, -. -, , - , , . script, , , , - - . script Pageflakes , - . , , script, zip - . - .

Powershell script :

* Maintains different configuration information for different deployments. For example, different connection strings for development servers and production servers (one or more production servers).
* Creates a deployment folder using the deployment date, time, and version so that you have a separate folder for each deployment and can keep track of things deployed on a day, e.g., 20061214-1.
* Copies only the change files and some predefined files to the deployment folder. So, you don't deploy the whole website every day.
* Copies the web.config and customizes the <appSettings>, <connectionString>, <assemblies> etc., as per the deployment configuration. For example, you can have different connection strings for different servers.
* Updates all JavaScript files with a version number so that in every deployment, a new file gets downloaded by client browsers.
* Updates default.aspx automatically with the modified script file name.
* Compresses all JavaScript files that gets deployed.
* Compresses all static HTML files using an Absolute HTML Optimizer.
* Creates a zip file which contains the deployment package.
* FTP the zip file to a target server.

script , , - zip !

FTP zip , FTP script.

0

API - . API- , .

, . PowerShell , , .

-, , . - UI , . .

+3

PowerShell CLI GUI. , !

, , . Cmdlet. .

, , . , , , , . , ! , , , PowerShell . , , , PowerShell, , ( , ).

, GUI ... PowerShell - . , , psake, .

+3

unix/linux - . , / ( ).

0

Source: https://habr.com/ru/post/1715428/


All Articles