Skip to content

Instantly share code, notes, and snippets.

@juliuste
juliuste / readme.md
Last active November 26, 2023 10:18
direkt.bahn.guru

Why are some trains missing from the map?

direkt.bahn.guru internally uses a (legacy) API by Deutsche Bahn to find all direct trains running via a given station within the next 1-2 weeks. This API includes most trains in central Europe, but data availability gets significantly lower the further away stations are from routes (co-)operated by DB. Furthermore, trains operated by smaller companies seem to be missing more often than those run by state-owned operators, probably due to a lack of data sharing agreements.

Why do we use this DB-specific API in the first place? Unfortunately, there still isn't any public dataset available which covers all public transport routes in Europe (or even the EU, at least). Some countries don‘t provide data at all, others only publish data per region and operator (e.g. France), which is very hard to combine into a single dataset. See also: https://eu.data.public-transport.earth

That being said, we‘ll try to use a more complete data source as soo

@chriskyfung
chriskyfung / fb-photo-bulk-downloader.user.js
Last active March 18, 2024 10:50
Userscript for batch downloading Facebook photos from facebook with the post link and captions
// ==UserScript==
// @name Facebook photos bulk downloader
// @namespace https://chriskyfung.github.io
// @version 1.0.0
// @description Bulk download Facebook photos from facebook with the post link and captions
// @author Chris KY Fung
// @match https://www.facebook.com/*/photos/*
// @match https://www.facebook.com/photo.php?*
// @match https://www.facebook.com/photo?*
// @match https://www.facebook.com/photo/*
@yifanlu
yifanlu / Ghidra-OSX-Launcher-Script.scpt
Last active April 4, 2024 21:00
Ghidra.app launcher for OSX
@Benoitlecorre
Benoitlecorre / algo_apb_proper.sql
Last active June 16, 2020 12:09
Code source d'Admission post-bac envoyé par le ministère de l'Education nationale
-- Génération automatique de classements aléatoires en production, pour les FNS
-- ===================================
FUNCTION gen_class_aiea_v1_relatif_grp( o_g_ea_cod_ins IN varchar2, o_g_ti_cod IN number, o_c_gp_cod IN number, o_g_tg_cod IN number, iogin IN varchar2, type_login IN number, mode_dev IN number, confirm IN number, saio IN number, nip IN varchar2, indic IN number, mess_err out varchar2, mess_aff out varchar2)
RETURN number IS
retour number;
X varchar2(2);
dummy number;
dummy2 number;
l_c_gp_fIg_seI c_grp.c_gp_flg_sel%type;
@kyledrake
kyledrake / ferengi-plan.txt
Last active April 6, 2024 00:30
How to throttle the FCC to dial up modem speeds on your website using Nginx
# The blog post that started it all: https://neocities.org/blog/the-fcc-is-now-rate-limited
#
# Current known FCC address ranges:
# https://news.ycombinator.com/item?id=7716915
#
# Confirm/locate FCC IP ranges with this: http://whois.arin.net/rest/net/NET-165-135-0-0-1/pft
#
# In your nginx.conf:
location / {
@richso
richso / fault_dgrid_selector.html
Created December 28, 2013 15:08
dgrid with dgrid/selector generate error "Uncaught TypeError: Cannot set property '_hasSelectorInputListener' of undefined" when destroyRecursive()
<!DOCTYPE html>
<html>
<head>
<title></title>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<style type="text/css">
@import "script/dojo183/dojo/resources/dojo.css";
@import "script/dojo183/dijit/themes/claro/claro.css";
@import "script/dojo183/dgrid/css/dgrid.css";
@import "script/dojo183/dgrid/css/skins/claro.css";
@bloudermilk
bloudermilk / README.md
Created March 23, 2012 19:07
Facebook Page Categories

All of the categories!

I wrote a really simple JavaScript script that uses jQuery to extract all the categories from Facebook's "Create a page" page.

Instructions

  1. Navigate to the Create a page page.
  2. jQuerify the page.
  3. Open up your JavaScript console of choice and run the following script: