Archive
LISP function for inserting the GNU GPL v3 in Emacs.
Whenever we create a new source code file for a free software with Emacs we need first to add the short brief of the blessed GNU GPL v3. You can add a LISP function to your “~/.emacs” configuration file and call it whenever you want to add it.
If the file is missing you can create it.
After inserting the function and restarting Emacs you can call the function:
M-x insert-short-gpl (press Alt-x, type insert-short-gpl, press return).
Remove backup files ending with “~” from your system.
Many text editors create backup files with names ending with “~”.
Most of the times these files are annoying and unnecessary…
So, you can use the following piped commands to remove them :
find / | grep "^.*~$"
| sed -e 's/\(^.*$\)/"\1"/g'
| xargs rm -f > /dev/null 2>&1
Please take account that this version handles correctly also filepaths containing space characters.
The project ‘gfs’ (GNU Find String).
Within the framework of the course “Operating Systems I – Laboratory” (Department of Informatics and Communications, T.E.I of Serres) we were asked to choose one of 25 available projects aiming to implement and then present to the entire class. My choice was project 17, whose goal was the implementation of the external ‘find’ command of the operating system MS-DOS.
The project ‘shell-library’ (Shell Function Library).
The project ‘shell-library’ (Shell Function Library) is a developers’ effort to develop a free shell library with POSIX general purpose functions. The functions that the library offers can be used within shell scripts developed to automate the work of your operating system.
The project ‘nxnes’ (NxN Equalisations Solver).
The project ‘nxnes’ (NxN Equalisations Solver) is the implementation of project 5 from the list of selected projects in the course “Operating Systems II – Laboratory” (Department of Informatics and Communications, T.E.I of Serres). The objective of this project was the implementation of the Gauss Elimination Method to solve a NxN system of linear equations.
The project ‘gdr’ (GNU Diary Reminder).
Within the framework of the course “Operating Systems II – Laboratory” (Department of Informatics and Communications, T.E.I of Serres) we were asked to choose one of the 20 available projects to achieve. My choice was project 10, whose goal was to implement a birthday and celebrations alert system.
The project ‘clg’ (Cell Life Game).
Within the framework of the course “Operating Systems II – Laboratory” (Department of Informatics and Communications, T.E.I of Serres) we developed as a semester assignment an application whose aim was to simulate the evolution of a colony of single-celled organisms, namely the creation of the famous game of life.
The project ‘YAFL’ (Yet Another Free Language).
This project refers to the development of the procedural programming language YAFL (Yet Another Free Language) as well as its interpreter. The programming language YAFL is a tool for teaching the basic principles of procedural programming to secondary school students and beginners in general.
Protection of critical regions of a process in GNU/Linux.
Below, we quote a function for managing a transaction in a hypothetical transaction management system. It is very likely multiple instances of the function to be executed in parallel on a system of symmetric multiprocessing (SMP), on multi-processor platforms or even a multithreaded single processor systems.
“Hello World” example program in assembly language.
Probably sometime you will need to write a program in assembly language. For this reason, in this article we will develop a simple and typical executable “Hello World” program in assembly language to familiarize yourself with the process.
Implementation of a C function to convert a typical process into background service (Daemon).
Below I quote a function in C to convert a standard Linux kernel process into background service (Daemon Service). If you wish to develop a server to provide services, it may be helpful. Although there are several manuals on the Internet on how to create background services, most of them don’t show a complete example, while others are barely functioning. The following function converts a standard process into a service taking everything you need into account. Also, this function is the result of a combination of several textbooks and numerous studies about this issue. Finally, it has been tested on personal applications servers and it is performing well.
Implementation of functions in C for software signal management in POSIX operating systems.
Below I quote a simple implementation in C that you can use in your applications for the management of software signals in POSIX operating systems (such as the GNU/Linux). Of course, this implementation comes from a personal project of the past, especially where I grappled with system programming. You can modify this implementation to work best with your needs.
Function implementation to generate true random numbers from the Linux kernel.
Before I mention the function that I have personally developed for the production of random numbers from the monolithic Linux kernel, I would first like to say something about the issue of random numbers.
The issue of producing truly random numbers is important and had even since the beginning puzzled computer scientists. In mathematics, it is very difficult to define the random and, generally, randomness is very difficult to prove with no assumptions. In the past, many scientists tried to develop mathematical models and algorithms to develop random number generators.
One of the greatest scientists of Computer Science, John von Neumann (the basic idea of the architecture of all computer systems today was his own design) jokingly said: ‘Anyone who considers arithmetical methods of producing random digits is, of course, in a state of sin.’.
The project ‘hcf’ (Histogram of Characters Frequencies).
Within the framework of the course “Programming II – Laboratory” (Department of Informatics and Communications, T.E.I of Serres) we were asked to implement as homework a program that reads characters from the standard input and then export to standard output a frequency histogram of the characters that appear.
The project ‘dec2bin’ (decimal to binary converter).
The project ‘dec2bin’ (decimal to binary converter) is the implementation of an idea I had for some time. I have to admit that sometime in the past when studying possible ways of programming embedded systems with the programming language C and C++, I felt the need to be able to produce, through a program, supposed memory addresses in the form of binary numbers.