Skip to content

Instantly share code, notes, and snippets.

View gubi's full-sized avatar

Alessandro Gubitosi gubi

View GitHub Profile
@gubi
gubi / README.md
Last active January 27, 2024 19:19
@gubi
gubi / available_font-awesome_icons.php
Last active January 7, 2024 11:58
Get all icons from a font-awesome.css file and list in json mode
<?php
/**
* Available Font Awesome icons
*
* Get all icons from a font-awesome.css file and list in json mode
*
* @author Alessandro Gubitosi <gubi.ale@iod.io>
* @license http://www.gnu.org/licenses/gpl-3.0.html GNU General Public License, version 3
*/
@gubi
gubi / fa-bounce.css
Last active September 14, 2023 17:58
Pulse animation for FontAwesome icons
.fa-bounce {
display: inline-block;
position: relative;
-moz-animation: bounce 1s infinite linear;
-o-animation: bounce 1s infinite linear;
-webkit-animation: bounce 1s infinite linear;
animation: bounce 1s infinite linear;
}
@-webkit-keyframes bounce {
@gubi
gubi / wget.sh
Created June 1, 2023 04:40 — forked from crittermike/wget.sh
Download an entire website with wget, along with assets.
# One liner
wget --recursive --page-requisites --adjust-extension --span-hosts --convert-links --restrict-file-names=windows --domains yoursite.com --no-parent yoursite.com
# Explained
wget \
--recursive \ # Download the whole site.
--page-requisites \ # Get all assets/elements (CSS/JS/images).
--adjust-extension \ # Save files with .html on the end.
--span-hosts \ # Include necessary assets from offsite as well.
--convert-links \ # Update links to still work in the static version.
@gubi
gubi / discover_network.sh
Created September 17, 2022 01:36
Discover the local network and list available devices (and their IP address)
#!/bin/bash
is_alive_ping()
{
ping -b -c 1 $1 > /dev/null
[ $? -eq 0 ] && echo Node with IP: $i is up.
}
for i in 192.168.{1..255}.{1..255}
@gubi
gubi / Atom_packages.md
Last active May 13, 2022 13:20
Packages installed in Atom

Featured

  • Autocomplete
  • Autocomplete Plus
  • Zen
  • Color Picker
  • Linter
  • Linter Php
  • Linter csslint
  • Linter Jshint
  • Linter Jsonlint
@gubi
gubi / README.md
Last active April 30, 2021 08:08
Elenco templates Bootstrap per BestGolf
@gubi
gubi / README.md
Last active December 23, 2018 15:50
Mysql version from .frm file

From your terminal launch this command:

$>: hexdump -s 0x33 -n 2 -v -d <FILE_NAME>.frm  | awk '{ print "Mysql version " $2; exit }'

Example output: Mysql version 50530, which means version 5.5.30

@gubi
gubi / _parser.php
Last active November 1, 2018 10:58
PHP script that extract data from the `resultAgrovoc_filled_20181029.xlsx` file
<?php
header("Content-type: text/plain");
require 'vendor/autoload.php';
use PhpOffice\PhpSpreadsheet\Spreadsheet;
use PhpOffice\PhpSpreadsheet\IOFactory;
use Monolog\Logger;
use Monolog\Handler\StreamHandler;
@gubi
gubi / sample.json
Created October 25, 2018 15:04
Bioversity sample metadata
{
"metadataBlocks": {
"citation": {
"fields": [{
"typeName": "title",
"multiple": false,
"value": "Manual para la evaluacion agronomica",
"typeClass": "primitive"
},
{