Skip to content

Instantly share code, notes, and snippets.


Open Data Coder p3t3r67x0

View GitHub Profile
p3t3r67x0 /
Last active December 31, 2022 23:34
Some list of openssl commands for check and verify your keys



Install the OpenSSL on Debian based systems

sudo apt-get install openssl
p3t3r67x0 /
Last active December 30, 2022 09:22
A CSS pseudo-element is used to style specified parts of an element. In some cases you can style native HTML controls with vendor specific pseudo-elements. Here you will find an list of cross browser specific pseudo-element selectors.

Styling native elements

Native HTML controls are a challenge to style. You can style any element in the web platform that uses Shadow DOM with a pseudo element ::pseudo-element or the /deep/ path selector.

video::webkit-media-controls-timeline {
  background-color: lime;

video /deep/ input[type=range] {
p3t3r67x0 /
Last active December 27, 2022 01:16
MS Office prefixed style properties can be used for older versions of MS Excel, MS PowerPoint or MS Word when you want to save a document, presentation, workbook, or worksheet as a web document, or even in older versions for MS Outlook.

MS Office prefixed style properties


Note: Office only

mso-ansi-font-size: large | larger | <length> | medium | <percentage> | small | smaller | x-large | x-small | xx-large | xx-small
p3t3r67x0 /
Last active November 11, 2022 09:59
Create a svg from truetype font with freetype and svgpathtools in python

Create a svg from truetype font in python

I am trying to create a svg file from a truetype font with freetype-py and svgpathtools. I have a working python code which generates the svg file but unfortunately there are some corners and edges where instead should be smooth curves. Here in this example I try to render an special char which does not look good at all.


What do I need to change in order to get curve symbols redered correctly?


p3t3r67x0 / hamburg_city_districts.geojson
Created December 4, 2018 23:01
Hamburg Germany multipolygon city districts geojson file.
View hamburg_city_districts.geojson
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
p3t3r67x0 /
Last active June 2, 2021 08:08
Simple script to extract the server cert of a given domain
#!/usr/bin/env python
# -*- coding: utf-8 -*-
import ssl
import OpenSSL
cert = ssl.get_server_certificate(('', 443))
x509 = OpenSSL.crypto.load_certificate(OpenSSL.crypto.FILETYPE_PEM, cert)
print 'Expired: {}'.format(x509.has_expired())
p3t3r67x0 / rewe_discounter_details.json
Created March 31, 2021 18:34
List of probably all german listed REWE discounters with address data as well as contact data.
View rewe_discounter_details.json
This file has been truncated, but you can view the full file.
{"marketManager": "Daniela Fischer", "phone": "036452-762538", "advertisingCounty": null, "regionShort": "OS", "address": {"street": "Schwerstedter Str.", "houseNumber": "3-4", "postalCode": "99439", "city": "Am Ettersberg OT Berlstedt", "state": "Th\u00fcringen", "streetWithNumber": "Schwerstedter Str. 3-4"}, "type": {"name": "REWE", "id": null}, "openingHours": {"condensed": [{"days": "Mo-Fr", "hours": "06:00 - 22:00"}, {"days": "Sa", "hours": "07:00 - 20:00"}], "dayAndTimeRanges": [{"startDay": "MONDAY", "endDay": "FRIDAY", "startTime": {"hour": 6, "minute": 0, "second": 0, "nano": 0}, "endTime": {"hour": 22, "minute": 0, "second": 0, "nano": 0}, "seoRepresentation": "Mo-Fr 06:00-22:00", "opens": "06:00", "closes": "22:00"}, {"startDay": "SATURDAY", "endDay": null, "startTime": {"hour": 7, "minute": 0, "second": 0, "nano": 0}, "endTime": {"hour": 20, "minute": 0, "second": 0, "nano": 0}, "seoRepresentation": "Sa 07:00-20:00", "opens": "07:00", "closes": "20:00"}]}, "specialOpeningHours": null, "geoLocation
p3t3r67x0 /
Last active October 31, 2020 15:16
Be aware that every rendering engine has its own implementation of prefixed properties. As extensions are made part of the standard, the unprefixed identifier is then substituted.

Prefixed style properties


The -ms-accelerator property sets or retrieves a string that indicates whether the object represents a keyboard shortcut.

-ms-accelerator: false | true
p3t3r67x0 / vue_tailwindcss_candar.vue
Created October 13, 2020 11:23
Simple Vue Tailwindcss Calendar with Modal
View vue_tailwindcss_candar.vue
<div class="bg-white rounded shadow overflow-hidden">
<div class="flex items-center justify-between py-2 px-6">
<span class="text-lg font-bold text-gray-800">{{ monthNames[month] }}</span>
<span class="ml-1 text-lg text-gray-600 font-normal">{{ year }}</span>
<div class="border rounded-lg px-1" style="padding-top: 2px;">
<button type="button" class="leading-none rounded-lg transition ease-in-out duration-100 inline-flex cursor-pointer hover:bg-gray-200 p-1 items-center" :class="{'cursor-not-allowed opacity-25': month == 0 }"