Home

Open a terminal and type the command: sudo nano /etc/dphys-swapfile Inside this file, change the value after “CONF_SWAPSIZE” to 2048. Save it then commit your changes with the following command: sudo dphys-swapfile setup NOTE: this will create a 2 gigabyte swap file on your SD card; make sure it’s large […]

Increasing swap space for Raspberry Pi


Install ‘Tools required for building Ruby Gems’ using Plesk installer Download the latest version of “Redmine” from its official website . Browse to Domains > example.com > File Manager and Upload .zip file from step 1. Extract it and copy all the extracted content to httpdocs . Rename config/database.yml.example to config/database.yml Browse to Domains > example.com > Databases and create a database. Browse […]

Add Redmine domain in Plesk




To rename all files in a directory recursively adding a suffix, for example in a way that the new filename suffix will be the number of lines of the original file (e.g. if the file ‘my_file’ has 10 lines then it will be renamed to ‘my_file_10’): To keep extensions (if present):

Recursive files renaming adding a suffix


Per aggiungere un indicator alla topbar di Ubuntu è sufficiente, aprire una console e lanciare il comando: sudo apt-get install indicator-<indicator name> Per esempio, se si vuole installare l’indicator per gestire input e output audio  basta lanciare il comando: sudo apt-get install indicator-sound*

Add indicator on Ubuntu topbar


To change files name recursively you can combine the commands find and rename, as in these ways: To add suffix (e.g. ‘_mysuffix’) find . -name “*.jpg” -exec rename -v ‘s/\.jpg$/\_mysuffix.jpg/i’ {} \; To remove suffix find . -name “*.jpg” -exec rename -v ‘s/\_mysuffix.jpg$/\.jpg/i’ {} \; To add prefix (e.g. ‘myprefix_’) find […]

Recursively files renaming on Linux cli



Changing Classes with JavaScript To dynamically change class(es) of an html element using Javascript, you can use classList method: document.getElementById(“MyElement”).classList.add(‘MyClass’); document.getElementById(“MyElement”).classList.remove(‘MyClass’); if ( document.getElementById(“MyElement”).classList.contains(‘MyClass’) ) { … } document.getElementById(“MyElement”).classList.toggle(‘MyClass’); To change all classes for an element: document.getElementById(“MyElement”).className = “MyClass”; document.getElementById(“MyElement”).className = “MyClass1 MyClass2”; The above commands will overwrite the existing classes; […]

Change an html element’s class with JavaScript and jQuery


Windows terminals accessible via a domain account sometimes don’t allow access via Windows Hello (i.e. via PIN or facial recognition). The way to resolve this problem is quite simple and quick. It’s enough to set a key value of a system registry. From “Start” run the command: regedit Now inside […]

Allow setup of user access on Windows 10 domain-joined devices


To display all files (for example greater than 50k bytes) in a directory and it’s subdirectories, open a linux shell and type: find . -size +10k -exec ls -lh {} \+ The ‘h’ parameter list the files by human readable size. The ‘{}’ is the file itself; the ‘\+’ could […]

List files (greater than a size) in directory and subdirectories ...



As jQuery official documentation reports, the .serialize() method creates a text string in standard URL-encoded notation. It can act on a jQuery object that has selected individual form controls. The .serialize() method creates a text string in standard URL-encoded notation. It can act on a jQuery object that has selected […]

Convert ampersands before serialize()