Название: Scripting: Automation with Bash, PowerShell, and Python
Автор: Michael Kofler
Издательство: Rheinwerk Publishing Inc.
Год: 2024
Страниц: 473
Язык: английский
Формат: pdf (true), epub (true)
Размер: 13.6 MB
Developers and admins, it’s time to simplify your workday. With this practical guide, use scripting to solve tedious IT problems with less effort and less code! Learn about popular scripting languages: Bash, PowerShell, and Python. Master important techniques such as working with Linux, cmdlets, regular expressions, JSON, SSH, Git, and more. Use scripts to automate different scenarios, from backups and image processing to virtual machine management. Discover what’s possible with only 10 lines of code! A script is a small piece of code to solve a specific problem or automate a tedious task. You don’t need a development environment or a compiler to develop a script—an editor is enough. When it comes to scripting, minimalism is the name of the game, and its goal is achieving maximum impact with minimal resources. To put it casually, scripting is the art of solving IT problems in ten lines of code. The “classic” scripting language is Bash. Today, Bash is the dominant Linux shell, both in interactive mode for executing commands and for script programming. Bash is popular, but its antiquated syntax doesn’t win any beauty contests. On the contrary, Bash scripts sometimes look awful. For this reason, Microsoft did not even try to adapt Bash for Windows. Instead, with PowerShell, Microsoft has combined the basic ideas of a classic Unix shell with the concepts behind object-oriented programming languages and created a completely new language, which turned out surprisingly well! Python is actually not a typical scripting language. Depending on the intended use, Python is the basis for AI developments, a tool for scientists, or a first language for entry-level programming.