Skip to content

Instantly share code, notes, and snippets.

Francesco Frassinelli frafra

Block or report user

Report or block frafra

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@frafra
frafra / tags.json
Created Apr 6, 2018
addr:street/addr:housenumber simple preset for GeoPaparazzi
View tags.json
[{
"sectionname": "addresses",
"sectiondescription": "addresses",
"forms": [{
"formname": "address",
"formitems": [{
"key": "addr:street",
"value": "",
"type": "string",
"mandatory": "no"
@frafra
frafra / gpap-notes2osm.sql
Last active Apr 6, 2018
From GeoPaparazzi notes to OpenStreetMap XML
View gpap-notes2osm.sql
/*
Description:
This query allows to convert notes from GeoPaparazzi into a OSM XML
file that can be imported into JOSM.
Usage:
$ sqlite3 geopaparazzi.gpap < gpap-notes2osm.sql > geopaparazzi.osm
Made by:
Francesco Frassinelli - https://frafra.eu
*/
with body as (
@frafra
frafra / gpap-notes2geojson.sql
Last active Apr 6, 2018
From GeoPaparazzi notes to OpenStreetMap through GeoJSON
View gpap-notes2geojson.sql
/*
Description:
This query allows to convert notes from GeoPaparazzi into a GeoJSON
file that can be imported into JOSM.
Usage:
$ sqlite3 geopaparazzi.gpap < gpap-notes2geojson.sql > geopaparazzi.geojson
Made by:
Francesco Frassinelli - https://frafra.eu
*/
with osm as (
@frafra
frafra / schiena-dritta.py
Last active Jan 17, 2018
Simple adaptive notification system
View schiena-dritta.py
#!/usr/bin/env python3
#
# License: GPLv3
# Author: Francesco Frassinelli (fraph24@gmail.com)
# Copyright: Francesco Frassinelli 2018
import gi
gi.require_version('Notify', '0.7')
from gi.repository import GLib, Notify
@frafra
frafra / inkscape-devel.md
Created Dec 8, 2017
inkscape-devel on Fedora 27
View inkscape-devel.md

How to install Inkscape devel on Fedora 27

Installation

# dnf build-dep inkscape
# dnf install gcc-c++ libsoup-devel gtkmm30-devel
$ git clone -b master https://git.launchpad.net/inkscape --depth 1
$ mkdir -p inkscape/build/conf
$ cd inkscape
@frafra
frafra / poliadventures-17december.md
Last active Nov 16, 2018
Quests - December 2017 #PoliMappersAdventures
View poliadventures-17december.md

Quests - December 2017 #PoliMappersAdventures

  1. Learn something you didn't know about OpenStreetMap https://learnosm.org/
  2. Install StreetComplete (for Android) or Go Maps (for iOS) https://github.com/westnordost/StreetComplete#download or https://itunes.apple.com/app/id592990211
  3. Map a bench https://wiki.openstreetmap.org/wiki/Tag:amenity%3Dbench
  4. Find a bench and add the backrest tag https://wiki.openstreetmap.org/wiki/Key:backrest
  5. Map a picnic table https://wiki.openstreetmap.org/wiki/Tag:leisure%3Dpicnic_table
  6. Find a bench or a picnic table and add the material tag https://wiki.openstreetmap.org/wiki/Key:material
  7. Map a trash bin (unsorted waste only) https://wiki.openstreetmap.org/wiki/Tag:amenity%3Dwaste_basket
  8. Map a container for recycling of used goods https://wiki.openstreetmap.org/wiki/Tag:amenity%3Drecycling
@frafra
frafra / osh2sqlite.py
Last active Oct 8, 2018
OSM node history to SQLite
View osh2sqlite.py
#!/usr/bin/env python3
#
# OSM node history to SQLite
import osmium
import sqlite3
import sys
SCHEMA_OBJECT = """
@frafra
frafra / osm-node-history.py
Last active Feb 23, 2018
OSM node history (just a test)
View osm-node-history.py
#!/usr/bin/env python3
#
# OSM node history to SQLite
import osmium
import sqlite3
import sys
SCHEMA_NODES = """
CREATE TABLE nodes
View posta2csv.py
#!/usr/bin/env python3
#
# Convertitore delle mail del Raspberry Pi di Ugone
# Scritto da Frafra (2017)
import collections
import csv
import glob
messages = glob.glob('messaggi/*.txt')
@frafra
frafra / seren.sh
Created Sep 17, 2017
Flatpak for Seren
View seren.sh
#!/bin/bash -ex
# Latest build ready to install:
# $ wget https://about.frafra.eu/private/seren-0.0.22dev20161009.flatpak
# $ flatpak install seren-0.0.22dev20161009.flatpak
# $ flatpak run org.seren.Seren
# This flatpak is build upon freedesktop.Sdk//1.6
# $ flatpak remote-add --from gnome https://sdk.gnome.org/gnome.flatpakrepo
# $ flatpak install gnome org.freedesktop.Sdk//1.6
You can’t perform that action at this time.