Welcome to Davide Airaghi's website ! 

In this website you'll find some information about me, some tips&tricks and some software i worked on.

 

Davide Airaghi

Apache Netbeans for Linux: get latest build

After having seen how to build Apache Netbeans on a Linux box here you can find how to get the latest build (no more compiling!) from Apache servers. It'a all in a couple of shell commands : NBURL=$( wget https://builds.apache.org/view/Incubator%20Projects/job/incubator-netbeans-linux/lastSuccessfulBuild/artifact/nbbuild/ -qO- | grep -o -e…

Continue reading...
Davide Airaghi

Gestione moduli Apache per openSuse

Per la gestione del webserver Apache Httpd sulla distribuzione openSuse abbiamo il classico comando a2enmod, condiviso con altre distribuzioni, che permette di: 1) capire se un modulo è abilitato, 2) attivare un modulo che è non attivo e 3) disattivare un modulo.

Per comodità di gestione del sistema ho preparato un semplice script che si occupa di fare da wrapper verso il citato a2enmod andando a fornire funzionalità quali: 1) lista di tutti i moduli presenti sul sistema, 2) lista di tutti i moduli abilitati, 3) verifica dell'abilitazione di un modulo, 4) abilitazione di uno o più moduli e 5) disattivazione di uno più moduli.

Continue reading...
Davide Airaghi

Apache Netbeans : download ultima versione disponibile

Dopo aver visto come compilare Apache NetBeans ecco un altro modo per ottenere l'ultima versione di tale software, questa volta già in formato "compilato". Il tutto si riduce a due semplici righe da eseguire nel vostro terminale NBURL=$( wget https://builds.apache.org/view/Incubator%20Projects/job/incubator-netbeans-linux/lastSuccessfulBuild/artifact/nbbuild/ -qO- | grep -o -e "NetBeans-dev-incubator-netbeans-linux-.*-on-.*-release.zip\""…

Continue reading...
Davide Airaghi

Apache NetBeans - building and installation

NetBeans is now an Apache Foundation project, but (as of today) we lost the possibility to download a specific release (Java only, PHP, C/C++, ...), the standard version available (release 9+) is only built with Java support. I have created a very simple script that build Apache NetBeans including support for various programming languages (PHP included), getting sources from the latest tree hosted on GitHub. Continue reading...
Davide Airaghi

Apache Netbeans - compilazione e aggiornamento

Con il passaggio di NetBeans alla Apache Foundation si è, per ora, persa la possibilità di scaricare versioni specifiche e già preconfezionate di questo IDE. Se si unisce questo all'attuale impossibilità di usare la versione 9 del software, come offerta preconfezionata dalla Apache Foundation, anche per lo sviluppo PHP emerge come si debba trovare un metodo alternativo per ottenere, con poco sforzo, un tool di sviluppo aggiornato e adatto ai propri scopi.

Per questo motivo vi propongo lo script che sto usando per compilare Apache NetBeans all'ultima versione disponibile sul relativo reporistory GitHub e con il supporto a tutti i linguaggi previsti (PHP incluso).

Continue reading...
Davide Airaghi

PHP - file encryption/decryption

To have some sort of privacy while sending/receiving messages (or files) using encryption is the first choice. Below you can find a very simple PHP web application that allows you to encrypt/decrypt a file using your web browser (and a web server hosting the page).

Continue reading...
Davide Airaghi

PHP - Tool per crittografia file online

Per permettere un certo livello di riservatezza nelle comunicazioni si deve ricorrere a sistemi che vadano a cifrare i dati in transito, facendo in modo che solo il diretto interessato sia in grado di risalire al messaggio reale inviato; questo tipo di comunicazione deve essere…

Continue reading...
Davide Airaghi

Linux: get info about notebook battery

Below you can find a very simple shell script that gets information about every battery present in your notebook and shows a summary. create a new file (es: /usr/local/bin/battery.sh) paste inside the new file the following code #!/bin/sh oDIR=$( pwd ) oIFS=$IFS IFS=$'\n' for BATTERY…

Continue reading...
Davide Airaghi

Automatic Wpa Supplicant restart

If wifi connection used by your Linux box is not stable and goes up&down, with wpa_supplicant requiring some manual restart you could use a simple script that does it for you. Below you can find a script i'm using on a RaspberryPi 3 with Raspian installed. #!/bin/sh…

Continue reading...