About the Python backup script
Greetings!

A lyrical post about how I started writing a backup script in Python 🧑💻.

This post is just a marker of the current status of my idea to implement a universal backup script. In the future there will be a separate note with a detailed description of how it works and practical examples 😉.

I should warn you right away that I’m not a developer and never wanted to be one 😌.

About the desired functionality

Let me briefly describe what I want from the final executable file:

Optional features:

That seems to be everything for now 😏.

A short story

And now a bit of blah blah blah 😀.

My experience shows that in modern IT, especially when working with Linux, there’s no getting away from programming. So I started studying Bash scripts to automate the large amount of routine work I face daily. But Linux administration isn’t only about Bash. And I started thinking more and more about Python, which is very closely tied to Linux. By the way, almost every desktop distribution of Linux with a GUI comes out of the box with a Python interpreter and software that uses this programming language.

But let’s get back to the topic of the post. It’s worth noting right away that I hadn’t really written anything in Python before. I only read and edited configs of some programs in Linux 🤷♂️.

At some point a while ago I tried a bit to learn Python on my own using a wonderful book: « Programming in Python: Examples and Problems » by A.N. Vasiliev 👍. But due to the lack of practical tasks related to the snake, I abandoned it about a third of the way through.

And about half a year ago I completed a great Python course for beginners. Well, i.e. for complete (and not so complete) novices. It was aimed at data analysts, but that’s not the point. It gave the basics. The course lasted 3 months, with 2 sessions a week (+1 optional extra one). This format suited me well.

Unfortunately, by the end of the course, the number of practical tasks where I could apply my Python knowledge hadn’t increased. And the skills I gained predictably started fading.

But one “fine” day, I returned to my idea of writing a universal backup script for my own needs. And initially I planned to do it in Bash. But after thinking a bit, I decided to shake the dust off my almost forgotten knowledge of the choking snake. Fortunately, with the availability of neural networks, the process of learning programming languages has become much easier and more comfortable.

Armed with ChatGPT, I set about writing shit code 🧐. At the moment I’ve implemented almost all the functionality I wanted, except encryption. I left that “for dessert” 🥞 and I’m working on it right now 👷♂️.

Initially, my goal was to create the most compact tool possible with minimal dependencies. I didn’t apply the OOP concept. So what came out is a simple and crude script that automates the “dirty” work 😌.

If you’re interested, the script is available in my repository on GitHub. But keep in mind that it’s still in development 🛠.

After further refinement and some testing, I plan to make a separate note with a detailed description of how to use it.

Thanks for reading!

Copyright Notice

Author: Ivan Cherniy

Link: https://r4ven.me/en/lyrics/pro-skript-rezervnogo-kopirovaniya-na-python/

License: CC BY-NC-SA 4.0

Blog materials may be used with attribution to the author and source, for non-commercial purposes, and under the same license.

Start searching

Enter keywords to search articles

↑↓
ESC
⌘K Shortcut